4 ms·
'malloc' gives you a pointer to a fixed length block of memory that you can use to store data. 'ls' lists files in a directory. That's totally different, functi
by 013a 6y ago
'malloc' gives you a pointer to a fixed length block of memory that you can use to store data. 'ls' lists files in a directory. That's totally different, functionality wise.
'malloc' gives you a pointer to a fixed length block of memory that you can use to store data. A table saw cuts pieces of wood. That's totally different, functionality wise.
'malloc' gives you a pointer to a fixed length block of memory that you can use to store data. S3 gives you a url to a variable length block of durable storage that you can use to store data. That's... more similar to each other than the words "totally different" would suggest.
- deleted 6y ago[deleted]
- gruez 6y ago>S3 gives you a url to a variable length block of durable storage that you can use to store data. nitpick: it doesn't. you control the url, because it's based on the key that you provide. malloc gives you an arbitrary pointer. it's closer to mmap (where you control the address), but even that's different because the address you provide is merely a hint.
- saagarjha 6y ago…unless you use MAP_FIXED, in which case it will fail if it cannot allocate at that address.