Technical Overview of the CLR


This article is pretty enlightening to the differences between JVM and CIL back when CIL and JVM started. One of the things that is weird, is that it is written by two Microsoft Employees, which already makes me recognize that there is some kind of bias here, but I'll try to keep myself neutral.

One of the really amazing things is that CIL was made for implementing a variety of languages, with that in mind, we can see why there is so many languages running in .net This is amazing!

I like how there are different types of pointers: transient pointers and managed pointers. So that we can specify exactly how to manage them.

I really like how there is metadata on the build, that allows to check for the SHA1 Integrity of the file, so that we can progress on different levels.

What is weird is that sometimes we don't see how amazing was the competition from microsoft to create C#, We hope and think that sometimes It'll be all right. But seeing into it's history, this was a quite complex platform to create in 2002, the creation of C#, was a major breakthrough for computer science.

One of the most important things I found about CLR runtime is that it can box and unbox variables natively.

The CLR provides built-in support for boxing and unboxing. A valuetype
"T can be turned into reference type object using the box T instruction, and back into a valuetype using the unbox T instruction." So this means that object encapsulation is supportes in the assambly, which for C# 1.0 is an amazing feature. If C# is so good, it is mostly due to the amazing assambler Microsoft build for dotnet.

I just hope C# gets more traction in the future.


Miller, Jim et all.Technical Overview of the Common Language Runtime. Retrieved from http://webcem01.cem.itesm.mx:8005/s201811/tc3048/clr.pdf



Towels

Usually, in our courses with Ariel Ortiz, we are to read three books, one fictional, and the other two technical. This provides a great gateway to explor e new books, and reminds us that not all is about coding, but that we should not forget the beauty of arts.

This semester, we read “The Hitchhiker’s Guide to the Galaxy”, being a cornerstone for the cultural panorama of the computer science world, I loved and understood plenty of references I’ve been missing throughout the years. I’d say this is as basic as the normal Star Wars / Star Trek crowd.

One of the things that struck me as pure Genius, is the way Adams always comes up with something incredibly illogical, but really plausible, which in turn, you could even say it makes total sense.

One of those is this excerpt.

A towel is just about the most massively useful thing any interstellar Hitchhiker can carry. Partly it has great practical value. You can wrap it around you for warmth as you bound across the cold moons of Jaglan Beta; you can lie on it on the brilliant marble-sanded beaches of Santraginus V, inhaling the heady sea vapours; you can sleep under it beneath the stars which shine so redly on the desert world of Kakrafoon; use it to sail a miniraft down the slow heavy River Moth; wet it for use in hand-to-hand combat; wrap it round your head to ward off noxious fumes or avoid the gaze of the Ravenous Bugblatter Beast of Traal (a mind-bogglingly stupid animal, it assumes that if you can't see it, it can't see you — daft as a brush, but very very ravenous); you can wave your towel in emergencies as a distress signal, and of course you can dry yourself off with it if it still seems to be clean enough.

More importantly, a towel has immense psychological value. For some reason, if a strag (strag: nonhitchhiker) discovers that a hitchhiker has his towel with him, he will automatically assume that he is also in possession of a toothbrush, washcloth, soap, tin of biscuits, flask, compass, map, ball of string, gnat spray, wet-weather gear, space suit etc., etc. Furthermore, the strag will then happily lend the hitchhiker any of these or a dozen other items that the hitchhiker might accidentally have "lost." What the strag will think is that any man who can hitch the length and breadth of the Galaxy, rough it, slum it, struggle against terrible odds, win through and still knows where his towel is, is clearly a man to be reckoned with.

Hence a phrase which has passed into hitch hiking slang, as in "Hey, you sass that hoopy Ford Prefect? There's a frood who really knows where his towel is."

See?  This is wonderful. A towel is being used as the best thing a person can have, and he explains it in a way it ends up making perfect sense to carry a towel around.

I’m really happy I got to read this book, it was wonderful, and definitely a highlight for the highlight course of my education.

Adams, Douglas “The Hitchhiker’s Guide to the Galaxy”, 1979.



Building Server-Side Web Language Processors

What do you do when you want to start learning a new language? You go to the language page and try to run some things in the interactive REPL they provide for testing out code, that allows you to get an intuitive grasp of the language. But how would you do that? This article by Ariel Ortiz, even though he presents us the ideas behind template views, the reality is that code is often executed in the web.

