Closed
Bug 107051
Opened 23 years ago
Closed 11 years ago
nsNetUtil.h should be made into a static library
Categories
(Core :: Networking, defect)
Core
Networking
Tracking
()
RESOLVED
DUPLICATE
of bug 170983
People
(Reporter: darin.moz, Unassigned)
Details
(Keywords: perf)
nsNetUtil.h should be made into a static library. for one thing, this would allow us to cache necko services (such as the IO service) on behave of each module that uses necko.
Reporter | ||
Updated•23 years ago
|
Comment 1•23 years ago
|
||
But then we lose the benefits of inlining (which are probably very small for most of these functions, I'll admit). Isn't there a better way to do this? I don't think we all really want a million little static libraries, one for each module. Won't a static variable in a static inline routine be shared between stuff which is linked together, anyway, but not between stuff which is dlopened? ie can't we make do_GetIOService do something like: (error checking omitted) static inline nsIIOService* do_GetIOService() { static nsIIOService* io = nsnull; if (!io) { io = do_GetService(cid); }return io; } and have this Just Work? Or does this require linker magic which isn't guarenteed?
Reporter | ||
Comment 2•23 years ago
|
||
this would work, but i also wanted to add and xpcom-shutdown observer to free the io service. so, i figured a library might be the best way to go.
Reporter | ||
Comment 3•23 years ago
|
||
unlikely to make it for mozilla1.0 -> future
Target Milestone: mozilla0.9.8 → Future
Reporter | ||
Comment 4•18 years ago
|
||
-> default owner
Assignee: darin → nobody
Status: ASSIGNED → NEW
QA Contact: benc → networking
Target Milestone: Future → ---
Updated•18 years ago
|
Priority: P3 → --
Updated•11 years ago
|
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•