The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
+4 votes
356 views

Suppose we have a computer with single register and only three instructions given below:

LOAD addren ; load register
  ; from addren
STORE addren ; store register
  ; at addren
ADD addren ; add register to
  ; contents of addren
  ; and place the result
  ; in the register

Consider the following grammar:

$A \rightarrow id : =E$

$E \rightarrow E+T\mid T$

$T \rightarrow (E)\mid id$

Write a syntax directed translation to generate code using this grammar for the computer described above.

asked in Compiler Design by Veteran (59.9k points) | 356 views

Please log in or register to answer this question.

Related questions

0 votes
0 answers
4
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
47,932 questions
52,335 answers
182,384 comments
67,817 users