By Topic

Design and construction of a PC-based stack machine simulator for undergraduate computer science and engineering courses

Sign In

Cookies must be enabled to login.After enabling cookies , please use refresh or reload or ctrl+f5 on the browser for the login options.

Formats Non-Member Member
$31 $13
Learn how you can qualify for the best price for this item!
Become an IEEE Member or Subscribe to
IEEE Xplore for exclusive pricing!
close button

puzzle piece

IEEE membership options for an individual and IEEE Xplore subscriptions for an organization offer the most affordable access to essential journal articles, conference papers, standards, eBooks, and eLearning courses.

Learn more about:

IEEE membership

IEEE Xplore subscriptions

2 Author(s)
Khan, F. ; Dept. of Comput. Sci., Texas Univ., Brownsville, TX, USA ; Anwar, S.

A senior level compiler design course in an undergraduate computer science and engineering program usually deals with teaching the students the basics of compiler construction. Since the impetus of such an undergraduate course is to deal with the issues of compiler construction rather than intricacies of different machines, it is instructive to generate the code for a simple stack machine, incorporating a hardware stack, rather than dealing with a register-based machine such as a microcomputer. However, the educational institutions have the latter as a well established computing platform. Therefore, for testing a constructed compiler for a stack machine, it is feasible to make a microcomputer-based stack machine simulator. This paper presents the working design of a PC-based stack machine simulator developed by the authors for use in an undergraduate computer science and engineering course in compiler design. This paper begins by putting forward the architecture of the virtual stack machine for which the simulator is designed and constructed. The stack machine's instruction set is explained and then followed by a discussion of its encoding scheme. The main data structures and the different stages of the simulator are elaborated upon, culminating in a description of the salient features of the simulator that make it an effective tool in a compiler construction course. This includes the simulator's different analytical features such as measuring space-time complexity to analyze the effectiveness of a compiled code

Published in:

Frontiers in Education Conference, 1997. 27th Annual Conference. Teaching and Learning in an Era of Change. Proceedings.  (Volume:3 )

Date of Conference:

5-8 Nov 1997