Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

412
Vistas
clang -Xclang -cc1 -O3 mips.c -emit-llvm , clang error: -emit-llvm cannot be used when linking

I want to use the clang front-end to convert mips.c to mips.ll which is a llvm IR.

So I use the command: clang -cc1 O3 mips.c -emit-llvm. A fatal error occurs: 'stdio.h'(which is included in mips.c) file not found.

Then I change the command as following: clang -Xclang -cc1 O3 mips.c -emit-llvm. Another error occurs: -emit-llvm cannot be used when linking

How can I solve the problem?

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

As written in the error message, you can only compile when emitting LLVM IR, not link.

Either add -c for the bitcode or -S for the readable form to your command line:

clang -Xclang -cc1 -O3 mips.c -emit-llvm -S
over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda