oota-llvm.git
16 years agoDon't add a default STACK_ALIGN (use the generic ABI alignment)
Rafael Espindola [Fri, 21 Sep 2007 15:50:22 +0000 (15:50 +0000)]
Don't add a default STACK_ALIGN (use the generic ABI alignment)
Implement calls to functions with byval arguments on X86

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42192 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoThere is no {rsqrt,rcp}{p,s}d.
Dan Gohman [Fri, 21 Sep 2007 15:24:00 +0000 (15:24 +0000)]
There is no {rsqrt,rcp}{p,s}d.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42190 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agosmall cleanup: use LowerMemArgument in LowerFastCCArguments also
Rafael Espindola [Fri, 21 Sep 2007 14:55:38 +0000 (14:55 +0000)]
small cleanup: use LowerMemArgument in LowerFastCCArguments also

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42189 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoInitial hack at 2.1 release notes.
Chris Lattner [Fri, 21 Sep 2007 03:54:09 +0000 (03:54 +0000)]
Initial hack at 2.1 release notes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42186 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd partial caching of non-local memory dependence queries. This provides a modest
Owen Anderson [Fri, 21 Sep 2007 03:53:52 +0000 (03:53 +0000)]
Add partial caching of non-local memory dependence queries.  This provides a modest
speedup for GVN.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42185 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoHonor user-defined section specification of a global, ignores whether its initializer...
Evan Cheng [Fri, 21 Sep 2007 00:41:19 +0000 (00:41 +0000)]
Honor user-defined section specification of a global, ignores whether its initializer is null.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42182 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix PR 1688. See comments there.
Dale Johannesen [Thu, 20 Sep 2007 23:47:58 +0000 (23:47 +0000)]
Fix PR 1688.  See comments there.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42181 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUpdate aux. info associated with an instruction before erasing instruction.
Devang Patel [Thu, 20 Sep 2007 23:45:50 +0000 (23:45 +0000)]
Update aux. info associated with an instruction before erasing instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42180 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDo not override user specified section.
Devang Patel [Thu, 20 Sep 2007 23:07:37 +0000 (23:07 +0000)]
Do not override user specified section.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42179 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDon't increment invalid iterator.
Devang Patel [Thu, 20 Sep 2007 23:01:50 +0000 (23:01 +0000)]
Don't increment invalid iterator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42178 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoTestcase for PR1678.
Duncan Sands [Thu, 20 Sep 2007 18:56:24 +0000 (18:56 +0000)]
Testcase for PR1678.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42171 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDisable if-conversion for this test.
Evan Cheng [Thu, 20 Sep 2007 18:06:22 +0000 (18:06 +0000)]
Disable if-conversion for this test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42170 91177308-0d34-0410-b5e6-96231b3b80d8

16 years ago-enable-arm-if-conversion is gone.
Evan Cheng [Thu, 20 Sep 2007 18:03:23 +0000 (18:03 +0000)]
-enable-arm-if-conversion is gone.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42169 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix dumb regression in constant folding (Regression/C/casts)
Dale Johannesen [Thu, 20 Sep 2007 16:50:21 +0000 (16:50 +0000)]
Fix dumb regression in constant folding (Regression/C/casts)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42165 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRegenerate.
Gordon Henriksen [Thu, 20 Sep 2007 16:48:18 +0000 (16:48 +0000)]
Regenerate.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42164 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoIncorporating review feedback for GC verifier patch.
Gordon Henriksen [Thu, 20 Sep 2007 16:47:41 +0000 (16:47 +0000)]
Incorporating review feedback for GC verifier patch.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42163 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix several more entries in the x86 reload/remat folding tables.
Dan Gohman [Thu, 20 Sep 2007 14:17:21 +0000 (14:17 +0000)]
Fix several more entries in the x86 reload/remat folding tables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42162 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agouse typenames equivalent to
Gabor Greif [Thu, 20 Sep 2007 10:20:34 +0000 (10:20 +0000)]
use typenames equivalent to
(u)intval, because latter are not
present in older caml/mlvalues.h
(e.g. 2004/07/07, 1.48.6.1)

