Core S2 Software Solutions

A light discussion on programming languages

Programming languages are to programmers what saws are to carpenters. It is one of our most important tools among many we need, but there are still many different types of saws needed that vary enormously across different applications. This analogy fits perfectly with programming languages and the variety that we have developed since the 1940’s. I’ve recently been thinking about how languages are interpreted to machine code now-days as well as other language concepts, and learned quite a bit through my coreBasic project.

Sure, developing a new programming language is as unnecessary as developing a new OS, but it is still a healthy academic exercise. There are even tools out there that allow you to define a programming language syntax, and let the interpreter do all the work, but I think it’s much more fun to write all that yourself! Let us go through the several layers and ways in which we can interpret a programming language ranging from binary to compiled to interpreted languages. Naturally you could learn much more through the Wikipedia articles on each topic, but again it’s fun to casually walk through and explain each type.

Continue reading for more!

Continue reading

Posted in Programming | Leave a comment

Dynamic Memory Allocations Usage as a Construct in Modern Programming Languages

This article was original published for the Pennsylvania State University Computer Science 461 course on programming language concepts in late 2009; I’m publishing it here as I had to research again into efficient memory allocation schemes for my new programming language coreBasic.

Introduction

Dynamic memory allocation is a fundamental feature of many computer programming languages, either sometimes called explicitly by the developer, or implicitly by the language. Certain languages have their entire fundamental data structures, such as LISP’s list element, based on dynamic allocations. This essay will discuss what is dynamic memory allocation, its usage within several programming language paradigms, as well as some implementations and their varying specialization’s.

Dynamic memory allocation is a common feature of programming languages (or libraries, such as in C/C++[3]) that allow allocation of varying sized pieces of data at run-time. This is different from the stack, as stack allocations are based on a first-in-last-out concept, such that when returning from a function data can be lost unless explicitly posted to a common “return” point. The stack structure is fast and self-managed, based on the notion of “pushing” and “popping” data, but is not designed for retaining significant data when moving between functions. This is due to the fact that “activation-frames” are relatively small and disappear when returning from a function[3][4]. The heap, based on dynamic memory allocation, allows for any number of any sized allocations (bounded by the virtual memory the operating system has) that remain persistent in the process until explicitly released by the program. Though not as fast and not self-managed as the stack is, the power is in the fact that data can stay as long as the programmer wants during the lifetime of the process.

Continue reading for more!

Continue reading

Posted in News & Updates | 2 Comments

CoreBasic – Programming language built from scratch running on a VM!

CoreBasic, or simple “cBasic”, is a BASIC-like language, derived from the TI-Basic programming language found commonly in the TI-series graphing calculators. It is a Virtual-Machine based language, meaning it is compiled into a byte-code and executed using software-simulation of an abstract hardware platform, but does not include advanced features like a JIT compiler or object-oriented features. The parsing and simulation tools are written in pure C, following the C99 standard, and can be ported or compiled on a wide variety of platforms.

The core goals of this language is to be simple, minimal, but feature rich, and easy to develop code with. This is an educational tool for use to program on mobile systems.

Learn more on Google Code.

Posted in News & Updates | 2 Comments


Sites map