Commit Graph

42400 Commits

Author SHA1 Message Date
Chris Lattner 15c6b7c948 various bug fixes, add to xcode project.
llvm-svn: 49216
2008-04-04 15:47:22 +00:00
Chris Lattner 6175bbbee2 initial checkin of Étoilé runtime support, patch by David Chisnall
llvm-svn: 49215
2008-04-04 15:45:52 +00:00
Steve Naroff 3913ea4bfb Add explicit support for diagnosing implicit function decls.
Without this, the diagnostic is very confusing. The diag is now consistent with gcc as well.

llvm-svn: 49214
2008-04-04 14:32:09 +00:00
Seo Sanghyeon b7bf0f3e1e - ccc: print generated command line to stdout instead of stderr
- ccc: quote shell metacharacters in command line to ease copy-and-paste

llvm-svn: 49213
2008-04-04 11:02:21 +00:00
Seo Sanghyeon 055c94f2f8 PR1963: Address of function is a constant expression
llvm-svn: 49212
2008-04-04 09:45:30 +00:00
Duncan Sands 4cbca05d4e If a value is cast to its own type, then the cast
is not needed.

llvm-svn: 49210
2008-04-04 08:28:13 +00:00
Torok Edwin 602647aa70 fix build error: add missing braces.
llvm-svn: 49209
2008-04-04 06:16:25 +00:00
Chris Lattner c5ffed4a66 Introduce ContextDecl, patch by Argiris Kirtzidis!
-Added ContextDecl (no TranslationUnitDecl)
-ScopedDecl class has a ContextDecl member
-FieldDecl class has a ContextDecl member, so that a Field or a ObjCIvar can be traced back to their RecordDecl/ObjCInterfaceDecl easily
-FunctionDecl, ObjCMethodDecl, TagDecl, ObjCInterfaceDecl inherit from ContextDecl. With TagDecl as ContextDecl, enum constants have a EnumDecl as their context.
-Moved Decl class to a "DeclBase.h" along with ContextDecl class
-CurContext is handled by Sema

llvm-svn: 49208
2008-04-04 06:12:32 +00:00
Chris Lattner 318d3ef88e Provide an initial cut at exposing JIT compiled symbols to performance
tools.  This is currently only enabled on the mac, but could easily be
supported by other hosts that are interested.

llvm-svn: 49207
2008-04-04 05:51:42 +00:00
Chris Lattner ee1817300a Make ExecutionEngine::updateGlobalMapping return the old mapping.
llvm-svn: 49206
2008-04-04 04:47:41 +00:00
Chris Lattner 5506f8cf4c Codegen assignment to self correctly, patch by David Chisnall!
llvm-svn: 49201
2008-04-04 04:07:35 +00:00
Nate Begeman 002e4bd158 Ignore qualifiers when checking vector operands, just like scalar operands.
This prevents things like 
a += b[0]; where a is a float4 and b is a float4 * (address_space 1)

llvm-svn: 49199
2008-04-04 01:30:25 +00:00
Evan Cheng 14bee50e06 Undo PHI elimination copy placement patch. This causes coalescing (performace) issues.
llvm-svn: 49198
2008-04-04 01:20:05 +00:00
Evan Cheng 823017fdd1 This is done.
llvm-svn: 49197
2008-04-04 01:19:03 +00:00
Ted Kremenek d1a2efadba Added investigate patch for an occasionally failing assertion (heisenbug?)
llvm-svn: 49193
2008-04-03 21:44:24 +00:00
Devang Patel 124cce86fc Reenable running StripSymbols when EH is on.
Dale fixed EH.

llvm-svn: 49192
2008-04-03 21:30:06 +00:00
Ted Kremenek bf191c76bd Remove bogus check to prune out analyzing files.
llvm-svn: 49191
2008-04-03 21:29:11 +00:00
Evan Cheng 4b9a2c0b59 New test case.
llvm-svn: 49190
2008-04-03 21:25:03 +00:00
Ted Kremenek 4c32d1fcce More reliably remove '\n' from queries of the location of ccc-analyzer
llvm-svn: 49189
2008-04-03 21:17:14 +00:00
Chuck Rose III 30d27e4e03 Removed a deleted file from the VStudio System project. Also added custom build commands to engage 64 bit assembler for compilation callback on 64 bit configurations only.
llvm-svn: 49188
2008-04-03 20:28:40 +00:00
Ted Kremenek 0dcd309044 Use full path to ccc-analyzer.
llvm-svn: 49187
2008-04-03 20:08:18 +00:00
Nate Begeman 11b6bb408e Teach clang how to codegen punpcklbw and punpcklwd
llvm-svn: 49186
2008-04-03 19:58:06 +00:00
Ted Kremenek d068813464 Make typedefs public.
llvm-svn: 49185
2008-04-03 19:52:45 +00:00
Ted Kremenek 10569cdd87 Better range highlight for undefined-argument checks.
llvm-svn: 49184
2008-04-03 18:52:25 +00:00
Ted Kremenek 5f5592062b When reporting "bad receiver" warnings, highlight the receiver.
llvm-svn: 49183
2008-04-03 18:46:16 +00:00
Ted Kremenek 89575b7bcb Use "getRanges" in default implementation of "getEndPath" to determine
the ranges of highlighted elements in the source code.

llvm-svn: 49181
2008-04-03 18:00:37 +00:00
Ted Kremenek cb2dc8eca5 Hooked up GRSimpleAPICheck and the simple Objective-C Foundation checks to use
the new BugReporter interface.

