o reduces the size of the generated LLVM IR, but mainly important for LLVM
intrinsics such as llvm.memcpy.*(), as llc complains if some of their
parameters are not constants (you could work around it by first running
opt or by using clang with optimizations so that the constants, which
were loaded in registers until now, were propagated to the intrinsics
by the time llc saw them)
git-svn-id: trunk@32776 -
o while in principle LLVM can layout those the same as we do, this would
require special treatment in case some fields are not initialised in
a typed record declaration (because then we have to emit padding only
for the skipped fields, and not for any padding between them)
o exception: records we create to represent parameters, as those have to
match the ABI definitions exactly for them to be treated as expected
git-svn-id: trunk@32714 -
because the names we assign to parameter locations are no longer valid after
a module has been compiled (they are tasmsymbols), and they're not necessary
for declarations either; this also avoids generating calleeside parameter
information for imported routines just to write the external declaration
(the callerside information will already be available from when the routines
were called)
git-svn-id: trunk@32518 -
a code and temp generator for the architectural target instead of for LLVM
* write the code for pure assembler routines using a GNU-style external
assembler writer for the target, with a decorator to wrap it in
LLVM module-level assembly statements
git-svn-id: trunk@31633 -
defined) or a declaration (external symbol), instead of deriving it from
from the bind of the tasmsymbol. The reason is that with module-level
inline assembly, some locally implemented functions (in pure assembler)
won't have an LLVM IR body
git-svn-id: trunk@31629 -
that we can use assembler writers with different conventions from the
currently set target_asm (e.g. an x86 assembler writer for inline assembly
in LLVM IR)
git-svn-id: trunk@31628 -
linkage types for aliases (or its documentation hasn't been updated), and
external linkage is the default so it doesn't matter for earlier versions
git-svn-id: trunk@31284 -
because due to aliasing symbols a single symbol may be called using
different procdefs (e.g. FPC_ANSISTR_UNIQUE in the system unit is defined
as an alias for a function and called as a procedure). This means we have
to insert extra type conversions for llvm, which requires both the source
and destination type
git-svn-id: trunk@30776 -
handle recursive record references (rec= record prec: ^rec)
o llvm unfortunately does not support recursive references to array types
or function pointers, so those will currently still result in endless
recursion when the compiler tries to write them out. Solving those
will require a lot of typecasting in the generated code
git-svn-id: trunk@30675 -
assembler writer, and for now skip writing labels if we are (they
will have to emitted as part of an actual inline assembly block,
not as llvm-style labels)
git-svn-id: trunk@30672 -
procdef.getcopyas(procvardef,pc_address_only) as the def if we want to
specify that we're interested in the address of a procedure/procvar of
object
git-svn-id: branches/hlcgllvm@28476 -
llvm
* instead, add LLVM-specific name mangling based on the asmsymbol's bind
and typ whenever we write out its name
git-svn-id: branches/hlcgllvm@28166 -
o remove the accompanying tdef operands from tai operands, because such
tai operands should have a tdef already
o check that every queued tai is a tai_simpletypedconst (which have a
type)
o wrap queued bitcast/getelementptr tai instances with a
tai_simpletypedconst
git-svn-id: branches/hlcgllvm@28154 -
rather than first concatenating everything, because in case of
instructions that have other tai as operands we have to ensure that
all previous output is flushed before the tai-operand is evaluated
(and written/flushed)
git-svn-id: branches/hlcgllvm@28125 -