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

Issue 877003003: Subzero: Use a "known" version of clang-format. (Closed)

Created:
5 years, 11 months ago by Jim Stichnoth
Modified:
5 years, 11 months ago
CC:
native-client-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Subzero: Use a "known" version of clang-format. There are two problems with "make format" and "make format-diff" in Makefile.standalone: 1. You have to make sure clang-format and clang-format-diff.py are available in $PATH. 2. Different users may have different versions installed (even for the same user on different machines), leading to whitespace wars. Can't we all just get along? Since the normal LLVM build that Subzero depends on also exposes and builds clang-format and friends, we might as well use it. The clang-format binary is found in $LLVM_BIN_PATH, and clang-format-diff.py is found relative to $LLVM_SRC_PATH. As long as the user's LLVM build is fairly up to date, whitespace wars are unlikely. Given this, there's a much higher incentive to use "make format" regularly instead of "make format-diff". In particular, inline comments on variable/field declaration lists can get lined up more nicely by looking at the entire context, rather than the small diff window. BUG= none R=jvoung@chromium.org Committed: https://gerrit.chromium.org/gerrit/gitweb?p=native_client/pnacl-subzero.git;a=commit;h=dd842dbb57b825ed0dd6400648d0602b74c90aff

Patch Set 1 #

Patch Set 2 : Fix wildcards #

Total comments: 8

Patch Set 3 : Add a clang-format blacklist. Fix formatting "errors". #