llvm-svn: 49180
2008-04-03 17:57:38 +00:00
Ted Kremenek c2546d6518 Mark nodes as sinks that GRAuditor says should be marked as sinks.
llvm-svn: 49179
2008-04-03 17:56:48 +00:00
Ted Kremenek b5c8225320 Use logical line number for BUGLINE.
llvm-svn: 49178
2008-04-03 17:55:57 +00:00
Ted Kremenek 406192d163 Added "getLogicalLineNumber" and "getLogicalColumnNumber" to FullSourceLoc.
llvm-svn: 49177
2008-04-03 17:55:15 +00:00
Andrew Lenharth bfb7246fb6 if some functions don't have debug info, we were outputing the same label at the start of each of those functions. This makes assemblers unhappy
llvm-svn: 49176
2008-04-03 17:37:43 +00:00
Ted Kremenek 73ac2048f9 Add member template version of SerializeTrait<T>::Create that also accepts
an optional argument for us by T's Create method.

llvm-svn: 49169
2008-04-03 16:44:37 +00:00
Evan Cheng 58936a48ee - Turn copies of implicit_def into implicit_def instructions.
- Be smarter about coalescing copies from implicit_def.

llvm-svn: 49168
2008-04-03 16:41:54 +00:00
Evan Cheng 6d07b625aa Special handling of zero-sized live intervals.
llvm-svn: 49167
2008-04-03 16:40:27 +00:00
Evan Cheng 20aed56504 - Treat a live range defined by an implicit_def as a zero-sized one.
- Eliminate an implicit_def when it's being spilled.

llvm-svn: 49166
2008-04-03 16:39:43 +00:00
Evan Cheng aacf4f15b3 - PHI elimination also eliminates implicit_def that fits into a PHI node rather than copying it.
- Be (slightly) smarter about where to place the copies.

llvm-svn: 49165
2008-04-03 16:38:20 +00:00
Evan Cheng 916802a78e Start of a series of patches related to implicit_def.
There is no point in creating a long live range defined by an implicit_def. Scheduler now duplicates implicit_def instruction for each of its uses. Therefore, if an implicit_def node has multiple uses, it will become a number of very short live ranges, rather than a long one. This will make coalescer's job easier.

llvm-svn: 49164
2008-04-03 16:36:07 +00:00
Ted Kremenek 1d0436cdb0 Re-implemented Path::createDirectoryOnDisk (for Unix).
This method allows one to create a directory, and optionally create all parent
directories that do not exist.

The original implementation would require that *all* directories along a path
are writable by the user, including directories that already exist. For example,
suppose we wanted to create the directory "/tmp/foo/bar", and the directory
"/tmp" already exists, but not "/tmp/foo". Since "/tmp" is writable by all
users, the original implementation would work, and create "/tmp/foo", followed
by "/tmp/bar".

A problem occurred, however if one wanted to created the directory
"/Users/myuser/bar" (or equivalently "/home/myuser/bar"), and "/Users/myuser"
already existed and is writable by the current user. The directory
"/User/myuser" is writable by the user, but "/User" is not. The original
implementation of createDirectoryOnDisk would return with failure since "/User"
is not writable, even though "/User/mysuser" is writable.

The new implementation works by recursively creating parents as needed, and thus
doesn't need to check the permissions on every directory in a path.

llvm-svn: 49162
2008-04-03 16:11:31 +00:00
Sam Bishop 30d70968fd Remove handling of impossible "-?" option.
llvm-svn: 49161
2008-04-03 14:29:47 +00:00
Sam Bishop 2f8a31ca92 trivial whitespace fix
llvm-svn: 49160
2008-04-03 14:20:28 +00:00
Evan Cheng 6c66bd368e Re-enable SSE4.
llvm-svn: 49158
2008-04-03 08:53:29 +00:00
Evan Cheng 6db4b4cc65 Fix x86-64 encoding bug. REX prefix must always follow 0x0F prefix. For example, extractps in 64bit mode: 66 REX 0F 3A 17, not 66 0F 3A REX 17.
llvm-svn: 49157
2008-04-03 08:53:17 +00:00
Evan Cheng d9129d1de3 Cosmetic
llvm-svn: 49156
2008-04-03 07:45:18 +00:00
Ted Kremenek ca40664275 Handle the case when getEndPath() returns NULL.
llvm-svn: 49155
2008-04-03 07:33:55 +00:00
Ted Kremenek 4d26d194e4 Don't run the analyzer on files whose language is "unknown"
llvm-svn: 49152
2008-04-03 07:14:59 +00:00
Ted Kremenek b73d6dda84 Added guard for printing out PathDiagnostics whose last element ends with
a piece with a SourceLocation that does not have a FileID.

llvm-svn: 49151
2008-04-03 07:13:10 +00:00
Ted Kremenek c599179267 Some cleanups in EscapeText and AddLineNumbers. Still investigating performance
issues.

llvm-svn: 49150
2008-04-03 07:12:29 +00:00
Ted Kremenek ffc1147323 Remove impossible "-?" option.
llvm-svn: 49149
2008-04-03 07:11:44 +00:00
Ted Kremenek 78e30c17bc Added "isFileID()" to FullSourceLoc.
llvm-svn: 49148
2008-04-03 07:11:38 +00:00
Ted Kremenek d4bee176b6 CSS/HTML generation tweaks for index.html: Remove special "classes" for <td>
elements in table so that sorttable can sort them.

llvm-svn: 49145
2008-04-03 05:50:51 +00:00