Using this as a workaround for now,
until --without-ocaml works
or we settle on a better solution

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42160 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoanother long double buglet
Dale Johannesen [Thu, 20 Sep 2007 01:27:54 +0000 (01:27 +0000)]
another long double buglet

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42159 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoExcuse me.
Nick Lewycky [Thu, 20 Sep 2007 00:57:00 +0000 (00:57 +0000)]
Excuse me.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42158 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix optimization. %x = sub %x, %y does not imply that %y is zero.
Nick Lewycky [Thu, 20 Sep 2007 00:48:36 +0000 (00:48 +0000)]
Fix optimization. %x = sub %x, %y does not imply that %y is zero.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42157 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoEnable if-conversion for ARM by default.
Evan Cheng [Thu, 20 Sep 2007 00:48:22 +0000 (00:48 +0000)]
Enable if-conversion for ARM by default.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42156 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMore long double fixes. x86_64 should build now.
Dale Johannesen [Wed, 19 Sep 2007 23:55:34 +0000 (23:55 +0000)]
More long double fixes.  x86_64 should build now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42155 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAvoid referencing deleted instruction.
Evan Cheng [Wed, 19 Sep 2007 21:48:07 +0000 (21:48 +0000)]
Avoid referencing deleted instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42153 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoPreviously GraphWriter assumed operator*() for node_iterator always
Ted Kremenek [Wed, 19 Sep 2007 21:26:49 +0000 (21:26 +0000)]
Previously GraphWriter assumed operator*() for node_iterator always
returned a reference type.  This patch allows operator*() to return a
non-reference type while still maintaining the old behavior when it
does return a reference type.

