1 /*===- InstrProfilingInternal.c - Support library for PGO instrumentation -===*\ 2 |* 3 |* Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4 |* See https://llvm.org/LICENSE.txt for license information. 5 |* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6 |* 7 \*===----------------------------------------------------------------------===*/ 8 9 #if !defined(__Fuchsia__) 10 11 #include "InstrProfilingInternal.h" 12 13 static unsigned ProfileDumped = 0; 14 15 COMPILER_RT_VISIBILITY unsigned lprofProfileDumped() { 16 return ProfileDumped; 17 } 18 19 COMPILER_RT_VISIBILITY void lprofSetProfileDumped(unsigned Value) { 20 ProfileDumped = Value; 21 } 22 23 static unsigned RuntimeCounterRelocation = 0; 24 25 COMPILER_RT_VISIBILITY unsigned lprofRuntimeCounterRelocation(void) { 26 return RuntimeCounterRelocation; 27 } 28 29 COMPILER_RT_VISIBILITY void lprofSetRuntimeCounterRelocation(unsigned Value) { 30 RuntimeCounterRelocation = Value; 31 } 32 33 #endif 34