History log of /llvm-project-15.0.7/clang/lib/CodeGen/CGExpr.cpp (Results 501 – 525 of 1262)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# e7b3d5dc 27-May-2014 Renato Golin <[email protected]>

Revert small change to EmitDeclRefLValue

That small change, although it looked harmless, it made emitting the LValue
on the PHI node without the proper cast. Reverting it fixes PR19841.

llvm-svn: 2

Revert small change to EmitDeclRefLValue

That small change, although it looked harmless, it made emitting the LValue
on the PHI node without the proper cast. Reverting it fixes PR19841.

llvm-svn: 209663

show more ...


# 5c2b4ea6 23-May-2014 Warren Hunt <[email protected]>

[MS-ABI] Implements MS-compatible RTTI
Enables the emission of MS-compatible RTTI data structures for use with
typeid, dynamic_cast and exceptions. Does not implement dynamic_cast
or exceptions.

[MS-ABI] Implements MS-compatible RTTI
Enables the emission of MS-compatible RTTI data structures for use with
typeid, dynamic_cast and exceptions. Does not implement dynamic_cast
or exceptions. As an artiface, typeid works in some cases but proper
support an testing will coming in a subsequent patch.

majnemer has fuzzed the results. Test cases included.

Differential Revision: http://reviews.llvm.org/D3833

llvm-svn: 209523

show more ...


# 8a13c418 21-May-2014 Craig Topper <[email protected]>

[C++11] Use 'nullptr'. CodeGen edition.

llvm-svn: 209272


# c9e2a689 20-May-2014 Eric Christopher <[email protected]>

Clean up language and grammar.

Based on a patch by [email protected]!
PR19806

llvm-svn: 209215


# c296d951 19-May-2014 Renato Golin <[email protected]>

Using SmallString and correct addr var

llvm-svn: 209180


# 156a853c 19-May-2014 Renato Golin <[email protected]>

Fix usage of string when StringRef was needed

Also adding a variable to the test, so release bots match %1.
This should also calm the gdb buildbot.

.

llvm-svn: 209171


# 230c5eb4 19-May-2014 Renato Golin <[email protected]>

Non-allocatable Global Named Register

This patch implements global named registers in Clang, lowering to the just
created intrinsics in LLVM (@llvm.read/write_register). A new type of LValue
had to

Non-allocatable Global Named Register

This patch implements global named registers in Clang, lowering to the just
created intrinsics in LLVM (@llvm.read/write_register). A new type of LValue
had to be created (Register), which just adds support to carry the metadata
node containing the name of the register. Two new methods to emit loads and
stores interoperate with another to emit the named metadata node.

No guarantees are being made and only non-allocatable global variable named
registers are being supported. Local named register support is unchanged.

llvm-svn: 209149

show more ...


Revision tags: llvmorg-3.4.2, llvmorg-3.4.2-rc1
# 9c8821bb 10-May-2014 David Blaikie <[email protected]>

Add FIXME describing the limitation of using column info to disambiguate inlining.

Also tidy up, simplify, and extend the test coverage to demonstrate the
limitations. This test should now fail if t

Add FIXME describing the limitation of using column info to disambiguate inlining.

Also tidy up, simplify, and extend the test coverage to demonstrate the
limitations. This test should now fail if the bugs are fixed (&
hopefully whoever ends up in this situation sees the FIXMEs and realizes
that the test needs to be updated to positively test their change that
has fixed some or all of these issues).

I do wonder whether I could demonstrate breakage without a macro here,
but any way I slice it I can't think of a way to get two calls to the
same function on the same line/column in non-macro C++ - implicit
conversions happen at the same location as an explicit function, but
you'd never get an implicit conversion on the result of an explicit call
to the same implicit conversion operator (since the value is already
converted to the desired result)...

llvm-svn: 208468

show more ...


# 2ae250c3 09-May-2014 Rafael Espindola <[email protected]>

Use auto to avoid duplicating the type.

llvm-svn: 208374


Revision tags: llvmorg-3.4.1, llvmorg-3.4.1-rc2, llvmorg-3.4.1-rc1
# 52edddae 08-Apr-2014 Reid Kleckner <[email protected]>

Add support for MSVC's __FUNCSIG__

It is very similar to GCC's __PRETTY_FUNCTION__, except it prints the
calling convention.

Reviewers: majnemer

Differential Revision: http://reviews.llvm.org/D331

Add support for MSVC's __FUNCSIG__

It is very similar to GCC's __PRETTY_FUNCTION__, except it prints the
calling convention.

Reviewers: majnemer

Differential Revision: http://reviews.llvm.org/D3311

llvm-svn: 205780

show more ...


# 0f38374f 26-Mar-2014 Richard Smith <[email protected]>

PR19254: If a thread_local data member of a class is accessed via member access
syntax, don't forget to run its initializer.

llvm-svn: 204869


# 2b0d66df 20-Feb-2014 David Majnemer <[email protected]>

