[GCC-XML] Parsing LLVM

Paolo Redaelli paolo.redaelli at gmail.com
Fri May 24 02:19:58 EDT 2013


2013/5/23 Brad King <brad.king at kitware.com>

> On 05/23/2013 10:13 AM, Paolo Redaelli wrote:
> > I'm trying to parse recent LLVM headers but I'm not able to solve this
> issue:
> >
> > gccxml -fexceptions `llvm-config --cppflags --cflags --cxxflags `
> plugin/c/llvm-liberty.h -fxml=llvm.gcc-xml
>
> What is the output of llvm-config with those flags?
>

First of all thanks in advance for any hints and suggestion.

Here's all the missing informations required to reproduce the issue
paolo at qualita:/media/Liberty/tybor-liberty/src/wrappers/llvm/library/externals$
llvm-config --cppflags --cflags --cxxflags
-I/usr/lib/llvm-3.1/include  -DNDEBUG -D_GNU_SOURCE
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
-I/usr/lib/llvm-3.1/include  -DNDEBUG -D_GNU_SOURCE
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -g
-O2 -fomit-frame-pointer -fPIC
-I/usr/lib/llvm-3.1/include  -DNDEBUG -D_GNU_SOURCE
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -g
-O2 -fomit-frame-pointer -fvisibility-inlines-hidden -fno-exceptions -fPIC
-Woverloaded-virtual -Wcast-qual



paolo at qualita:/media/Liberty/tybor-liberty/src/wrappers/llvm/library/externals$
cat plugin/c/llvm-liberty.h
#ifdef DEBUG // Let's be verbose during compile
#   warning "LLVM-liberty starting include"
#endif

#ifndef __builtin_bswap32 // previously __llvm__
extern unsigned int __builtin_bswap32(unsigned int _data);
#endif

#ifndef __builtin_bswap64
extern unsigned long __builtin_bswap64(unsigned long _data);
#endif

#ifndef __builtin_unreachable
#    include <stdlib.h>
#    define __builtin_unreachable abort
#endif

#include <llvm-c/Analysis.h>
#include <llvm-c/BitReader.h>
#include <llvm-c/BitWriter.h>
#include <llvm-c/Core.h>
#include <llvm-c/ExecutionEngine.h>
// #include <llvm-c/LinkTimeOptimizer.h>
// #include <llvm-c/Target.h>
// #include <llvm-c/lto.h>
// #include <llvm-c/Transforms/IPO.h>
// #include <llvm-c/Transforms/Scalar.h>
#ifdef DEBUG // Let's be verbose during compile
#   warning "LLVM-liberty ending include"
#endif
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/gccxml/attachments/20130524/3c387b85/attachment.html>


More information about the gccxml mailing list