Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Issue 7331014: Drastically reduce the transitive dependencies of jsregexp.h, making it (almost) (Closed)

Created:
9 years, 5 months ago by Sven Panne
Modified:
9 years, 5 months ago
CC:
v8-dev
Visibility:
Public.

Description

Drastically reduce the transitive dependencies of jsregexp.h, making it (almost) architecture-independent. jsregexp.h is itself included transitively quite a lot, and by getting rid of 19 of its dependencies (which even included things like src/cpu.h, the various assemblers, etc.), the recompilation behaviour is a bit less funny than it was. Committed: http://code.google.com/p/v8/source/detail?r=8589

Patch Set 1 #

Total comments: 8
Unified diffs Side-by-side diffs Delta from patch set Stats (+40 lines, -2 lines) Patch
M src/arm/regexp-macro-assembler-arm.h View 1 chunk +3 lines, -0 lines 2 comments Download
M src/ia32/regexp-macro-assembler-ia32.h View 1 chunk +3 lines, -0 lines 0 comments Download
M src/jsregexp.h View 1 chunk +0 lines, -1 line 0 comments Download
M src/mips/regexp-macro-assembler-mips.h View 2 chunks +6 lines, -1 line 2 comments Download
M src/objects-visiting.h View 1 chunk +16 lines, -0 lines 0 comments Download
M src/x64/regexp-macro-assembler-x64.h View 1 chunk +6 lines, -0 lines 2 comments Download
M test/cctest/test-regexp.cc View 1 chunk +6 lines, -0 lines 2 comments Download

Messages

Total messages: 5 (0 generated)
Sven Panne
9 years, 5 months ago (2011-07-08 14:41:11 UTC) #1
danno
LGTM with nits http://codereview.chromium.org/7331014/diff/1/src/mips/regexp-macro-assembler-mips.h File src/mips/regexp-macro-assembler-mips.h (right): http://codereview.chromium.org/7331014/diff/1/src/mips/regexp-macro-assembler-mips.h#newcode34 src/mips/regexp-macro-assembler-mips.h:34: #include "macro-assembler.h" Please include in alpabetical ...
9 years, 5 months ago (2011-07-11 08:57:56 UTC) #2
Søren Thygesen Gjesse
LGTM
9 years, 5 months ago (2011-07-11 09:07:23 UTC) #3
Kevin Millikin (Chromium)
http://codereview.chromium.org/7331014/diff/1/src/arm/regexp-macro-assembler-arm.h File src/arm/regexp-macro-assembler-arm.h (right): http://codereview.chromium.org/7331014/diff/1/src/arm/regexp-macro-assembler-arm.h#newcode32 src/arm/regexp-macro-assembler-arm.h:32: #include "arm/assembler-arm-inl.h" Drive-by comments: I don't know if it's ...
9 years, 5 months ago (2011-07-11 10:10:51 UTC) #4
Sven Panne
9 years, 5 months ago (2011-07-11 12:22:48 UTC) #5
http://codereview.chromium.org/7331014/diff/1/src/arm/regexp-macro-assembler-...
File src/arm/regexp-macro-assembler-arm.h (right):

http://codereview.chromium.org/7331014/diff/1/src/arm/regexp-macro-assembler-...
src/arm/regexp-macro-assembler-arm.h:32: #include "arm/assembler-arm-inl.h"
On 2011/07/11 10:10:52, Kevin Millikin wrote:
> I don't know if it's a good practice, but we usually assume that xxx-inl.h
> includes xxx.h already.  That is, we usually include one or the other, but not
both.

I wasn't able to deduce this from our code, and I'm not sure if we follow this
rule consistently. Anyway, more stuff for the upcoming cleanups... :-)

> 
> Also, you should try to remember to the copyright dates :).

Ooops, I'll remember that next time, sorry.

http://codereview.chromium.org/7331014/diff/1/src/mips/regexp-macro-assembler...
File src/mips/regexp-macro-assembler-mips.h (right):

http://codereview.chromium.org/7331014/diff/1/src/mips/regexp-macro-assembler...
src/mips/regexp-macro-assembler-mips.h:34: #include "macro-assembler.h"
On 2011/07/11 08:57:56, danno wrote:
> Please include in alpabetical order:

IMHO this is a rather useless rule: If you have only a small handful of
#includes, nobody seriously cares about their order, because you can see
everything at first glance. If you have tons of #includes, you have very
different and much more serious problems (coupling/cohesion), where the order is
one of your least concerns. :-)

Anyway, back to the code at hand: The vast majority of our v8 headers fail
miserably when it comes to being self-contained, so we currently *do* have lots
of places where we have to rely on the order.

We really have to clean this up heavily, but this can only be done in very small
steps, because tiny changes ripple through tons of source files at the moment.

http://codereview.chromium.org/7331014/diff/1/src/x64/regexp-macro-assembler-...
File src/x64/regexp-macro-assembler-x64.h (right):

http://codereview.chromium.org/7331014/diff/1/src/x64/regexp-macro-assembler-...
src/x64/regexp-macro-assembler-x64.h:35: #include "x64/macro-assembler-x64.h"
On 2011/07/11 08:57:56, danno wrote:
> alphabetize

See related comment

http://codereview.chromium.org/7331014/diff/1/test/cctest/test-regexp.cc
File test/cctest/test-regexp.cc (right):

http://codereview.chromium.org/7331014/diff/1/test/cctest/test-regexp.cc#newc...
test/cctest/test-regexp.cc:45: #include "code.h"
On 2011/07/11 08:57:56, danno wrote:
> alphabetize

See related comment

Powered by Google App Engine
This is Rietveld 408576698