FosterMolasses@leminal.space to 196@lemmy.blahaj.zoneEnglish · edit-21 month agoImprovise adapt overruleleminal.spaceimagemessage-square34linkfedilinkarrow-up1702arrow-down12
arrow-up1700arrow-down1imageImprovise adapt overruleleminal.spaceFosterMolasses@leminal.space to 196@lemmy.blahaj.zoneEnglish · edit-21 month agomessage-square34linkfedilink
minus-squareSasquatch@lemmy.mllinkfedilinkEnglisharrow-up2·1 month agoim not sure how malloc() works, but I would guess it would attempt to squeeze new allocations into partially-filled memory pages, right? Wouldn’t that largely offset the inefficiency?
minus-squaretomalley8342@lemmy.worldlinkfedilinkEnglisharrow-up2·1 month agoTransfers to cache get brought in much smaller sizes than a memory page so I can’t imagine an automated treatment like that from the heap end would be effective. However there are ways to lay out linked lists in memory so that it is more friendly to cache
im not sure how
malloc()works, but I would guess it would attempt to squeeze new allocations into partially-filled memory pages, right? Wouldn’t that largely offset the inefficiency?Transfers to cache get brought in much smaller sizes than a memory page so I can’t imagine an automated treatment like that from the heap end would be effective. However there are ways to lay out linked lists in memory so that it is more friendly to cache