echristo added a comment.
LGTM as well. Thanks!
Repository:
rL LLVM
https://reviews.llvm.org/D52920
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rL344000: Introduce code_model macros (authored by tamur,
committed by ).
Herald added a subscriber: llvm-commits.
Repository:
rL LLVM
https://reviews.llvm.org/D52920
Files:
cfe/trunk/include/clang/Ba
tamur added inline comments.
Comment at: lib/Basic/Targets/X86.cpp:865
+ if (CodeModel == "default")
+// When the user has not explicitly specified anything,
+// the default code model to use is small.
MaskRay wrote:
> I'm not sure if the comment is usef
tamur updated this revision to Diff 168700.
Repository:
rC Clang
https://reviews.llvm.org/D52920
Files:
include/clang/Basic/TargetOptions.h
lib/Basic/Targets/X86.cpp
lib/Frontend/CompilerInvocation.cpp
test/Preprocessor/init.c
Index: test/Preprocessor/init.c
==
MaskRay added inline comments.
Comment at: lib/Basic/Targets/X86.cpp:865
+ if (CodeModel == "default")
+// When the user has not explicitly specified anything,
+// the default code model to use is small.
I'm not sure if the comment is useful here... or y
tamur updated this revision to Diff 168494.
Repository:
rC Clang
https://reviews.llvm.org/D52920
Files:
include/clang/Basic/TargetOptions.h
lib/Basic/Targets/X86.cpp
lib/Frontend/CompilerInvocation.cpp
test/Preprocessor/init.c
Index: test/Preprocessor/init.c
==
MaskRay added inline comments.
Comment at: test/Preprocessor/init.c:7992
+//
+// RUN: %clang -xc - -E -dD -mcmodel=medium --target=i386-unknown-linux <
/dev/null | FileCheck -match-full-lines -check-prefix X86_MEDIUM %s
+// X86_MEDIUM:#define __code_model_medium_ 1
-
MaskRay added inline comments.
Comment at: include/clang/Basic/TargetOptions.h:72
+ // The code model to be used as specified by the user. Corresponds to
+ // Model enum defined in include/llvm/Support/CodeGen.h, plus "default" for
+ // the case when the user has not explicitl
tamur created this revision.
tamur added reviewers: compnerd, MaskRay.
tamur added a project: clang.
Herald added a subscriber: cfe-commits.
gcc defines macros such as __code_model_small_ based on the user passed command
line flag -mcmodel. clang accepts a flag with the same name and similar
eff