www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/04/17/19:57:46

Message-ID: <3537E4CB.5B59@icrdl.net>
From: Michel Huot <huotm AT icrdl DOT net>
Reply-To: huotm AT icrdl DOT net
MIME-Version: 1.0
Newsgroups: comp.os.msdos.djgpp
Subject: How prevent GCC from inlining a function?
Lines: 14
Date: Fri, 17 Apr 1998 23:25:27 GMT
NNTP-Posting-Host: 207.236.233.78
NNTP-Posting-Date: Fri, 17 Apr 1998 19:25:27 EST
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

I am writing a program and, for speed reasons, i must inline some
function that has a label and a loop in it, like that:

void foo(. . .)
{
  asm volatile (" ...
        Loop1:    ...
                  loop Loop1
                  ... ");
}

GCC compiles and say me that Loop1 is already defined. I found that
everywhere I call foo, the compiler inline it and put the label "Loop1".

Im wondering how can I prevet GCC from inlining this function? Is there
a pragma or something like that?

Thanks in advance, and sorry for my english:).

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019