mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-12 14:29:28 +00:00
FAST_DEPEND: Rework optimization for r290524.
The .MAKEFLAGS check inside of the .for loop is extremely slow for some reason. Just moving it out of the loop trimmed -V lookup time from 11 seconds to 1 second in the kernel obj directory. Sponsored by: EMC / Isilon Storage Division
This commit is contained in:
parent
0e47853e87
commit
9f286e8295
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=294104
@ -170,12 +170,12 @@ DEPENDSRCS= ${SRCS:M*.[cSC]} ${SRCS:M*.cxx} ${SRCS:M*.cpp} ${SRCS:M*.cc}
|
||||
.if !empty(DEPENDSRCS)
|
||||
DEPENDOBJS+= ${DEPENDSRCS:R:S,$,.o,}
|
||||
.endif
|
||||
.for __obj in ${DEPENDOBJS:O:u}
|
||||
DEPENDFILES_OBJS= ${DEPENDOBJS:O:u:${DEPEND_FILTER}:C/^/${DEPENDFILE}./}
|
||||
.if ${.MAKEFLAGS:M-V} == ""
|
||||
.sinclude "${DEPENDFILE}.${__obj:${DEPEND_FILTER}}"
|
||||
.endif
|
||||
DEPENDFILES_OBJS+= ${DEPENDFILE}.${__obj:${DEPEND_FILTER}}
|
||||
.for __depend_obj in ${DEPENDFILES_OBJS}
|
||||
.sinclude "${__depend_obj}"
|
||||
.endfor
|
||||
.endif
|
||||
.endif # ${MK_FAST_DEPEND} == "yes"
|
||||
.endif # defined(SRCS)
|
||||
|
||||
|
@ -206,12 +206,12 @@ DEPEND_CFLAGS+= -MD -MP -MF.depend.${.TARGET}
|
||||
DEPEND_CFLAGS+= -MT${.TARGET}
|
||||
CFLAGS+= ${DEPEND_CFLAGS}
|
||||
DEPENDOBJS+= ${SYSTEM_OBJS}
|
||||
.for __obj in ${DEPENDOBJS:O:u}
|
||||
DEPENDFILES_OBJS= ${DEPENDOBJS:O:u:C/^/.depend./}
|
||||
.if ${.MAKEFLAGS:M-V} == ""
|
||||
.sinclude ".depend.${__obj}"
|
||||
.endif
|
||||
DEPENDFILES_OBJS+= .depend.${__obj}
|
||||
.for __depend_obj in ${DEPENDFILES_OBJS}
|
||||
.sinclude "${__depend_obj}"
|
||||
.endfor
|
||||
.endif
|
||||
.endif # ${MK_FAST_DEPEND} == "yes"
|
||||
|
||||
.NOPATH: .depend ${DEPENDFILES_OBJS}
|
||||
|
Loading…
Reference in New Issue
Block a user