anemet added inline comments.
Comment at: test/Frontend/optimization-remark-with-hotness.c:1-34
+// Generate instrumentation and sampling profile data.
// RUN: llvm-profdata merge \
-// RUN: %S/Inputs/optimization-remark-with-hotness.proftext \
+// RUN: %S/Inputs/optim
anemet added inline comments.
Comment at: test/Frontend/optimization-remark-with-hotness.c:32
+// RUN: -Rpass-analysis=inline -fdiagnostics-show-hotness 2>&1 |
FileCheck \
+// RUN: -check-prefix=PGO_ENABLED %s
+// RUN: %clang_cc1 -triple x86_64-apple-macosx10.9 -main-fi
anemet accepted this revision.
anemet added a comment.
This revision is now accepted and ready to land.
LGTM
Repository:
rC Clang
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D57220/new/
https://reviews.llvm.org/D57220
___
cfe-commits ma
anemet added a comment.
Only minor things at this point. This is very close now.
Comment at: include/llvm/Analysis/OptimizationDiagnosticInfo.h:81
/// detected by the user.
- bool allowExtraAnalysis() const {
-// For now, only allow this with -fsave-optimization-record
anemet added a comment.
Please clean this up as well (don't have commented-out lines) so that it's
ready to go with the LLVM patch.
Comment at: lib/CodeGen/CodeGenAction.cpp:302-305
static void DiagnosticHandler(const llvm::DiagnosticInfo &DI,
anemet accepted this revision.
anemet added a comment.
This revision is now accepted and ready to land.
LGTM with the nits below. Thanks!
Comment at: include/llvm/IR/DiagnosticHandler.h:1
+//===- DiagnosticHandler.cpp - DiagnosticHandler class for LLVM -*- C++
-*-===//
+//
--
anemet added inline comments.
Comment at: lib/CodeGen/CodeGenAction.cpp:882-883
BEConsumer = Result.get();
-
+ VMContext->setDiagnosticHandler(llvm::make_unique(
+ CI.getCodeGenOpts(), Result.get()));
// Enable generating macro debug info only when debug info is not d
anemet added a comment.
In https://reviews.llvm.org/D37196#868320, @vivekvpandya wrote:
> > Why? That was inside BackendConsumer.
>
> I was getting incomplete type error.
You may have to move the class declaration of ClangDiagnosticHandler before the
BackendConsumer and move the definition of
anemet accepted this revision.
anemet added a comment.
Still looks good.
Comment at: lib/IR/LLVMContext.cpp:332
+}
\ No newline at end of file
Has this version of the diff been clang-formatted?
https://reviews.llvm.org/D33514
_
anemet accepted this revision.
anemet added a comment.
This revision is now accepted and ready to land.
LGTM.
https://reviews.llvm.org/D37196
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-
anemet added a comment.
This caused:
http://green.lab.llvm.org/green/job/clang-stage1-cmake-RA-incremental/56120/consoleFull#1420996271a1ca8a51-895e-46c6-af87-ce24fa4cd561
Please fix or revert.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55382/new/
https://rev
anemet added a comment.
Actually this has been failing for 8 hours. So reverted in r349117. Also
reverted your attempt to update the test. It wasn't updating the right test:
r349118
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55382/new/
https://reviews.llvm
anemet accepted this revision.
anemet added a comment.
This revision is now accepted and ready to land.
LGTM, thanks!
Repository:
rC Clang
https://reviews.llvm.org/D49348
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.o
anemet added a subscriber: davide.
anemet added a comment.
@modocache, @davide, are you guys sure this feature is working? The test does
not actually check whether hotness is included in the remarks and when I run it
manually they are missing. In https://reviews.llvm.org/D40678, I am filtering
anemet added a comment.
Looks like it's a test problem. When I tweak the sample profile file according
to https://clang.llvm.org/docs/UsersManual.html#sample-profile-text-format, I
do get hotness on the remarks.
https://reviews.llvm.org/D34082
__
anemet added a comment.
Sorted these out in https://reviews.llvm.org/rL319576,
https://reviews.llvm.org/rL319577 and https://reviews.llvm.org/rL319578.
https://reviews.llvm.org/D34082
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://l
anemet accepted this revision.
anemet added a comment.
This revision is now accepted and ready to land.
LGTM.
https://reviews.llvm.org/D36949
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-
anemet created this revision.
Sema holds the current FPOptions which is adjusted by 'pragma STDC
FP_CONTRACT'. This then gets propagated into expression nodes as they are
built.
This encapsulates FPOptions so that this propagation happens opaquely rather
than directly with the fp_contractable on
anemet created this revision.
FPContractModeKind is the codegen option flag which is already ternary (off,
on, fast). This makes it universally the type for the contractable info
across the front-end:
- In FPOptions (i.e. in the Sema + in the expression nodes).
- In LangOpts::DefaultFPContractMo
anemet created this revision.
This is toward moving fp-contraction=fast from an LLVM TargetOption to a
FastMathFlag in order to fix PR25721.
https://reviews.llvm.org/D31168
Files:
lib/CodeGen/CGExprScalar.cpp
Index: lib/CodeGen/CGExprScalar.cpp
==
anemet added a comment.
Thanks, Akira. You're right on both accounts. I actually had a test written
but failed to git add it.
https://reviews.llvm.org/D31168
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/ma
anemet updated this revision to Diff 92564.
anemet added a comment.
Address Akira's comments
https://reviews.llvm.org/D31168
Files:
lib/CodeGen/CGExprScalar.cpp
test/CodeGen/ffp-contract-fast-option.c
Index: test/CodeGen/ffp-contract-fast-option.c
=
anemet created this revision.
This adds the new pragma and the first variant, contract_fast.
The pragma has the same block scope rules as STDC FP_CONTRACT, i.e. it can be
placed at the beginning of a compound statement or at file scope.
Similarly to STDC FP_CONTRACT there is no need to use attri
anemet updated this revision to Diff 92825.
anemet marked 4 inline comments as done.
anemet added a comment.
Address Aaron's comments. Also add a code example to the documentation.
https://reviews.llvm.org/D31276
Files:
docs/LanguageExtensions.rst
include/clang/Basic/DiagnosticParseKinds.t
anemet added inline comments.
Comment at: docs/LanguageExtensions.rst:2321
+specified for a section of the source code. This pragma can only appear at
+file scope or at the start of a compound statement. When using within a
+compound statement, the pragma is active within the s
anemet added a comment.
Thanks very much, Aaron! It would be great if you could also look at the three
patches that add support for the generation of the new FMF 'contract' for
-ffp-contract=fast. I've added them in the dependencies of this revision.
(https://reviews.llvm.org/D31168 is not r
anemet added a comment.
In https://reviews.llvm.org/D31276#708976, @aaron.ballman wrote:
> In https://reviews.llvm.org/D31276#708968, @anemet wrote:
>
> > Thanks very much, Aaron! It would be great if you could also look at the
> > three patches that add support for the generation of the new FM
anemet added a comment.
In https://reviews.llvm.org/D31276#708992, @hfinkel wrote:
> High-level comment ;)
>
> #pragma clang fast_math contract_fast(on)
>
>
> This seems a bit unfortunate because 'fast' appears twice? How are we
> planning on naming the other fast-math flags? Maybe we shoul
anemet added a comment.
In https://reviews.llvm.org/D31276#708999, @hfinkel wrote:
> They're definitely on my list. I might not get to them until the weekend or
> next week, however.
Thank you. The schedule is getting tight but that should still work ;).
Actually most of the individual patch
anemet marked 3 inline comments as done.
anemet added inline comments.
Comment at: lib/CodeGen/CGExprScalar.cpp:1712
BinOp.Opcode = IsInc ? BO_Add : BO_Sub;
- BinOp.FPContractable = false;
+ // FIXME: once UnaryOperator carries FPFeatures, copy it here.
BinOp.E = E;
-
anemet updated this revision to Diff 92898.
anemet added a comment.
Address Aaron's comments.
https://reviews.llvm.org/D31166
Files:
include/clang/AST/Expr.h
include/clang/AST/ExprCXX.h
include/clang/Basic/LangOptions.h
include/clang/Sema/Sema.h
lib/AST/ASTImporter.cpp
lib/Analysis/
anemet added a comment.
In https://reviews.llvm.org/D31276#710608, @hfinkel wrote:
> In https://reviews.llvm.org/D31276#709111, @anemet wrote:
>
> > In https://reviews.llvm.org/D31276#708992, @hfinkel wrote:
> >
> > > High-level comment ;)
> > >
> > > #pragma clang fast_math contract_fast(on)
>
This revision was automatically updated to reflect the committed changes.
Closed by commit rL298877: Encapsulate FPOptions and use it consistently
(authored by anemet).
Changed prior to commit:
https://reviews.llvm.org/D31166?vs=92898&id=93166#toc
Repository:
rL LLVM
https://reviews.llvm.or
anemet updated this revision to Diff 93325.
anemet retitled this revision from "Add #pragma clang fp" to "Add #pragma clang
fast_math".
anemet edited the summary of this revision.
anemet added a comment.
Rename pragma from #pragma clang fast_math contract_fast(on/off) -> #pragma
clang fp contrac
anemet added a comment.
(Sorry about updating the title/description back and forth but arcanist is
buggy)
https://reviews.llvm.org/D31276
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com
anemet added inline comments.
Comment at: include/clang/Basic/LangOptions.h:92
+ enum FPContractModeKind {
+FPC_Off,// Form fused FP ops only where result will not be
affected.
+FPC_On, // Form fused FP ops according to FP_CONTRACT rules.
---
This revision was automatically updated to reflect the committed changes.
Closed by commit rL299027: Use FPContractModeKind universally (authored by
anemet).
Changed prior to commit:
https://reviews.llvm.org/D31167?vs=92423&id=93406#toc
Repository:
rL LLVM
https://reviews.llvm.org/D31167
F
anemet added inline comments.
Comment at: cfe/trunk/include/clang/Basic/LangOptions.h:217
/// Adjust BinaryOperator::FPFeatures to match the bit-field size of this.
- unsigned fp_contract : 1;
+ LangOptions::FPContractModeKind fp_contract : 2;
};
rnk wrote:
anemet updated this revision to Diff 93487.
anemet added a comment.
Also add 'contract' for CompoundAssignOperator (+= and -=). For l-values,
these don't go through the expr-visitor in ScalarExprEmitter::Visit. This
again piggybacks on how debug-locations are added.
https://reviews.llvm.org/D3
anemet added a comment.
Ping. This is the only patch in the series now that wasn't approved.
https://reviews.llvm.org/D31168
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
anemet added a comment.
In https://reviews.llvm.org/D31168#716153, @rjmccall wrote:
> I may have missed earlier steps in this patch series. Why is this being done
> statefully and contextually in the IRBuilder instead of just applying the
> flag from the BinaryOperator to the instruction when
anemet updated this revision to Diff 93882.
anemet added a comment.
Address John's comment.
https://reviews.llvm.org/D31168
Files:
lib/CodeGen/CGExprScalar.cpp
test/CodeGen/ffp-contract-fast-option.cpp
Index: test/CodeGen/ffp-contract-fast-option.cpp
==
anemet added a comment.
In https://reviews.llvm.org/D31276#717390, @aaron.ballman wrote:
> This continues to look good to me with the new name.
Thank you, Aaron!
https://reviews.llvm.org/D31276
___
cfe-commits mailing list
cfe-commits@lists.llvm.
anemet added a comment.
Thanks, Aaron! @rjmccall, does it look good to you too?
https://reviews.llvm.org/D31168
___
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 rL299469: Set FMF for -ffp-contract=fast (authored by anemet).
Changed prior to commit:
https://reviews.llvm.org/D31168?vs=93882&id=94121#toc
Repository:
rL LLVM
https://reviews.llvm.org/D31168
Files:
This revision was automatically updated to reflect the committed changes.
Closed by commit rL299470: Add #pragma clang fp (authored by anemet).
Changed prior to commit:
https://reviews.llvm.org/D31276?vs=93325&id=94122#toc
Repository:
rL LLVM
https://reviews.llvm.org/D31276
Files:
cfe/tru
anemet added inline comments.
Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220
+/// \brief FP_CONTRACT mode (on/off/fast).
+ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP
contraction type")
LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field typ
anemet added inline comments.
Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220
+/// \brief FP_CONTRACT mode (on/off/fast).
+ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP
contraction type")
LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field typ
anemet added inline comments.
Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220
+/// \brief FP_CONTRACT mode (on/off/fast).
+ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP
contraction type")
LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field typ
anemet added inline comments.
Comment at: cfe/trunk/include/clang/Basic/LangOptions.def:220
+/// \brief FP_CONTRACT mode (on/off/fast).
+ENUM_LANGOPT(DefaultFPContractMode, FPContractModeKind, 2, FPC_Off, "FP
contraction type")
LANGOPT(NoBitFieldTypeAlign , 1, 0, "bit-field typ
anemet accepted this revision.
anemet added a comment.
This revision is now accepted and ready to land.
LGTM, thanks!
https://reviews.llvm.org/D34865
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listi
anemet added a comment.
Great!
Comment at: docs/UsersManual.rst:330-332
This option, which defaults to off, controls whether Clang prints the
profile hotness associated with a diagnostics in the presence of
profile-guided optimization information. This is currently
anemet accepted this revision.
anemet added a comment.
This revision is now accepted and ready to land.
Looks great, thank you!
https://reviews.llvm.org/D34868
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mai
anemet created this revision.
anemet added reviewers: hfinkel, mehdi_amini.
anemet added a subscriber: cfe-commits.
This is to match the behavior of non-LTO; when -fsave-optmization-record
is passed and PGO is available we enable the generation of hotness
information in the optimization records.
anemet added a comment.
In https://reviews.llvm.org/D27332#611769, @mehdi_amini wrote:
> (You have a typo in the decription, you may want to fix it before commit)
Got it. Thanks for the reviews!
https://reviews.llvm.org/D27332
___
cfe-commits ma
This revision was automatically updated to reflect the committed changes.
Closed by commit rL288520: With LTO and profile-use, enable hotness info in opt
remarks (authored by anemet).
Changed prior to commit:
https://reviews.llvm.org/D27332?vs=80026&id=80088#toc
Repository:
rL LLVM
https://
anemet created this revision.
This restores the behavior prior to https://reviews.llvm.org/D31167 where the
code-gen default was
FPC_On which mapped to FPOpFusion::Standard. After merging the FE
state (on/off) and the code-gen state (on/fast/off), the default became off to
match the front-end.
This revision was automatically updated to reflect the committed changes.
Closed by commit rL300858: Don't pass FPOpFusion::Strict to the backend
(authored by anemet).
Changed prior to commit:
https://reviews.llvm.org/D32301?vs=95979&id=95982#toc
Repository:
rL LLVM
https://reviews.llvm.org
58 matches
Mail list logo