summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorVedant Kumar <vsk@apple.com>2016-05-13 20:10:49 +0000
committerVedant Kumar <vsk@apple.com>2016-05-13 20:10:49 +0000
commit32f3a98d973ad901baf5fe131a413d1c82516d4e (patch)
tree83bc96f96774d846de35e0e633159c569ae1d3c9 /lib
parent7dd57fdb15845abd591034feb6b9cee1536edc61 (diff)
Revert "(HEAD -> master, origin/master, origin/HEAD) [ProfileData] (compiler-rt) Use Error in InstrProf and Coverage, NFC"
This reverts commit r269464. It fails two llvm-profdata tests. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@269469 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/profile/InstrProfData.inc7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/profile/InstrProfData.inc b/lib/profile/InstrProfData.inc
index 7358efc18..77d44f15b 100644
--- a/lib/profile/InstrProfData.inc
+++ b/lib/profile/InstrProfData.inc
@@ -295,15 +295,16 @@ typedef struct ValueProfData {
static std::unique_ptr<ValueProfData>
serializeFrom(const InstrProfRecord &Record);
/*!
- * Check the integrity of the record.
+ * Check the integrity of the record. Return the error code when
+ * an error is detected, otherwise return instrprof_error::success.
*/
- Error checkIntegrity();
+ instrprof_error checkIntegrity();
/*!
* Return a pointer to \c ValueProfileData instance ready to be read.
* All data in the instance are properly byte swapped. The input
* data is assumed to be in little endian order.
*/
- static Expected<std::unique_ptr<ValueProfData>>
+ static ErrorOr<std::unique_ptr<ValueProfData>>
getValueProfData(const unsigned char *SrcBuffer,
const unsigned char *const SrcBufferEnd,
support::endianness SrcDataEndianness);