This patch was motivated when I tried to use "df_iterator" (see
llvm/ADT/DepthFirstIterator.h) as a "node_iterator", as df_iterator
does not return a reference type and thus we would get a compilation
error when trying to take the address of a temporary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42151 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAvoid unsafe promotion.
Devang Patel [Wed, 19 Sep 2007 20:18:51 +0000 (20:18 +0000)]
Avoid unsafe promotion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42149 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoPSHUFDmi, etc. are actually folding a load, not a store.
Evan Cheng [Wed, 19 Sep 2007 19:02:47 +0000 (19:02 +0000)]
PSHUFDmi, etc. are actually folding a load, not a store.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42147 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix longdouble -> uint conversion.
Dale Johannesen [Wed, 19 Sep 2007 17:53:26 +0000 (17:53 +0000)]
Fix longdouble -> uint conversion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42143 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoreject things like "declare internal @foo"
Chris Lattner [Wed, 19 Sep 2007 17:14:45 +0000 (17:14 +0000)]
reject things like "declare internal @foo"

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42140 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd a flag to mark a dirty cache entry. This is not yet used, but will eventually
Owen Anderson [Wed, 19 Sep 2007 16:13:57 +0000 (16:13 +0000)]
Add a flag to mark a dirty cache entry.  This is not yet used, but will eventually
help non-local memdep caching.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42137 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix some long double issues.
Dale Johannesen [Wed, 19 Sep 2007 14:22:58 +0000 (14:22 +0000)]
Fix some long double issues.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42133 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoImprove comment.
Duncan Sands [Wed, 19 Sep 2007 10:25:38 +0000 (10:25 +0000)]
Improve comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42132 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoPartial fix for PR1678: correct some parts of constant
Duncan Sands [Wed, 19 Sep 2007 10:16:17 +0000 (10:16 +0000)]
Partial fix for PR1678: correct some parts of constant
fold that were missed in the fix for PR1646.  Probably
this null/not-null logic should be factorized somewhere.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42131 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoA global variable with external weak linkage can be null, while
Duncan Sands [Wed, 19 Sep 2007 10:10:31 +0000 (10:10 +0000)]
A global variable with external weak linkage can be null, while
an alias could alias such a global variable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42130 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoinclude alloca.h if available. this helps Solaris, but intnat and uintnat types are...
Gabor Greif [Wed, 19 Sep 2007 09:29:58 +0000 (09:29 +0000)]
include alloca.h if available. this helps Solaris, but intnat and uintnat types are still undefined, causing errors

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42129 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoTestcase for PR1678.
Duncan Sands [Wed, 19 Sep 2007 07:43:17 +0000 (07:43 +0000)]
Testcase for PR1678.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42128 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUse struct SDep instead of std::pair for SUnit pred and succ lists. First step
Evan Cheng [Wed, 19 Sep 2007 01:38:40 +0000 (01:38 +0000)]
Use struct SDep instead of std::pair for SUnit pred and succ lists. First step
in tracking physical register output dependencies.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42125 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoSet CCR (EFLAGS) copy cost to -1, i.e. extremely expensive to copy.
Evan Cheng [Wed, 19 Sep 2007 01:36:39 +0000 (01:36 +0000)]
Set CCR (EFLAGS) copy cost to -1, i.e. extremely expensive to copy.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42124 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd CopyCost to TargetRegisterClass. This specifies the cost of copying a value
Evan Cheng [Wed, 19 Sep 2007 01:35:01 +0000 (01:35 +0000)]
Add CopyCost to TargetRegisterClass. This specifies the cost of copying a value
between two registers in the specific class.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42123 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRelax loop ExitCondition predicate restriction.
Devang Patel [Wed, 19 Sep 2007 00:28:47 +0000 (00:28 +0000)]
Relax loop ExitCondition predicate restriction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42122 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFilter loops where split condition's false branch is not empty. For example
Devang Patel [Wed, 19 Sep 2007 00:15:16 +0000 (00:15 +0000)]
Filter loops where split condition's false branch is not empty. For example
for (int i = 0; i < N; ++i) {
  if (i == somevalue)
    dosomething();
   else
    dosomethingelse();
}

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42121 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoBail out early, before modifying anything.
Devang Patel [Wed, 19 Sep 2007 00:11:01 +0000 (00:11 +0000)]
Bail out early, before modifying anything.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42120 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoWork is incomplete. Loop is not modified at all right now.
Devang Patel [Wed, 19 Sep 2007 00:08:13 +0000 (00:08 +0000)]
Work is incomplete. Loop is not modified at all right now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42119 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoooops...
Devang Patel [Tue, 18 Sep 2007 23:58:14 +0000 (23:58 +0000)]
ooops...

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42118 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoClean up.
Evan Cheng [Tue, 18 Sep 2007 22:56:31 +0000 (22:56 +0000)]
Clean up.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42112 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix a bogus splat xform:
Evan Cheng [Tue, 18 Sep 2007 21:54:37 +0000 (21:54 +0000)]
Fix a bogus splat xform:
shuffle <undef, undef, x, undef>, <undef, undef, undef, undef>, <2, 2, 2, 2>
!=
<undef, undef, x, undef>

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42111 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agorename test, it is obviously misspelled
Gabor Greif [Tue, 18 Sep 2007 21:42:39 +0000 (21:42 +0000)]
rename test, it is obviously misspelled

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42108 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoPrevent crash on long double.
Dale Johannesen [Tue, 18 Sep 2007 18:36:59 +0000 (18:36 +0000)]
Prevent crash on long double.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42103 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoTests of the ocaml (and thus C) bindings for constants.
Gordon Henriksen [Tue, 18 Sep 2007 18:07:51 +0000 (18:07 +0000)]
Tests of the ocaml (and thus C) bindings for constants.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42101 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMove the entries for 64-bit CMP, IMUL, and a few others into the correct
Dan Gohman [Tue, 18 Sep 2007 14:59:14 +0000 (14:59 +0000)]
Move the entries for 64-bit CMP, IMUL, and a few others into the correct
tables so that they are eligible for reload/remat folding. And add
entries for JMP and CALL.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42094 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdding ocaml language bindings for the vmcore and bitwriter libraries. These are
Gordon Henriksen [Tue, 18 Sep 2007 12:49:39 +0000 (12:49 +0000)]
Adding ocaml language bindings for the vmcore and bitwriter libraries. These are
built atop the C language bindings, and user programs can link with them as
such:

  # Bytecode
  ocamlc -cc g++ llvm.cma llvmbitwriter.cma -o example example.ml
  # Native
  ocamlopt -cc g++ llvm.cmxa llvmbitwriter.cmxa -o example.opt example.ml