Sema: Do not assert when dereferencing member pointer using virtual inheritance with an incomplete class type

The MS ABI requires that we determine the vbptr offset if have a
virtual inheritance mod

Sema: Do not assert when dereferencing member pointer using virtual inheritance with an incomplete class type

The MS ABI requires that we determine the vbptr offset if have a
virtual inheritance model. Instead, raise an error pointing to the
diagnostic when this happens.

This fixes PR18583.

Differential Revision: http://llvm-reviews.chandlerc.com/D2842

llvm-svn: 201824

show more ...


# bf854f0f 17-Feb-2014 Bob Wilson <[email protected]>

Change PGO instrumentation to compute counts in a separate AST traversal.

Previously, we made one traversal of the AST prior to codegen to assign
counters to the ASTs and then propagated the count v

Change PGO instrumentation to compute counts in a separate AST traversal.

Previously, we made one traversal of the AST prior to codegen to assign
counters to the ASTs and then propagated the count values during codegen. This
patch now adds a separate AST traversal prior to codegen for the
-fprofile-instr-use option to propagate the count values. The counts are then
saved in a map from which they can be retrieved during codegen.

This new approach has several advantages:

1. It gets rid of a lot of extra PGO-related code that had previously been
added to codegen.

2. It fixes a serious bug. My original implementation (which was mailed to the
list but never committed) used 3 counters for every loop. Justin improved it to
move 2 of those counters into the less-frequently executed breaks and continues,
but that turned out to produce wrong count values in some cases. The solution
requires visiting a loop body before the condition so that the count for the
condition properly includes the break and continue counts. Changing codegen to
visit a loop body first would be a fairly invasive change, but with a separate
AST traversal, it is easy to control the order of traversal. I've added a
testcase (provided by Justin) to make sure this works correctly.

3. It improves the instrumentation overhead, reducing the number of counters for
a loop from 3 to 1. We no longer need dedicated counters for breaks and
continues, since we can just use the propagated count values when visiting
breaks and continues.

To make this work, I needed to make a change to the way we count case
statements, going back to my original approach of not including the fall-through
in the counter values. This was necessary because there isn't always an AST node
that can be used to record the fall-through count. Now case statements are
handled the same as default statements, with the fall-through paths branching
over the counter increments. While I was at it, I also went back to using this
approach for do-loops -- omitting the fall-through count into the loop body
simplifies some of the calculations and make them behave the same as other
loops. Whenever we start using this instrumentation for coverage, we'll need
to add the fall-through counts into the counter values.

llvm-svn: 201528

show more ...


# 314cc81b 25-Jan-2014 Alp Toker <[email protected]>

Rename getResultType() on function and method declarations to getReturnType()

A return type is the declared or deduced part of the function type specified in
the declaration.

