| delorie.com/archives/browse.cgi | search | 
| X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f | 
| Date: | Sat, 11 Dec 2004 10:24:40 -0500 | 
| Message-Id: | <200412111524.iBBFOeqJ032761@envy.delorie.com> | 
| From: | DJ Delorie <dj AT delorie DOT com> | 
| To: | djgpp AT delorie DOT com | 
| In-reply-to: | <b3Aud.18735$Zk.327000@twister2.libero.it> (message from Carlo on | 
| Sat, 11 Dec 2004 10:34:47 GMT) | |
| Subject: | Re: why inportb and outportb are so time expensive ? | 
| References: | <b3Aud.18735$Zk DOT 327000 AT twister2 DOT libero DOT it> | 
| Errors-To: | nobody AT delorie DOT com | 
| X-Mailing-List: | djgpp AT delorie DOT com | 
| X-Unsubscribes-To: | listserv AT delorie DOT com | 
> I have an application with a lot of inportb and outportb, most of the > time is spent to do these function calls. Two things come to mind: 1. inportb and outportb are intended to be inlined. Are you including the right header, and compiling with optimization, and have you verified that the instructions are inlined into a single opcode? You can check this with gdb (x/i) or objdump -d. 2. What peripherals are you talking to? I/O requests to slow peripherals will require a delay in the I/O itself, which can add a significant delay to those opcodes.
| webmaster | delorie software privacy | 
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |