Commit Graph

330 Commits

Author SHA1 Message Date
Anton Korobeynikov a41d9eca96 Moved disassembler to libSystem
llvm-svn: 33461
2007-01-23 10:26:08 +00:00
Reid Spencer 181fe4ad09 For PR808:
NetBSD also doesn't have pthread_mutexattr_setpshared

llvm-svn: 33406
2007-01-20 20:44:38 +00:00
Reid Spencer 9f900c1f92 Unbreak Darwin.
llvm-svn: 33375
2007-01-19 22:04:24 +00:00
Reid Spencer a96084901c Help the lli interpreter find the stderr/stdin/stdout symbols. These are
needed for output to be generated. On Linux these are both global vars and
macro definitions so we have to special case Linux.

llvm-svn: 33374
2007-01-19 21:41:04 +00:00
Reid Spencer dcf6f90033 Handle each of stderr/stdin/stdout separately.
llvm-svn: 33373
2007-01-19 21:30:39 +00:00
Reid Spencer 750f80e306 Avoid taking the address of a macro by checking to see if stdin is defined
or not. This allows DynamicLibrary.cpp to compile on Darwin.

llvm-svn: 33064
2007-01-11 00:35:10 +00:00
Reid Spencer 1b2eeedd85 Allow LLI, in interpreter mode, to find stdin, stdout, and stderr. This is
a bit of a hack but it lets some of the llvm-test programs run.

llvm-svn: 33058
2007-01-10 19:50:43 +00:00
Anton Korobeynikov eef04ba1c2 Partly fixed JITing on mingw32 platform. The support is not full due to
absence of dllimport JIT codegen.

llvm-svn: 32673
2006-12-19 15:24:18 +00:00
Reid Spencer 1792326daf Eliminate "control reaches end of non-void function" warnings.
llvm-svn: 32225
2006-12-05 17:53:26 +00:00
Jeff Cohen 7d6f3db3e2 Unbreak VC++ build.
llvm-svn: 31464
2006-11-05 19:31:28 +00:00
Reid Spencer 7f311c2f4b Get rid of unused variable.
llvm-svn: 31373
2006-11-02 07:59:59 +00:00
Chris Lattner a4f1e8f6b8 Use new config.h macro
llvm-svn: 30321
2006-09-14 06:21:59 +00:00
Chris Lattner 2f107cfc0d On Mac OS/X, make Process::PreventCoreFiles disable crash reporter for
the process in addition to disabling core file emission.  This speeds up
bugpoint on default-configured macs by several orders of magnitude.

llvm-svn: 30317
2006-09-14 06:01:41 +00:00
Anton Korobeynikov 6c6a70f999 - Fixed broken Win32 build
- Removed warning about clobbered parameter in Bytecode/Reader

