LLVM C++ API How to create a constant f128

Viewed 83

how can I create a constant f128 (quad) using the LLVM C*+ API. Usually you do it like this (as per the tutorial):

ConstantFP::get(*TheContext, APFloat(Val))

But APFloat has no constructor that can take a long double or a StringRef where I can pass in the string repr of the quad. So how do I create a long double with the LLVM C++ API? As per the documentation of the IR language I know that a f128 type exists.

2 Answers
Related