History log of /external/lldb/source/Host/common/File.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
1c52f53b131537899c4ec04aa531e81979e1b544 23-May-2013 Greg Clayton <gclayton@apple.com> Cleaned up the File API a bit.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@182538 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
102b2c2681c9a830afe25bfea35557421905e42c 19-Apr-2013 Greg Clayton <gclayton@apple.com> After discussing with Chris Lattner, we require C++11, so lets get rid of the macros and just use C++11.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@179805 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
81a96aa6242f7b559770f5dc62316253cb8cb0d4 18-Apr-2013 Greg Clayton <gclayton@apple.com> Since we use C++11, we should switch over to using std::unique_ptr when C++11 is being used. To do this, we follow what we have done for shared pointers and we define a STD_UNIQUE_PTR macro that can be used and it will "do the right thing". Due to some API differences in std::unique_ptr and due to the fact that we need to be able to compile without C++11, we can't use move semantics so some code needed to change so that it can compile with either C++.

Anyone wanting to use a unique_ptr or auto_ptr should now use the "STD_UNIQUE_PTR(TYPE)" macro.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@179779 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
36da2aa6dc5ad9994b638ed09eb81c44cc05540b 25-Jan-2013 Greg Clayton <gclayton@apple.com> <rdar://problem/13069948>

Major fixed to allow reading files that are over 4GB. The main problems were that the DataExtractor was using 32 bit offsets as a data cursor, and since we mmap all of our object files we could run into cases where if we had a very large core file that was over 4GB, we were running into the 4GB boundary.

So I defined a new "lldb::offset_t" which should be used for all file offsets.

After making this change, I enabled warnings for data loss and for enexpected implicit conversions temporarily and found a ton of things that I fixed.

Any functions that take an index internally, should use "size_t" for any indexes and also should return "size_t" for any sizes of collections.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@173463 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
42dc5a5711614d1ebd88d5e6e27fe7663071d878 30-Oct-2012 Greg Clayton <gclayton@apple.com> Fixed File::SeekFromEnd() to use SEEK_END insted of SEEK_CUR.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@167025 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
fc04d2463ad654c28f9ee2ee836174cc86b7f8b8 30-Aug-2012 Greg Clayton <gclayton@apple.com> OptionValueFileSpec had an accessor to read the contents of the file and return the data. This can end up being used to get the string contents of a text file and could end up not being NULL terminated. I added accessors to get the file contents raw, or with a null terminator. Added the needed calls to make this happen in the FileSpec and File classes.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@162921 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
2f28ece553d2ef0d7b3e8d1419020591ec3818f9 04-Jan-2012 Greg Clayton <gclayton@apple.com> <rdar://problem/10507811>

Be better at detecting when DWARF changes and handle this more
gracefully than asserting and exiting.

Also fixed up a bunch of system calls that weren't properly checking
for EINTR.



git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@147559 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
9c236733d43e6250c8a5671a438f4a2afeb9c0b2 26-Oct-2011 Greg Clayton <gclayton@apple.com> Cleaned up many error codes. For any who is filling in error strings into
lldb_private::Error objects the rules are:
- short strings that don't start with a capitol letter unless the name is a
class or anything else that is always capitolized
- no trailing newline character
- should be one line if possible

Implemented a first pass at adding "--gdb-format" support to anything that
accepts format with optional size/count.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@142999 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
ec2d9787bed36e9eda6eac1996c7bed76c8d3da4 08-Apr-2011 Stephen Wilson <wilsons@start.ca> Add missing headers.

Something changed in commit r129112 where a few standard headers vanished from
the include chain when building on Linux. Fix up by including limits.h for
INT_MAX and PATH_MAX where needed, and stdio.h for printf().



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@129130 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
257082556976558deb1cb246d45c2ae1bdd7b34c 01-Apr-2011 Greg Clayton <gclayton@apple.com> Some OpenBSD patches from Amit Kulkarni.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@128721 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
80949d4e2bb738030a3211ea92b888c276993fe0 09-Feb-2011 Greg Clayton <gclayton@apple.com> Missed part of a patch from Stephen Wilson.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125220 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
419144b064166f0d18b06cad4d52fe66e7ca058f 09-Feb-2011 Greg Clayton <gclayton@apple.com> File::GetFileSpec() support for linux patch from Stephen Wilson.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125181 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
c08c4d3fa57387517b9ef43230f4b92c19e70572 09-Feb-2011 Greg Clayton <gclayton@apple.com> Pull support for the shared and exclusive lock since this wasn't available
on linux. And conditionalize the availablility of the fcntl() command
F_GETPATH.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125152 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
5892856b0cd6591194c669afab5bf9ac19c5b3a0 09-Feb-2011 Greg Clayton <gclayton@apple.com> Use Host::File in lldb_private::StreamFile and other places to cleanup host
layer a bit more.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125149 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
d35305ab31c10130fd60cec3f6ff62c49f1fb9dd 08-Feb-2011 Greg Clayton <gclayton@apple.com> Updated a few more Host::File functions and added documentation.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125110 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
882ef0508d9fc517b8ce51a6115b0a3a4e195725 08-Feb-2011 Greg Clayton <gclayton@apple.com> Added a few more calls to the File abtract class for seeking, syncing and
getting the file spec from the file descriptor.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125106 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp
60a63aea48af3c5fb34a808e97cb5227eebbaf00 08-Feb-2011 Greg Clayton <gclayton@apple.com> Added a file abtraction layer into the Host section of LLDB.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@125093 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Host/common/File.cpp