Skip to main content

Questions tagged [compilers]

Questions about programs that read code in one language (source language) and translate it into an equivalent program in another language (target language).

0 votes
3 answers
490 views

In most languages, writing a floating-point literal like 0.45 produces a binary IEEE-754 double that is actually stored as something slightly less than 0.45 (e.g., 0.44999999999999996). Because of ...
Whodunit's user avatar
3 votes
0 answers
56 views

I am currently reading "Warren's Abstract Machine: A Tutorial Reconstruction" and I'm trying to follow along with the exercise as well as code my own implementation. I am trying to ...
kusakus's user avatar
  • 31
0 votes
0 answers
56 views

I'm looking at translations to and from APL, which has right-to-left evaluation and no operator precedence. Is there a known algorithm to minimize parentheses usage when keeping the same operators for ...
Gabi's user avatar
  • 123
3 votes
2 answers
187 views

Is there any research on or at least formulation of the concept of "fixed points of bugs"? That is, suppose we have an implementation $I$ (e.g., a compiler or interpreter) of a programming ...
Anita Hailey's user avatar
1 vote
0 answers
52 views

I'm reading The implementation of functional programming languages (1987) by Peyton Jones and he mentions (p.307) that the MKAP (make application) instruction is more convenient if the argument is ...
Giacomo's user avatar
  • 111
1 vote
0 answers
35 views

I am implementing an LLVM pass for anticipated expressions using dataflow analysis and code hoisting. The reference I am following is the Purple Dragon Book (Compilers: Principles, Techniques, and ...
Abhishek Ghosh's user avatar
1 vote
0 answers
57 views

I am learning compiler design and I came across a problem for converting a Regex to DFA by direct method. But I couldn't draw the syntax tree or I would say I couldn't find a systematic approach for ...
Om Kumar Rath's user avatar
12 votes
3 answers
2k views

I understand that processors belonging to different architectures have different instruction set and therefore a program compiled for one processor (hardware platform) can't run on a processor with ...
vimalathithan17's user avatar
0 votes
1 answer
100 views

I'm stuck on exercise 4.6.7 part b from the dragon book. The task is to show that the given grammar Gn: S → Aibi        for 1 ≤ i ≤ nAi → ajAi | aj   for 1 ≤ i,j ≤ n i≠j has ...
Basic_Linuxoid's user avatar
2 votes
0 answers
62 views

This question might be too open-ended, but I can't seem to find any resources online. When implementing reference counting as a form of GC in a language, how do you know when to increase/decrease ...
lav_shaun's user avatar
1 vote
2 answers
567 views

There are questions here and on electrical engeneering stackexchange with similar titles, but they do not quite address the part that is bugging me. I hope I can explain it here in a clear way and ...
Vincent's user avatar
  • 761
1 vote
1 answer
69 views

I am writing a basic compiler that compiles a language down into custom bytecode instructions. The language allows for variable shadowing (this is a cause of one of the main problems I am running into)...
RIVERMAN2010's user avatar
1 vote
1 answer
62 views

I just started reading about data flow analysis in compilers and I am trying to understand the concept of live-out variables. For this I read the algorithm to compute live-out variables in each bloc ...
edamondo's user avatar
  • 111
1 vote
1 answer
98 views

I was just reading a book (Algorithms and Theory of Computation Handbook, Volume 1) and I came across the following passage : "From a practical point of view, for each grammar G = (Σ,V, S, P) ...
Aland Ameer's user avatar
1 vote
1 answer
60 views

I am stumped on Engineering a Compiler, 3rd ed. Section 6.3, Review Question 1. The book uses the term 'activation record' to refer to a generalized procedure frame. The question asks: In C, '...
Dean DeRosa's user avatar

15 30 50 per page
1
2 3 4 5
45