The vmcore.ml test exercises most/all of the APIs thus far bound. Unfortunately,
they're not yet numerous enough to write hello world. But:

  $ cat example.ml
  (* example.ml *)

  open Llvm
  open Llvm_bitwriter

  let _ =
    let filename = Sys.argv.(1) in
    let m = create_module filename in

    let v = make_int_constant i32_type 42 false in
    let g = define_global "hello_world" v m in

    if not (write_bitcode_file m filename) then exit 1;

    dispose_module m;

  $ ocamlc -cc g++ llvm.cma llvm_bitwriter.cma -o example example.ml
  File "example.ml", line 11, characters 6-7:
  Warning Y: unused variable g.
  $ ./example example.bc
  $ llvm-dis < example.bc
  ; ModuleID = '<stdin>'
  @hello_world = global i32 42            ; <i32*> [#uses=0]

The ocaml test cases provide effective tests for the C interfaces.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42093 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRegenerate.
Gordon Henriksen [Tue, 18 Sep 2007 12:27:13 +0000 (12:27 +0000)]
Regenerate.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42092 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agogit-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42091 91177308-0d34-0410...
Gordon Henriksen [Tue, 18 Sep 2007 12:26:59 +0000 (12:26 +0000)]
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42091 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agogit-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42090 91177308-0d34-0410...
Gordon Henriksen [Tue, 18 Sep 2007 12:26:17 +0000 (12:26 +0000)]
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42090 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoIncorporating review feedback for GC verifier patch.
Gordon Henriksen [Tue, 18 Sep 2007 10:14:30 +0000 (10:14 +0000)]
Incorporating review feedback for GC verifier patch.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42087 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDon't pass back a reference to a temporary.
Bill Wendling [Tue, 18 Sep 2007 09:10:16 +0000 (09:10 +0000)]
Don't pass back a reference to a temporary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42086 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUpdate my entry.
Bill Wendling [Tue, 18 Sep 2007 05:28:19 +0000 (05:28 +0000)]
Update my entry.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42079 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoThe exception handling function info should be reset for each new
Bill Wendling [Tue, 18 Sep 2007 05:03:44 +0000 (05:03 +0000)]
The exception handling function info should be reset for each new
function. The information isn't used heavily -- it's only used at the end
of exception handling emission -- so there's no need to cache it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42078 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoC bindings for libLLVMCore.a and libLLVMBitWriter.a.
Gordon Henriksen [Tue, 18 Sep 2007 03:18:57 +0000 (03:18 +0000)]
C bindings for libLLVMCore.a and libLLVMBitWriter.a.

- The naming prefix is LLVM.
- All types are represented using opaque references.
- Functions are not named LLVM{Type}{Method}; the names became
  unreadable goop. Instead, they are named LLVM{ImperativeSentence}.
- Where an attribute only appears once in the class hierarchy (e.g.,
  linkage only applies to values; parameter types only apply to
  function types), the class is omitted from identifiers for
  brevity. Tastes like methods.
- Strings are C strings or string/length tuples on a case-by-case
  basis.
- APIs which give the caller ownership of an object are not mapped
  (removeFromParent, certain constructor overloads). This keeps
  keep memory management as simple as possible.

For each library with bindings:

  llvm-c/<LIB>.h       - Declares the bindings.
  lib/<LIB>/<LIB>.cpp  - Implements the bindings.

So just link with the library of your choice and use the C header
instead of the C++ one.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42077 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFixing an comment in Module.h that refers to a nonexistent parameter.
Gordon Henriksen [Tue, 18 Sep 2007 02:09:34 +0000 (02:09 +0000)]
Fixing an comment in Module.h that refers to a nonexistent parameter.

Also adding some missing svn:ignores that've been bothering me.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42076 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix PR1657
Devang Patel [Tue, 18 Sep 2007 01:54:42 +0000 (01:54 +0000)]
Fix PR1657

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42075 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoObjective-C was generating EH frame info like this:
Bill Wendling [Tue, 18 Sep 2007 01:47:22 +0000 (01:47 +0000)]
Objective-C was generating EH frame info like this:

"_-[NSString(local) isNullOrNil]".eh = 0
        .no_dead_strip  "_-[NSString(local) isNullOrNil]".eh

The ".eh" should be inside the quotes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42074 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd support for appending a suffix to the end of a mangled name.
Bill Wendling [Mon, 17 Sep 2007 22:39:32 +0000 (22:39 +0000)]
Add support for appending a suffix to the end of a mangled name.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42071 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoBug fix and minor clean up of generated code.
Evan Cheng [Mon, 17 Sep 2007 22:26:41 +0000 (22:26 +0000)]
Bug fix and minor clean up of generated code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42069 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDo not hide APInt::dump() inside #ifndef NDEBUG.
Devang Patel [Mon, 17 Sep 2007 22:24:00 +0000 (22:24 +0000)]
Do not hide APInt::dump() inside #ifndef NDEBUG.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42068 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix broken default help strings for enable-shared, enable-static, and enable-fast...
Tanya Lattner [Mon, 17 Sep 2007 21:41:15 +0000 (21:41 +0000)]
Fix broken default help strings for enable-shared, enable-static, and enable-fast-install. Regenerate configure script.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42066 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDo not eliminate loop when it is invalid to do so. For example,
Devang Patel [Mon, 17 Sep 2007 21:01:05 +0000 (21:01 +0000)]
Do not eliminate loop when it is invalid to do so. For example,
for(int i = 0; i < N; i++) {
if ( i == XYZ) {
A;
else
B;
}
C;
D;
}

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42058 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoSkeleton for transformations to truncate loop's iteration space.
Devang Patel [Mon, 17 Sep 2007 20:39:48 +0000 (20:39 +0000)]
Skeleton for transformations to truncate loop's iteration space.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42054 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix for PR1633: Verifier doesn't fully verify GC intrinsics
Gordon Henriksen [Mon, 17 Sep 2007 20:30:04 +0000 (20:30 +0000)]
Fix for PR1633: Verifier doesn't fully verify GC intrinsics

LLVM now enforces the following prototypes for the write barriers:

<ty>* @llvm.gcread(<ty2>*, <ty>**)
void @llvm.gcwrite(<ty>*, <ty2>*, <ty>**)

And for @llvm.gcroot, the first stack slot is verified to be an alloca or a
bitcast of an alloca.

Fixes test/CodeGen/Generic/GC/lower_gcroot.ll, which violated these.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42051 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRemove RSTRegClass case from loadRegFromStackSlot
Dale Johannesen [Mon, 17 Sep 2007 20:15:38 +0000 (20:15 +0000)]
Remove RSTRegClass case from loadRegFromStackSlot
and storeRegToStackSlot.  Evan and I concluded this
should never be needed and it appears to be true.
(It if is needed, adjustment would be needed for
long double to work.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42049 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix comment.
Devang Patel [Mon, 17 Sep 2007 20:07:40 +0000 (20:07 +0000)]
Fix comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42048 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoThis is not ideal but unbreaks build failure.
Devang Patel [Mon, 17 Sep 2007 20:03:03 +0000 (20:03 +0000)]
This is not ideal but unbreaks build failure.
APInt::dump() is inside #ifndef NDEBUG, however SelectionDAG dump() routines are not.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42047 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoImplement x86 long double in jit (not really
Dale Johannesen [Mon, 17 Sep 2007 18:44:13 +0000 (18:44 +0000)]
Implement x86 long double in jit (not really
complete, but common cases work)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42043 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMerge DenseMapKeyInfo & DenseMapValueInfo into DenseMapInfo
Chris Lattner [Mon, 17 Sep 2007 18:34:04 +0000 (18:34 +0000)]
Merge DenseMapKeyInfo & DenseMapValueInfo into DenseMapInfo

Add a new DenseMapInfo::isEqual method to allow clients to redefine
the equality predicate used when probing the hash table.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42042 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoThat's what i get for using carbon emacs in a terminal
Daniel Berlin [Mon, 17 Sep 2007 18:05:59 +0000 (18:05 +0000)]
That's what i get for using carbon emacs in a terminal

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42040 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix iterator so it doesn't sometimes report bits that aren't in the bitmap
Daniel Berlin [Mon, 17 Sep 2007 18:04:21 +0000 (18:04 +0000)]
Fix iterator so it doesn't sometimes report bits that aren't in the bitmap

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42039 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd a utility function to SDOperand for testing if a value is unused.
Dan Gohman [Mon, 17 Sep 2007 17:44:31 +0000 (17:44 +0000)]
Add a utility function to SDOperand for testing if a value is unused.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42038 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoX86ISD::TEST is dead.
Evan Cheng [Mon, 17 Sep 2007 17:42:53 +0000 (17:42 +0000)]
X86ISD::TEST is dead.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42037 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoregenerate
Chris Lattner [Mon, 17 Sep 2007 17:40:48 +0000 (17:40 +0000)]
regenerate

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42036 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoInstcombine x-((x/y)*y) into a remainder operator.
Dan Gohman [Mon, 17 Sep 2007 17:31:57 +0000 (17:31 +0000)]
Instcombine x-((x/y)*y) into a remainder operator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42035 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdding myself to credits.
Gordon Henriksen [Mon, 17 Sep 2007 17:04:44 +0000 (17:04 +0000)]
Adding myself to credits.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42032 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd 64-bit jmp instructions to the list of instructions that
Dan Gohman [Mon, 17 Sep 2007 15:19:08 +0000 (15:19 +0000)]
Add 64-bit jmp instructions to the list of instructions that
can terminate a block with no fall-through.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42029 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUse xorl instead of xorq to enter a zero into a 64-bit register.
Dan Gohman [Mon, 17 Sep 2007 14:55:08 +0000 (14:55 +0000)]
Use xorl instead of xorq to enter a zero into a 64-bit register.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42027 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoEmit integer x<1 as x<=0, as comparisons with zero (now includeing
Dan Gohman [Mon, 17 Sep 2007 14:49:27 +0000 (14:49 +0000)]
Emit integer x<1 as x<=0, as comparisons with zero (now includeing
64-bit) can use test instead of cmp with an immediate.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42026 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUse "test reg,reg" in place of "cmp reg,0" for 64-bit operands. This was
Dan Gohman [Mon, 17 Sep 2007 14:35:24 +0000 (14:35 +0000)]
Use "test reg,reg" in place of "cmp reg,0" for 64-bit operands. This was
previously only done for 32-bit and smaller operands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42024 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFactor the trampoline transformation into a subroutine.
Duncan Sands [Mon, 17 Sep 2007 10:26:40 +0000 (10:26 +0000)]
Factor the trampoline transformation into a subroutine.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42021 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoImplement x86 long double (uses host long double,
Dale Johannesen [Mon, 17 Sep 2007 00:38:27 +0000 (00:38 +0000)]
Implement x86 long double (uses host long double,
so only works on x86 target).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42019 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix bug in andersen's related to test_and_set.
Daniel Berlin [Sun, 16 Sep 2007 23:59:53 +0000 (23:59 +0000)]
Fix bug in andersen's related to test_and_set.
Add operator == and != to SparseBitVector.
Simplify code for test_and_set

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42018 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix a few bugs related to zero'ing of elements
Daniel Berlin [Sun, 16 Sep 2007 22:31:47 +0000 (22:31 +0000)]
Fix a few bugs related to zero'ing of elements

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42017 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRewrite of andersen's to be about 100x faster, cleaner, and begin to support field...
Daniel Berlin [Sun, 16 Sep 2007 21:45:02 +0000 (21:45 +0000)]
Rewrite of andersen's to be about 100x faster, cleaner, and begin to support field sensitivity

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42016 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFollow-up to patch r41999. Make the conditional that emits the personality stub
Bill Wendling [Sun, 16 Sep 2007 19:21:08 +0000 (19:21 +0000)]
Follow-up to patch r41999. Make the conditional that emits the personality stub
match the conditional that turns on exception handling emittion in the asm
printer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42008 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdjust per revew comments.
Dale Johannesen [Sun, 16 Sep 2007 16:51:49 +0000 (16:51 +0000)]
Adjust per revew comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42002 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoOnly emit the personality function as a global value if the backend actually
Bill Wendling [Sun, 16 Sep 2007 10:36:17 +0000 (10:36 +0000)]
Only emit the personality function as a global value if the backend actually
supports it. This solves this error on the Darwin x86-64 platform:

$ cat testcase.ii
struct A {
  A();
};

A *bork() {
  return new A;
}
$ llvm-g++ -arch x86_64 -c testcase.ii
/var/tmp//cc3U8fd8.s:52:unknown section type: non_lazy_symbol_pointers
/var/tmp//cc3U8fd8.s:52:Rest of line ignored. 1st junk character valued 76 (L).
/var/tmp//cc3U8fd8.s:53:Unknown pseudo-op: .indirect_symbol
/var/tmp//cc3U8fd8.s:53:Rest of line ignored. 1st junk character valued 95 (_).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41999 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoBe more careful when constant-folding PHI nodes.
Owen Anderson [Sun, 16 Sep 2007 08:04:16 +0000 (08:04 +0000)]
Be more careful when constant-folding PHI nodes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41998 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoremove obsolete tests.
Chris Lattner [Sat, 15 Sep 2007 17:38:04 +0000 (17:38 +0000)]
remove obsolete tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41984 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix PR1666, SPASS with the CBE and 254.gap with the CBE.
Chris Lattner [Sat, 15 Sep 2007 06:51:03 +0000 (06:51 +0000)]
Fix PR1666, SPASS with the CBE and 254.gap with the CBE.

GCC optimizes away things like ptr < NULL  to false.  To "fix" this,
have the CBE emit casts of pointers to intptr_t when doing relational
pointer comparisons.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41983 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoNew testcase for PR1662. GCC trees are horrible :(
Chris Lattner [Sat, 15 Sep 2007 05:46:41 +0000 (05:46 +0000)]
New testcase for PR1662.  GCC trees are horrible :(

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41979 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd patterns for SHLD64* and SHRD64*.
Dan Gohman [Fri, 14 Sep 2007 23:17:45 +0000 (23:17 +0000)]
Add patterns for SHLD64* and SHRD64*.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41975 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agofix a gcc warning: comparison between signed and unsigned integer expressions
Chris Lattner [Fri, 14 Sep 2007 22:57:00 +0000 (22:57 +0000)]
fix a gcc warning: comparison between signed and unsigned integer expressions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41972 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRemove RLE from the headers, since the pass itself is gone now.
Owen Anderson [Fri, 14 Sep 2007 22:54:46 +0000 (22:54 +0000)]
Remove RLE from the headers, since the pass itself is gone now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41971 91177308-0d34-0410-b5e6-96231b3b80d8