When we execute in the web, we are presented with a plethora of vernaculars where we can learn a new language, but definitely the ones which are often are more popular as time progresses, are the ones that we try out with a tutorial or something of the sorts.

Now that we reflect upon this, this is a publication from 2010, where compilers were actually used only for code and templates. Now we are having a lot of transpiling languages. From SASS, LESS, to Babel and Typescript, we can see that transpilation is the new thing now. Having code transformed into a cannonical AST and then being transpiled, is only possible due to the massive advances of computation nowadays. 

We are beginning to see a shift from processing in the server, to processing in the client. To get to the maximal canonical view of processing in both places at asynchronous times, to collide to the desired state.

Technologies like React, try to address the previous point. Having event-centric languages is just a symptom of the duality of the processing between the two clients.

To drive the point home, is that we have a lot of technologies which are being executed server and client side that require some type of transpilation. Which ultimately ends up simplifying the lives of the developers which work on this.

Ortiz, Ariel. Building Server-Side Web Language Processors Proceedings of the Forty First SIGCSE Technical Symposium on Computer Science Education (SIGCSE 2010). March 10-13, 2010; Milwaukee, Wisconsin.


The Interpreter Pattern

First of all, I want to preface this blog, stating that I have two courses with my teacher <Ariel Ortiz> the first one, is Software Design and Architecture, where we evaluate and see different Refactorings and Coding Patterns. One of the patterns we started to see was the Interpreter pattern. This pattern allows us to build a Domain specific language for solving a problem. In this case, the program that we had to write was Rock Paper Scissors Lizard Spock. It is based on a meme from the program called the Big Bang Theory.

Going on, after implementing this process, I found in the book that was studied, a DSL for creating a maps implementation. What if, Google maps or Apple maps were coded in a DSL? This could be interesting info. What other implementations of implementing a language existed out there?

That prefaces this wonderful article, by Ariel Ortiz, where he stablishes an S-Expresison language, mainly used in Lisp, that works in this way ( expr input ). 

Adding to his wonderful article, we also saw his conference on “Applying the eval apply loop in clojure.” We could in theory, express a subset of Lisp in this SIL.

I am only yearning for the day we can implement lisp equivalent expressions without long parenthesis. That’s why I’ve started to learn python 3, which allows for the *kwargs pointer that allows similar evaluation to randomly assigned arguments.

I think the future is expanding to this kind of expressions, having a list comprehension of undefinite arguments, allow things like map reduce being way more useful than we thought previously.

This showing of the interpreter pattern is only going to open our paradigms even more for doing creative solutions. I’ve never had thought of solving a problem like this before. Thank you teacher.


“Language Design and Implementation using Ruby and the Interpreter Pattern” by Ariel Ortiz 


Grace Hopper

The first time I heard about Grace hopper was when I saw the Grace Hopper Conference, celebrated for woman around the world, which work in fields related to computer science. Seeing her story is truly admirable, I love how she invented the first compiler. That is amazing. 

One of the things I found amazing is that she is very personable. One of the quotes of the video was:

By the year 2000 70% of all active code in the world is COBOL code.

She was creating software for computers long before it was a thing.

One of the really amazing things is that she had great humor and sarcasm.  The way you see her express sarcasm and humor, really makes her incredible. She is an example for all of us, men and women alike.

She is really a wonderful spokeperson. Seeing her talks, really inspire you to make amazing things.

I’d love also how she was in the navy, not only did she enter a male dominated field, such as computing or mathematics, she did it in another male dominated field, the navy. She managed to rise through the ranks in both fields.

In my work at Microsoft, they give out scolarships for the Grace Hopper conference to people throughout the organization. I love that efforts like this are named after such a wonderful person.

I think she deserves more than she got, but I know she didn’t care for titles and names, like the code.


Nevertheless, I also saw an interview with her when she go to Letterman. She develops a good humor, and explains wonderfully everything.

An excerpt:

–“How did you know so much about computers?”

–“I didn’t, I worked on the first one.”

This is beautiful. Godspeed.


• “Grace Hopper – The Mother of Cobol” I Programmer.  Website. Pp 1, 2. 2013

• “The Queen Of Code”. Jacobs, Gillian. (16 minutes long), 2015