1d2926107SJoseph Huber //===-- Implementation of the GPU remquof function ------------------------===// 2d2926107SJoseph Huber // 3d2926107SJoseph Huber // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4d2926107SJoseph Huber // See https://llvm.org/LICENSE.txt for license information. 5d2926107SJoseph Huber // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6d2926107SJoseph Huber // 7d2926107SJoseph Huber //===----------------------------------------------------------------------===// 8d2926107SJoseph Huber 9d2926107SJoseph Huber #include "src/math/remquof.h" 10d2926107SJoseph Huber #include "src/__support/common.h" 11d2926107SJoseph Huber 12d2926107SJoseph Huber #include "declarations.h" 13*5ff3ff33SPetr Hosek #include "src/__support/macros/config.h" 14d2926107SJoseph Huber 15*5ff3ff33SPetr Hosek namespace LIBC_NAMESPACE_DECL { 16d2926107SJoseph Huber 17d2926107SJoseph Huber LLVM_LIBC_FUNCTION(float, remquof, (float x, float y, int *quo)) { 18d2926107SJoseph Huber int tmp; 19d2926107SJoseph Huber float r = __ocml_remquo_f32(x, y, (gpu::Private<int> *)&tmp); 20d2926107SJoseph Huber *quo = tmp; 21d2926107SJoseph Huber return r; 22d2926107SJoseph Huber } 23d2926107SJoseph Huber 24*5ff3ff33SPetr Hosek } // namespace LIBC_NAMESPACE_DECL 25