History log of /llvm-project/llvm/lib/Support/Path.cpp (Results 176 – 200 of 208)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# c9d2e5b8 05-Jul-2013 Rafael Espindola <rafael.espindola@gmail.com>

Add a createUniqueFile function and switch llvm's users of unique_file.

This function is complementary to createTemporaryFile. It handles the case were
the unique file is *not* temporary: we will re

Add a createUniqueFile function and switch llvm's users of unique_file.

This function is complementary to createTemporaryFile. It handles the case were
the unique file is *not* temporary: we will rename it in the end. Since we
will rename it, the file has to be in the same filesystem as the final
destination and we don't prepend the system temporary directory.

This has a small semantic difference from unique_file: the default mode is 0666.
This matches the behavior of most unix tools. For example, with this change
lld now produces files with the same permissions as ld. I will add a test
of this change when I port clang over to createUniqueFile (next commit).

llvm-svn: 185726

show more ...


# 325fa0fd 05-Jul-2013 Rafael Espindola <rafael.espindola@gmail.com>

Add a higher level createTemporaryFile function.

This function is inspired by clang's Driver::GetTemporaryPath. It hides the
pattern used for uniquing and requires simple file names that are always

Add a higher level createTemporaryFile function.

This function is inspired by clang's Driver::GetTemporaryPath. It hides the
pattern used for uniquing and requires simple file names that are always
placed in the system temporary directory.

llvm-svn: 185716

show more ...


# 31a24433 28-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Improve comment.

llvm-svn: 185141


# e79a8722 28-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Improvements to unique_file and createUniqueDirectory.

* Don't try to create parent directories in unique_file. It had two problem:
* It violates the contract that it is atomic. If the directory

Improvements to unique_file and createUniqueDirectory.

* Don't try to create parent directories in unique_file. It had two problem:
* It violates the contract that it is atomic. If the directory creation
success and the file creation fails, we would return an error but the
file system was modified.
* When creating a temporary file clang would have to first check if the
parent directory existed or not to avoid creating one when it was not
supposed to.

* More efficient implementations of createUniqueDirectory and the unique_file
that produces only the file name. Now all 3 just call into a static
function passing what they want (name, file or directory).

Clang also has to be updated, so tests might fail if a bot picks up this commit
and not the corresponding clang one.

llvm-svn: 185126

show more ...


# 18424823 28-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Don't ask for a mode when we are not keeping the file.

llvm-svn: 185123


# 7ffacc49 27-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Add a convenience createUniqueDirectory function.

There are a few valid situation where we care about the structure inside a
directory, but not about the directory itself. A simple example is for un

Add a convenience createUniqueDirectory function.

There are a few valid situation where we care about the structure inside a
directory, but not about the directory itself. A simple example is for unit
testing directory traversal.

PathV1 had a function like this, add one to V2 and port existing users of the
created temp file and delete it hack to using it.

llvm-svn: 185059

show more ...


# f1fc3829 26-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Rename PathV2 to just Path now that it is the only one.

llvm-svn: 185015


# 6d1e3791 19-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Remove Path::isObjectFile.

llvm-svn: 184305


# 71affba9 12-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Inline Path::isBitcodeFile into only use and remove it.

llvm-svn: 183840


# e3e790a4 12-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Remove Path::hasMagicNumber.

llvm-svn: 183838


# d1fcac91 11-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Include PathV1.h in files that use it.

This is preparation for replacing Path.h with PathV2.h.

llvm-svn: 183782


# c656225b 11-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Remove Path::getDirname.

llvm-svn: 183780


# 01265491 11-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Remove GetDLLSuffix.

llvm-svn: 183777


# 8cc6dc26 11-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Remove GetSystemLibraryPaths.

llvm-svn: 183770


# 0487a321 11-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Remove unused FindLibrary function.

llvm-svn: 183764


# 3add14d7 11-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Remove sys::identifyFileType.

llvm-svn: 183763


# 1dc43065 10-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Pass a StringRef to sys::identifyFileType.

llvm-svn: 183669


# 548e9d48 10-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Fix an out of bounds array access.

We were looking at Magic[5] without checking Length. Since this path would not
return unless Length >= 18 anyway, just move the >= 18 check up.

llvm-svn: 183666


# 693b4750 10-Jun-2013 Rafael Espindola <rafael.espindola@gmail.com>

Update for current naming conventions.

I will change identifyFileType to use a StringRef in the next patch.

llvm-svn: 183664


Revision tags: llvmorg-3.3.0, llvmorg-3.3.0-rc3, llvmorg-3.3.0-rc2, llvmorg-3.3.0-rc1
# a229186a 21-Dec-2012 Roman Divacky <rdivacky@freebsd.org>

Remove duplicate includes.

llvm-svn: 170902


Revision tags: llvmorg-3.2.0, llvmorg-3.2.0-rc3
# ed0881b2 03-Dec-2012 Chandler Carruth <chandlerc@gmail.com>

Use the new script to sort the includes of every file under lib.

Sooooo many of these had incorrect or strange main module includes.
I have manually inspected all of these, and fixed the main module

Use the new script to sort the includes of every file under lib.

Sooooo many of these had incorrect or strange main module includes.
I have manually inspected all of these, and fixed the main module
include to be the nearest plausible thing I could find. If you own or
care about any of these source files, I encourage you to take some time
and check that these edits were sensible. I can't have broken anything
(I strictly added headers, and reordered them, never removed), but they
may not be the headers you'd really like to identify as containing the
API being implemented.

Many forward declarations and missing includes were added to a header
files to allow them to parse cleanly when included first. The main
module rule does in fact have its merits. =]

llvm-svn: 169131

show more ...


Revision tags: llvmorg-3.2.0-rc2, llvmorg-3.2.0-rc1
# fc2fb711 25-Jun-2012 Meador Inge <meadori@codesourcery.com>

PR13013: ELF Type identification fails for MSB type ELF files.

Fix 'sys::IdentifyFileType' to work with big and little endian byte orderings
when reading the ELF object file type.

Initial patch by

PR13013: ELF Type identification fails for MSB type ELF files.

Fix 'sys::IdentifyFileType' to work with big and little endian byte orderings
when reading the ELF object file type.

Initial patch by Stefan Hepp.

llvm-svn: 159138

show more ...


Revision tags: llvmorg-3.1.0, llvmorg-3.1.0-rc3, llvmorg-3.1.0-rc2, llvmorg-3.1.0-rc1
# 4f8a832c 13-Dec-2011 Michael J. Spencer <bigcheesegs@gmail.com>

Support/FileSystem: Add file_magic and move a vew clients over to it.

llvm-svn: 146523


# 7dfbeda6 13-Dec-2011 Michael J. Spencer <bigcheesegs@gmail.com>

Cleanup whitespace.

llvm-svn: 146521


Revision tags: llvmorg-3.0.0, llvmorg-3.0.0-rc4, llvmorg-3.0.0-rc3
# 39df70c3 01-Nov-2011 Eli Friedman <eli.friedman@gmail.com>

Remove a couple unused methods. PR11201.

llvm-svn: 143452


123456789