llvm-svn: 30026
2006-09-01 20:35:17 +00:00
Chris Lattner 9543866c27 Guess what happens when asserts are disabled. :(
Also, the assert could never fire due to || instead of &&.

llvm-svn: 29977
2006-08-30 20:37:06 +00:00
Chris Lattner 97c9f20c52 simplify AnalysisGroup registration, eliminating one typeid call.
llvm-svn: 29932
2006-08-28 00:42:29 +00:00
Reid Spencer 50eac3b8ab For PR797:
Make the Win32 code exception free (untested/uncompiled) which forced some
interface changes which had ripple effect. This should be the last of 797.

llvm-svn: 29884
2006-08-25 21:37:17 +00:00
Reid Spencer 51e6f68b47 For PR797:
Final commit for this bug. This removes the last EH holdouts in LLVM
and turns off exception support by using the -fno-exceptions option. This
leads to the following reduction in library and executable sizes:
                DEBUG BUILD                RELEASE BUILD
         before     after   delta     before   after    delta
lib    162,328K  157,616K   4,712    17,864K  16,416K  1,448K
bin    571,444K  557,156K  14,288    63,296K   56,996K 6,300K

Debug   Improvement: 19,000K (2.59%)
Release Improvement:  7,748K (9.55%)

llvm-svn: 29882
2006-08-25 19:54:53 +00:00
Reid Spencer b5d6b8f26d For PR797:
Adjust implementation to match the new interface after exception handling
was removed in the Unix verison. NOTE: this hasn't been compiled yet!

llvm-svn: 29858
2006-08-24 18:58:37 +00:00
Reid Spencer dd27929918 Turn off exception handling for this library. It no longer throws nor
handles exceptions.

llvm-svn: 29847
2006-08-23 20:35:51 +00:00
Reid Spencer e4ca722199 For PR797:
Final removal of exceptions from lib/System and adjustment of users to
accommodate.

llvm-svn: 29846
2006-08-23 20:34:57 +00:00
Reid Spencer 879ed5ab9c For PR797:
Eliminate exception throwing from Path::renamePathOnDisk and adjust its
users correspondingly.

llvm-svn: 29843
2006-08-23 07:30:48 +00:00
Reid Spencer 51edba15c6 For PR797:
Remove exception throwing from Path::getDirectoryContents and its users.

llvm-svn: 29841
2006-08-23 06:56:27 +00:00
Reid Spencer 8db844241b For PR797:
Remove exceptions from the Path::create*OnDisk methods. Update their users
to handle error messages via arguments and result codes.

llvm-svn: 29840
2006-08-23 00:39:35 +00:00
Reid Spencer a1a7a35267 For PR797:
Adjust code to compensate for Path class interface change.

llvm-svn: 29837
2006-08-22 23:54:35 +00:00
Reid Spencer 9d2f19c7e4 For PR797:
Change the Path::make*OnDisk methods exception free and adjust their usage.

llvm-svn: 29836
2006-08-22 23:27:23 +00:00
Reid Spencer 7e73c51351 Update for changes in Path class interface for exception removal.
llvm-svn: 29834
2006-08-22 22:46:39 +00:00
Reid Spencer 6ba87bbfd3 Make the sys::Path::GetTemporaryDirectory method not throw exceptions and
adjust users of it to compensate.

llvm-svn: 29831
2006-08-22 19:01:30 +00:00
Reid Spencer b1f9935407 Don't throw needlessly. Failure of gettimeofday is *very* unlinkely so
just return MinTime if that should ever happen.

llvm-svn: 29826
2006-08-22 17:38:44 +00:00
Reid Spencer df1297dd3a For PR797:
Make MappedFile not throw any exceptions.

llvm-svn: 29816
2006-08-22 16:04:22 +00:00
Reid Spencer 8a77bb9815 For PR797:
Fix a bug in my last patch that botched file redirection by using explicit
scoping of if statements.

llvm-svn: 29815
2006-08-22 15:56:52 +00:00
Reid Spencer 6ad2a91fb3 Make an error message a little more intelligible.
llvm-svn: 29808
2006-08-22 05:28:38 +00:00
Reid Spencer 42bcf6ea76 For PR797:
Remove all exception code from Program.inc and implement its new interface
with an ErrMsg string argument.

llvm-svn: 29790
2006-08-21 06:02:44 +00:00
Reid Spencer c295914b7a For PR797:
Make sys::Program::ExecuteAndWait not throw exceptions and update any
affected code. It now return -9999 to signal that the program couldn't be
executed. Only one case (in bugpoint) actually examines the result code.

llvm-svn: 29785
2006-08-21 02:04:43 +00:00
Reid Spencer d6f8b1c70a Remove extraneous #include.
llvm-svn: 29541
2006-08-07 05:36:24 +00:00
Reid Spencer 448e2460e0 Make the removal of files use Path::eraseFromDisk just like it does for
the removal of directories. Using std::remove is indiscriminate and can
lead to the removal of things like /dev/null if run as root. The
Path::eraseFromDisk method ensures that we only ever remove regular files
or directories, but never character or block special nodes.  This should
clear up the problem with usage like: llvm-as -o /dev/null which is used
in the llvm-test makefiles.

llvm-svn: 29540
2006-08-07 05:34:08 +00:00
Reid Spencer 5f9e301521 Add a note about how the "isFile" check in Path::eraseFromDisk prevents
the erasure of non-file paths like /dev/null.

llvm-svn: 29539
2006-08-07 05:20:05 +00:00
Reid Spencer 0b52e2f433 Update the auto* tools: autoconf 2.60, libtool 1.5.22, automake 1.9.6.
Update ltld.[ch] to version 1.5.22.
Correct the notes about updating these tools (autoconf/README.TXT)
Add configure options for getting the correct option for including a whole
archive when linking.

llvm-svn: 29529
2006-08-04 18:18:08 +00:00
Chris Lattner 7dbd783e90 Remove some now-dead methods. Use getFileStatus instead.
llvm-svn: 29447
2006-08-01 18:16:02 +00:00
Chris Lattner 80df7c4651 Use getFileStatus instead of Path::isDirectory().
llvm-svn: 29443
2006-08-01 17:59:14 +00:00
Chris Lattner be119d4386 elimiante some syscalls
llvm-svn: 29442
2006-08-01 17:51:09 +00:00
Anton Korobeynikov 98484fc568 Minor fix due to recent API changes
llvm-svn: 29428
2006-08-01 08:07:22 +00:00
Chris Lattner 60c5064538 Modify setStatusInfoOnDisk to not throw an exception.
llvm-svn: 29402
2006-07-28 22:36:17 +00:00
Chris Lattner 60fbecabf8 Update win32 for Path::getStatusInfo
llvm-svn: 29401
2006-07-28 22:32:09 +00:00
Chris Lattner 3cec109967 Modify Path::eraseFromDisk to not throw an exception.
llvm-svn: 29400
2006-07-28 22:29:50 +00:00
Chris Lattner 4857253d98 Change Path::getStatusInfo to return a boolean and error string on an error
instead of throwing an exception.  This reduces the amount of code that is
exposed to exceptions (e.g. FileUtilities), though it is clearly only one step
along the way.

llvm-svn: 29395
2006-07-28 22:03:44 +00:00
Chris Lattner 963ac1486a Fix the build on win32
llvm-svn: 29302
2006-07-26 20:37:11 +00:00
Reid Spencer 082e2a7821 For PR780:
Put the rest of lib/System into LinkAllVMCore.h. This makes all of
lib/System available to programs that #include LinkALlVMCore.h so that
loadable modules linked into those programs can depend on all of lib/System
being available.

llvm-svn: 29288
2006-07-26 16:55:39 +00:00
Reid Spencer 421475cd3b For PR780:
1. Move IncludeFile.h to System library
2. Move IncludeFile.cpp to System library
3. #1 and #2 required to prevent cyclic library dependencies for libSystem
4. Convert all existing uses of Support/IncludeFile.h to System/IncludeFile.h
5. Add IncludeFile support to various lib/System classes.
6. Add new lib/System classes to LinkAllVMCore.h
All this in an attempt to pull in lib/System to what's required for VMCore

llvm-svn: 29287
2006-07-26 16:18:00 +00:00
Chris Lattner 9c6c94a806 simple optimization: don't bother calling "exists" (which calls the syscall
"access").  Instead, just let the open call fail if the file doesn't exist.
This reduces the # syscalls executed.

llvm-svn: 29173
2006-07-18 07:07:51 +00:00