Solved

Accessing  32bit registers from C/C++ compilers in Lin

Posted on 2001-08-14
9
232 Views
Last Modified: 2010-04-21
Hai,

I have done C/C++ programming in DOS/WIN that access the 32 bit registers and performs operations on them.
I wan't to be able to do the same.

I wan't to directly load registers, and do shift operations.

Is it possible. (Suggest Lib's or code etc!)

I wan't to do this on intel celerons. (or any Intel bit 32 cpu for that matter).

Sincerely,
Bhaskar
Thanx for your time.
0
Comment
Question by:absub1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
9 Comments
 

Author Comment

by:absub1
ID: 6385720
I don't mind if I have to be a previlaged user to do this. But I don't think that will be needed.
0
 
LVL 5

Expert Comment

by:paulqna
ID: 6388502
Why don't you buy C++ for linux ?

General C++ and linux:
http://users.cyberelectric.net.au/%7Ecollins/
0
 

Author Comment

by:absub1
ID: 6389160
paulgna, I have Linux and the c/c++ compilers also. I want awnser to question in my text. Plz read fully.

0
Setting up LaraDock for Laravel

Learn how to set up LaraDock in a Laravel project - LaraDock gives us an easy way to run a Laravel application using Docker in a single command.

 
LVL 5

Expert Comment

by:paulqna
ID: 6390987
directly load registers, and do shift operations library code
0
 
LVL 5

Expert Comment

by:paulqna
ID: 6390990
Sorry for that last comment...
0
 
LVL 5

Accepted Solution

by:
bryanh earned 25 total points
ID: 6399468
I don't know how you access 32 bit registers in C/C++ in DOS/WIN, so I don't necessarily know what you're asking for.

But in the GNU compiler, you can manipulate registers with assembler code embedded in an otherwise C or C++ program.  See <http://gcc.gnu.org/onlinedocs/gcc-3.0/gcc_5.html#SEC102>
.
0
 

Expert Comment

by:rasaraja
ID: 6404927
U can use assembly language,registers eax,ebx are 32 bit ( e for enhanced ) .
so mov eax,(32 bit val) will work
Hope that helps.
0
 
LVL 20

Expert Comment

by:jmcg
ID: 9915925
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Accept: bryanh {http:#6399468}

Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

jmcg
EE Cleanup Volunteer
0

Featured Post

Use Filtering Commands to Process Files in Linux

Learn how to manipulate data with the help of various filtering commands such as `cat`, `fmt`, `pr`, and others in Linux.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever been frustrated by having to click seven times in order to retrieve a small bit of information from the web, always the same seven clicks, scrolling down and down until you reach your target? When you know the benefits of the command l…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

631 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question