Daniel Dunbar
ea457b3edb
CrashRecovery/Darwin: Override raise() as well so that crash recovery doesn't
...
end up altering the thread on which crashes are done because of its use of
Darwin's broken raise() implementation.
llvm-svn: 114558
2010-09-22 17:46:10 +00:00
Francois Pichet
53617de15e
Fix the "unable to rename temporary" lit test failing on Windows. rename is now copy + delete on Windows. Problem to be revisited for a permanent and clean solution.
...
llvm-svn: 114320
2010-09-20 04:03:07 +00:00
Jakob Stoklund Olesen
8ae6803659
Add one more Core i7 model number.
...
llvm-svn: 114310
2010-09-19 17:54:28 +00:00
Chris Lattner
4e80799dbb
add corei7, the laptop version.
...
llvm-svn: 114302
2010-09-19 00:31:58 +00:00
NAKAMURA Takumi
14029b5d65
Move the declaration SetInformationJobObject() outside of namespace.
...
It is also workaround for PR7927.
llvm-svn: 114175
2010-09-17 11:14:18 +00:00
Daniel Dunbar
8a328e38c5
System: Don't reexport ___eprintf when building with Clang; this symbol isn't
...
used on Darwin anymore, and Clang might not always link with the library it is
currently found in.
llvm-svn: 114165
2010-09-17 04:25:24 +00:00
Michael J. Spencer
4b7f13a515
System/Path: Add x86-64 COFF to IdentifyFileType.
...
llvm-svn: 114037
2010-09-15 23:04:14 +00:00
Michael J. Spencer
915ffb8284
System/Path: Add isObjectFile().
...
llvm-svn: 114032
2010-09-15 22:45:45 +00:00
NAKAMURA Takumi
aa9b257b29
lib/System/Host.cpp: 7bit-ize. Eliminate "TM" and "(R)" in comments.
...
llvm-svn: 113486
2010-09-09 13:30:48 +00:00
Dan Gohman
2625d9a286
Issue a #error if the host doesn't have an implementation for
...
GetMainExecutable yet.
llvm-svn: 113240
2010-09-07 18:26:49 +00:00
Chris Lattner
7cd17a7a4a
compute the HasSSE3 bit correctly, patch by Nikolai Saoukh.
...
llvm-svn: 113147
2010-09-06 05:19:44 +00:00
Dan Gohman
7abb8df743
Apply a patch from Kees van Reeuwijk to add support for Minix.
...
Minix apparently doesn't like double-slash separators, and there's
no apparent need for them here.
llvm-svn: 112844
2010-09-02 18:24:46 +00:00
Dan Gohman
5f2118dd6f
Add an interface for unregistering a file from the FilesToRemove list.
...
llvm-svn: 112705
2010-09-01 14:17:34 +00:00
Anton Korobeynikov
1fa6799edc
Some fixes for NetBSD
...
llvm-svn: 112662
2010-08-31 22:38:00 +00:00
Michael J. Spencer
ab565264fa
Cleanup Whitespace.
...
llvm-svn: 112587
2010-08-31 06:36:46 +00:00
Michael J. Spencer
3bca7bf84d
System: Fix getMagicNumber on windows.
...
getMagicNumber was treating the _binary_ data it read in as a
null terminated string. This resulted in the std::string
calculating the length, and causing an assert in other code that
assumed that the length it passed was the same as the length of
the string it would get back.
llvm-svn: 112586
2010-08-31 06:36:33 +00:00
Michael J. Spencer
5cb73a9fb8
Don't cast Win32 FILETIME structs to int64. Patch by Dimitry Andric!
...
According to the Microsoft documentation here:
http://msdn.microsoft.com/en-us/library/ms724284%28VS.85%29.aspx
this cast used in lib/System/Win32/Path.inc:
__int64 ft = *reinterpret_cast<__int64*>(&fi.ftLastWriteTime);
should not be done. The documentation says: "Do not cast a pointer to a
FILETIME structure to either a ULARGE_INTEGER* or __int64* value because
it can cause alignment faults on 64-bit Windows."
llvm-svn: 112376
2010-08-28 16:39:32 +00:00
Daniel Dunbar
22ad30651b
Fix --disable-threads build, PR7949.
...
llvm-svn: 111676
2010-08-20 20:54:37 +00:00
Daniel Dunbar
093ad188e7
CrashRecovery/Darwin: On Darwin, raise sends a signal to the main thread instead
...
of the current thread. This has the unfortunate effect that assert() and abort()
will end up bypassing our crash recovery attempts. We work around this for
anything in the same linkage unit by just defining our own versions of the
assert handler and abort.
llvm-svn: 111583
2010-08-19 23:45:39 +00:00
Chris Lattner
f403684a4d
Fix failure of unittests/ExecutionEngine/JIT/MultiJITTest.cpp on
...
cygwin when built with ENABLE_SHARED=1. Patch by NAKAMURA Takumi!
llvm-svn: 111231
2010-08-17 15:42:43 +00:00
Chandler Carruth
69dd8d673c
Mark this variable as used.
...
llvm-svn: 110667
2010-08-10 10:39:25 +00:00
Chris Lattner
838e42928b
remove code setting rw locks to PTHREAD_PROCESS_PRIVATE, which
...
is the default. Patch by NAKAMURA Takumi!
llvm-svn: 110636
2010-08-10 00:34:06 +00:00
Dan Gohman
227c4f64ac
Eliminate unnecessary empty string literals.
...
llvm-svn: 110183
2010-08-04 01:39:08 +00:00
Owen Anderson
8769f9a8dd
Add an erase() method to llvm::ThreadLocal.
...
llvm-svn: 109686
2010-07-28 22:49:43 +00:00
Duncan Sands
b0f45f192c
Rather than using an ifdef on the target to zero out fields,
...
just use memset to zero the entire struct.
llvm-svn: 108330
2010-07-14 14:32:33 +00:00
Duncan Sands
f7b98e2b1e
Convert some tab stops into spaces.
...
llvm-svn: 108130
2010-07-12 08:16:59 +00:00
Chris Lattner
58dad00aa5
Path::isRootDirectory is unimplemented on Unix and not used,
...
remove it, fixing PR6909.
llvm-svn: 108125
2010-07-12 04:39:07 +00:00
Chris Lattner
a94ea82dac
improve Path::makeUnique when mkstemp/mktemp are not available
...
patch by Lasse Kärkkäinen in PR7404.
llvm-svn: 108110
2010-07-12 00:09:55 +00:00
Chris Lattner
96566c78ef
add some triple for minix, patch by Kees van Reeuwijk from PR7582
...
llvm-svn: 107785
2010-07-07 15:52:27 +00:00
Duncan Sands
48e353b393
Avoid "variable 'bits' set but not used [-Wunused-but-set-variable]"
...
warnings with gcc-4.6, by not setting bits when the result is not
used.
llvm-svn: 105790
2010-06-10 16:23:15 +00:00
Dan Gohman
b049874698
Factor out the handler work from SignalHandler into a helper function,
...
and change llvm::sys::RunInterruptHandlers to call that function directly
instead of calling SignalHandler, because the rest of SignalHandler
invokes side effects which aren't appropriate, including raising the
signal.
llvm-svn: 104896
2010-05-27 23:11:55 +00:00
Dan Gohman
31980d4fb9
Don't bother clearing the Magic string when the magic number
...
can't be read, since it isn't cleared on other error paths.
llvm-svn: 104852
2010-05-27 17:14:10 +00:00
Dan Gohman
91a7dd7cb6
Don't bother checking canRead() before calling getMagicNumber();
...
getMagicNumber() does its own error checking.
llvm-svn: 104851
2010-05-27 17:12:23 +00:00
Daniel Dunbar
1457d51ff8
Add llvm::sys::RunInterruptHandlers(), which runs the registered SIGINT cleanup
...
stuff.
llvm-svn: 103333
2010-05-08 02:10:34 +00:00
Dan Gohman
caa827af2c
This doesn't need SmallVector.h anymore.
...
llvm-svn: 101790
2010-04-19 17:51:31 +00:00
Dan Gohman
ede59ecfbb
Fix this for std::vectors which don't have .data().
...
llvm-svn: 101785
2010-04-19 16:33:28 +00:00
Dan Gohman
e2e1b9063a
Fix -Wcast-qual warnings.
...
llvm-svn: 101782
2010-04-19 15:55:10 +00:00
Dan Gohman
735c177251
Revert 91528 and use a std::vector instead, fixing an abuse of std::string.
...
llvm-svn: 101781
2010-04-19 15:54:44 +00:00
Chris Lattner
746abd86e7
avoid temporary std::string in non posix_spawn path.
...
llvm-svn: 101723
2010-04-18 17:34:10 +00:00
Benjamin Kramer
2cade0b3ff
Eliminate temporary string.
...
llvm-svn: 101711
2010-04-18 09:19:41 +00:00
Benjamin Kramer
6f6354213f
Properly inherit the environment on darwin where environ is not available for shared libraries.
...
llvm-svn: 101710
2010-04-18 09:16:04 +00:00
Nick Lewycky
152b2bc046
This is horrible. Split the difference, and declare 'environ' on all non-Darwin
...
platforms to unbreak the darwin and linux builds. The BSD folks should feel
free to change the #if, if this breaks them.
llvm-svn: 101703
2010-04-18 07:07:48 +00:00
Nick Lewycky
459afe3cce
Revert r101701, Darwin doesn't have 'environ'. Go figure.
...
llvm-svn: 101702
2010-04-18 06:44:21 +00:00
Nick Lewycky
2b694c49bb
Fix linux build. posix_spawn doesn't inherit the environment by default.
...
llvm-svn: 101701
2010-04-18 06:22:26 +00:00
Chris Lattner
22b58ac393
make Program::Execute use posix_spawn on systems that support it,
...
as it is more efficient than fork/exec.
Thanks to Eric for adding the autoconf check. It would be nice if
a cmake guru could add a cmake check for posix_spawn as well.
llvm-svn: 101693
2010-04-18 04:14:37 +00:00
Chris Lattner
49c39866b3
unnest from namespace.
...
llvm-svn: 101691
2010-04-18 03:33:55 +00:00
Dan Gohman
d48633d340
Fix a bunch of namespace polution.
...
llvm-svn: 101376
2010-04-15 17:08:50 +00:00
Chris Lattner
bb78eb4d82
improve haiku portability, patch by Paul Davey.
...
llvm-svn: 100933
2010-04-10 17:54:51 +00:00
Chris Lattner
9d77e5ba47
add minix support, patch by Kees van Reeuwijk! PR6797
...
llvm-svn: 100895
2010-04-09 20:45:04 +00:00
Torok Edwin
ba2f97fcb0
AddSignalHandler was not releasing the critical section on win32.
...
Patch from Gianluigi Tiesi!
llvm-svn: 100003
2010-03-31 12:07:16 +00:00