3 ms·
Does RAII make code faster? I thought RAII just meant things were freed as soon as they went out of scope rather than waiting for the next GC sweep? Seems like
by throwaway894345 5y ago
Does RAII make code faster? I thought RAII just meant things were freed as soon as they went out of scope rather than waiting for the next GC sweep? Seems like this would make code slower (instead of one free() for all garbage, you have to do a free() for each allocation). Granted, the tracing burden is lower, but I'm of the impression that tracing is cheap?