Unified diffs Side-by-side diffs Delta from patch set Stats (+604 lines, -747 lines) Patch
M Makefile.standalone View 1 2 2 chunks +10 lines, -16 lines 0 comments Download
M crosstest/mem_intrin.cpp View 2 chunks +4 lines, -5 lines 0 comments Download
M crosstest/mem_intrin_main.cpp View 1 2 2 chunks +30 lines, -30 lines 0 comments Download
M crosstest/test_arith_main.cpp View 5 chunks +11 lines, -16 lines 0 comments Download
M crosstest/test_bitmanip.h View 1 chunk +4 lines, -4 lines 0 comments Download
M crosstest/test_bitmanip_main.cpp View 2 chunks +9 lines, -17 lines 0 comments Download
M crosstest/test_calling_conv.h View 1 chunk +2 lines, -2 lines 0 comments Download
M crosstest/test_calling_conv.cpp View 1 chunk +3 lines, -3 lines 0 comments Download
M crosstest/test_calling_conv_main.cpp View 3 chunks +5 lines, -5 lines 0 comments Download
M crosstest/test_cast_main.cpp View 1 chunk +39 lines, -43 lines 0 comments Download
M crosstest/test_fcmp_main.cpp View 2 chunks +2 lines, -2 lines 0 comments Download
M crosstest/test_global.cpp View 3 chunks +8 lines, -8 lines 0 comments Download
M crosstest/test_global_main.cpp View 1 chunk +1 line, -2 lines 0 comments Download
M crosstest/test_icmp_main.cpp View 4 chunks +15 lines, -17 lines 0 comments Download
M crosstest/test_select_main.cpp View 3 chunks +8 lines, -10 lines 0 comments Download
M crosstest/test_stacksave.h View 1 chunk +6 lines, -6 lines 0 comments Download
M crosstest/test_stacksave.c View 1 chunk +1 line, -3 lines 0 comments Download
M crosstest/test_stacksave_main.c View 2 chunks +6 lines, -8 lines 0 comments Download
M crosstest/test_sync_atomic.h View 1 chunk +3 lines, -3 lines 0 comments Download
M crosstest/test_sync_atomic.cpp View 1 chunk +30 lines, -30 lines 0 comments Download
M crosstest/test_sync_atomic_main.cpp View 9 chunks +64 lines, -86 lines 0 comments Download
M runtime/szrt.c View 1 1 chunk +13 lines, -39 lines 0 comments Download
M src/IceCfg.h View 2 chunks +2 lines, -4 lines 0 comments Download
M src/IceCfgNode.h View 1 chunk +6 lines, -6 lines 0 comments Download
M src/IceCfgNode.cpp View 3 chunks +7 lines, -6 lines 0 comments Download
M src/IceConverter.cpp View 1 chunk +1 line, -1 line 0 comments Download
M src/IceDefs.h View 2 chunks +2 lines, -9 lines 0 comments Download
M src/IceELFObjectWriter.cpp View 1 chunk +1 line, -1 line 0 comments Download
M src/IceGlobalContext.h View 1 chunk +1 line, -5 lines 0 comments Download
M src/IceGlobalInits.h View 2 chunks +2 lines, -3 lines 0 comments Download
M src/IceGlobalInits.cpp View 4 chunks +9 lines, -8 lines 0 comments Download
M src/IceInst.cpp View 4 chunks +8 lines, -8 lines 0 comments Download
M src/IceInstX8632.h View 3 chunks +3 lines, -11 lines 0 comments Download
M src/IceInstX8632.cpp View 13 chunks +44 lines, -66 lines 0 comments Download
M src/IceIntrinsics.h View 1 chunk +2 lines, -8 lines 0 comments Download
M src/IceIntrinsics.cpp View 2 chunks +94 lines, -87 lines 0 comments Download
M src/IceOperand.h View 6 chunks +8 lines, -10 lines 0 comments Download
M src/IceOperand.cpp View 3 chunks +6 lines, -5 lines 0 comments Download
M src/IceRNG.cpp View 1 chunk +2 lines, -2 lines 0 comments Download
M src/IceTargetLowering.h View 1 chunk +1 line, -3 lines 0 comments Download
M src/IceTargetLowering.cpp View 1 chunk +3 lines, -3 lines 0 comments Download
M src/IceTargetLoweringX8632.cpp View 13 chunks +29 lines, -29 lines 0 comments Download
M src/IceTimerTree.h View 1 chunk +4 lines, -4 lines 0 comments Download
M src/IceTypes.h View 2 chunks +2 lines, -6 lines 0 comments Download
M src/IceTypes.cpp View 2 chunks +2 lines, -2 lines 0 comments Download
M src/PNaClTranslator.cpp View 15 chunks +24 lines, -32 lines 0 comments Download
M src/assembler.h View 1 chunk +1 line, -3 lines 0 comments Download
M src/llvm2ice.cpp View 6 chunks +34 lines, -38 lines 0 comments Download
M unittest/BitcodeMunge.h View 1 chunk +2 lines, -3 lines 0 comments Download
M unittest/BitcodeMunge.cpp View 2 chunks +5 lines, -4 lines 0 comments Download
M unittest/IceParseInstsTest.cpp View 1 2 6 chunks +25 lines, -25 lines 0 comments Download

Messages

Total messages: 6 (1 generated)
Jim Stichnoth
The only actual change is in Makefile.standalone, but this CL also includes running "make format", ...
5 years, 11 months ago (2015-01-27 13:53:41 UTC) #2
jvoung (off chromium)
https://codereview.chromium.org/877003003/diff/20001/Makefile.standalone File Makefile.standalone (right): https://codereview.chromium.org/877003003/diff/20001/Makefile.standalone#newcode202 Makefile.standalone:202: `find . -name "*.c" -o -name "*.cpp" -o -name ...
5 years, 11 months ago (2015-01-27 18:08:12 UTC) #3
Jim Stichnoth
Jan, for looking through the mind-numbing changes, you da real MVP! I added a "make ...
5 years, 11 months ago (2015-01-27 19:24:11 UTC) #4
jvoung (off chromium)
lgtm
5 years, 11 months ago (2015-01-27 19:29:58 UTC) #5
Jim Stichnoth
5 years, 11 months ago (2015-01-27 20:53:57 UTC) #6
Message was sent while issue was closed.
Committed patchset #3 (id:40001) manually as
dd842dbb57b825ed0dd6400648d0602b74c90aff (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698