A result type is the (

Rename getResultType() on function and method declarations to getReturnType()

A return type is the declared or deduced part of the function type specified in
the declaration.

A result type is the (potentially adjusted) type of the value of an expression
that calls the function.

Rule of thumb:

* Declarations have return types and parameters.
* Expressions have result types and arguments.

llvm-svn: 200082

show more ...


# 0718a3a4 13-Jan-2014 Justin Bogner <[email protected]>

CodeGen: Rename adjustFallThroughCount -> adjustForControlFlow

adjustFallThroughCount isn't a good name, and the documentation was
even worse. This commit attempts to clarify what it's for and when

CodeGen: Rename adjustFallThroughCount -> adjustForControlFlow

adjustFallThroughCount isn't a good name, and the documentation was
even worse. This commit attempts to clarify what it's for and when to
use it.

llvm-svn: 199139

show more ...


# ea278c32 07-Jan-2014 Justin Bogner <[email protected]>

CodeGen: Sentences end with a period

llvm-svn: 198649


# ef512b99 06-Jan-2014 Justin Bogner <[email protected]>

CodeGen: Initial instrumentation based PGO implementation

llvm-svn: 198640


Revision tags: llvmorg-3.4.0, llvmorg-3.4.0-rc3
# e1468322 11-Dec-2013 David Tweed <[email protected]>

Add front-end infrastructure now address space casts are in LLVM IR.

With the introduction of explicit address space casts into LLVM, there's
a need to provide a new cast kind the front-end can crea

Add front-end infrastructure now address space casts are in LLVM IR.

With the introduction of explicit address space casts into LLVM, there's
a need to provide a new cast kind the front-end can create for C/OpenCL/CUDA
and code to produce address space casts from those kinds when appropriate.

Patch by Michele Scandale!

llvm-svn: 197036

show more ...


Revision tags: llvmorg-3.4.0-rc2
# cf4143b5 21-Nov-2013 Joey Gouly <[email protected]>

Fix a crash in EmitStoreThroughExtVectorComponentLValue for vectors of odd sizes.

In OpenCL a vector of 3 elements, acts like a vector of four elements.
So for a vector of size 3 the '.hi' and '.odd

Fix a crash in EmitStoreThroughExtVectorComponentLValue for vectors of odd sizes.

In OpenCL a vector of 3 elements, acts like a vector of four elements.
So for a vector of size 3 the '.hi' and '.odd' accessors, would access
the elements {2, 3} and {1, 3} respectively.
However, in EmitStoreThroughExtVectorComponentLValue we are still operating on
a vector of size 3, so we should only access {2} and {1}. We do this by checking
the last element to be accessed, and ignore it if it is out-of-bounds.

EmitLoadOfExtVectorElementLValue doesn't have a similar problem, because it does
a direct shufflevector with undef, so an out-of-bounds access just gives an undef
value.

Patch by Anastasia Stulova!

llvm-svn: 195367

show more ...


Revision tags: llvmorg-3.4.0-rc1
# 949ec546 08-Nov-2013 Will Dietz <[email protected]>

ubsan: Only emit constants for filenames and type descriptors once.

Produces neater IR in significantly less time.

(~18% faster -O0 compile time for sqlite3 with -fsanitize=undefined)

llvm-svn: 19

ubsan: Only emit constants for filenames and type descriptors once.

Produces neater IR in significantly less time.

(~18% faster -O0 compile time for sqlite3 with -fsanitize=undefined)

llvm-svn: 194231

show more ...


# bed356a9 06-Nov-2013 David Majnemer <[email protected]>

[-fms-extensions] Add support for __FUNCDNAME__

Summary:
Similar to __FUNCTION__, MSVC exposes the name of the enclosing mangled
function name via __FUNCDNAME__. This implementation is very naive a

[-fms-extensions] Add support for __FUNCDNAME__

Summary:
Similar to __FUNCTION__, MSVC exposes the name of the enclosing mangled
function name via __FUNCDNAME__. This implementation is very naive and
unoptimized, it is expected that __FUNCDNAME__ would be used rarely in
practice.

Reviewers: rnk, rsmith, thakis

CC: cfe-commits, silvas

Differential Revision: http://llvm-reviews.chandlerc.com/D2109

llvm-svn: 194181

show more ...


# b47c36f8 05-Nov-2013 Richard Smith <[email protected]>

C++1y sized deallocation: if we have a use, but not a definition, of a sized
deallocation function (and the corresponding unsized deallocation function has
been declared), emit a weak discardable def

C++1y sized deallocation: if we have a use, but not a definition, of a sized
deallocation function (and the corresponding unsized deallocation function has
been declared), emit a weak discardable definition of the function that
forwards to the corresponding unsized deallocation.

This allows a C++ standard library implementation to provide both a sized and
an unsized deallocation function, where the unsized one does not just call the
sized one, for instance by putting both in the same object file within an
archive.

llvm-svn: 194055

show more ...


# 6b53e224 22-Oct-2013 Richard Smith <[email protected]>

Split -fsanitize=bounds to -fsanitize=array-bounds (for the frontend-inserted
check using the ubsan runtime) and -fsanitize=local-bounds (for the middle-end
check which inserts traps).

Remove -fsani

Split -fsanitize=bounds to -fsanitize=array-bounds (for the frontend-inserted
check using the ubsan runtime) and -fsanitize=local-bounds (for the middle-end
check which inserts traps).

Remove -fsanitize=local-bounds from -fsanitize=undefined. It does not produce
useful diagnostics and has false positives (PR17635), and is not a good
compromise position between UBSan's checks and ASan's checks.

Map -fbounds-checking to -fsanitize=local-bounds to restore Clang's historical
behavior for that flag.

llvm-svn: 193205

show more ...


# b453cd64 20-Oct-2013 Peter Collingbourne <[email protected]>

Implement function type checker for the undefined behavior sanitizer.

This uses function prefix data to store function type information at the
function pointer.

Differential Revision: http://llvm-r

Implement function type checker for the undefined behavior sanitizer.

This uses function prefix data to store function type information at the
function pointer.

Differential Revision: http://llvm-reviews.chandlerc.com/D1338

llvm-svn: 193058

show more ...


# 4f755dea 08-Oct-2013 Manman Ren <[email protected]>

TBAA: use the same format for scalar TBAA and struct-path aware TBAA.

An updated version of r191586 with bug fix.

Struct-path aware TBAA generates tags to specify the access path,
while scalar TBAA

TBAA: use the same format for scalar TBAA and struct-path aware TBAA.

An updated version of r191586 with bug fix.

Struct-path aware TBAA generates tags to specify the access path,
while scalar TBAA only generates tags to scalar types.

We should not generate a TBAA tag with null being the first field. When
a TBAA type node is null, the tag should be null too. Make sure we
don't decorate an instruction with a null TBAA tag.

Added a testing case for the bug reported by Richard with -relaxed-aliasing
and -fsanitizer=thread.

llvm-svn: 192145

show more ...


1...<<21222324252627282930>>...51