This was the opening keynote for the Embedded Computing Conference 2017 in Winterthur. It presents an historic view on the programming language C. The talk emphasize the influence from Unix, BCPL, PCC and C++.
Before 1980, most cell control and management software was written b.pdfarkleatheray
Before 1980, most cell control and management software was written by the user using the C
programming language. True False
Solution
False
The C programming language was devised in the early 1970s as a system implementation
language for the nascent Unix operating system. Derived from the typeless language BCPL, it
evolved a type structure; created on a tiny machine as a tool to improve a meager programming
environment, it has become one of the dominant languages of today
C came into being in the years 1969-1973, in parallel with the early development of the Unix
operating system; the most creative period occurred during 1972. Another spate of changes
peaked between 1977 and 1979, when portability of the Unix system was being demonstrated. In
the middle of this second period, the first widely available description of the language appeared:
The C Programming Language,often called the `white book\' or `K&R\' [Kernighan 78]. Finally,
in the middle 1980s, the language was officially standardized by the ANSI X3J11 committee,
which made further changes. Until the early 1980s, although compilers existed for a variety of
machine architectures and operating systems, the language was almost exclusively associated
with Unix; more recently, its use has spread much more widely, and today it is among the
languages most commonly used throughout the computer industry.
The late 1960s were a turbulent era for computer systems research at Bell Telephone
Laboratories [Ritchie 78] [Ritchie 84]. The company was pulling out of the Multics project
[Organick 75], which had started as a joint venture of MIT, General Electric, and Bell Labs; by
1969, Bell Labs management, and even the researchers, came to believe that the promises of
Multics could be fulfilled only too late and too expensively. Even before the GE-645 Multics
machine was removed from the premises, an informal group, led primarily by Ken Thompson,
had begun investigating alternatives..
Before 1980, most cell control and management software was written b.pdfarkleatheray
Before 1980, most cell control and management software was written by the user using the C
programming language. True False
Solution
False
The C programming language was devised in the early 1970s as a system implementation
language for the nascent Unix operating system. Derived from the typeless language BCPL, it
evolved a type structure; created on a tiny machine as a tool to improve a meager programming
environment, it has become one of the dominant languages of today
C came into being in the years 1969-1973, in parallel with the early development of the Unix
operating system; the most creative period occurred during 1972. Another spate of changes
peaked between 1977 and 1979, when portability of the Unix system was being demonstrated. In
the middle of this second period, the first widely available description of the language appeared:
The C Programming Language,often called the `white book\' or `K&R\' [Kernighan 78]. Finally,
in the middle 1980s, the language was officially standardized by the ANSI X3J11 committee,
which made further changes. Until the early 1980s, although compilers existed for a variety of
machine architectures and operating systems, the language was almost exclusively associated
with Unix; more recently, its use has spread much more widely, and today it is among the
languages most commonly used throughout the computer industry.
The late 1960s were a turbulent era for computer systems research at Bell Telephone
Laboratories [Ritchie 78] [Ritchie 84]. The company was pulling out of the Multics project
[Organick 75], which had started as a joint venture of MIT, General Electric, and Bell Labs; by
1969, Bell Labs management, and even the researchers, came to believe that the promises of
Multics could be fulfilled only too late and too expensively. Even before the GE-645 Multics
machine was removed from the premises, an informal group, led primarily by Ken Thompson,
had begun investigating alternatives..
C Programming Language is the most popular computer language and most used programming language till now. It is very simple and elegant language. This lecture series will give you basic concepts of structured programming language with C.
Developers who contributed hugely to and had a lasting influence on the software development profession, and who also have an extraordinary personal history.
History of F#, and the ML family of languages. Rachel Reese
After I switched from C# (a curly-brace heavy object-oriented language) to F# (a whitespace-sensitive functional language) a few years ago, I started to wonder about the history of programming languages and how they evolve. How does a feature in one language influence a feature in another language -- for instance, where did type providers come from? In this talk, I cover the history of MLs from approximately the dawn of time, eventually focusing on F# specifically.
Seven Master of Arts students from Constance at the University of Applied Sciences Communication Design faculty will be working on design research concerning multi-touch interfaces during summer term 2008. Faces and history.
Can programming be liberated from the von neumman styleshady_10
John Backus.
Can programming be liberated from the von neumman style.
Conventional programming languages are growing ever more enormous, but not stronger. Inherent defects at the most basic level cause them to be both fat and weak: their primitive word-at-a-time style of programming inherited from their common ancestor --the von Neumann computer, their close coupling of semantics to state transitions, their division of programming into a world of expressions and a world of statements, their inability to effectively use powerful combining forms for building new programs from existing ones, and their lack of useful mathematical properties for reasoning about programs.
In Earlier days every Language was designed for some specific purpose.
For Example- FORTRAN(Formula Translator) was used for Scientific and Mathematical application, COBOL(Common Business Oriented Language) was used for Business application.
* So need of such a language was felt which could with stand most of the purposes.
This is a talk I gave at Papers We Love NYC on April 12, 2017. The talk is based on some papers about this history of COBOL and how it relates to computer science.
How to do Test-Driven Development in C illustrated by solving a Recently Used List kata.
Similar slides can be found here http://www.olvemaudal.com/talks
C Programming Language is the most popular computer language and most used programming language till now. It is very simple and elegant language. This lecture series will give you basic concepts of structured programming language with C.
Developers who contributed hugely to and had a lasting influence on the software development profession, and who also have an extraordinary personal history.
History of F#, and the ML family of languages. Rachel Reese
After I switched from C# (a curly-brace heavy object-oriented language) to F# (a whitespace-sensitive functional language) a few years ago, I started to wonder about the history of programming languages and how they evolve. How does a feature in one language influence a feature in another language -- for instance, where did type providers come from? In this talk, I cover the history of MLs from approximately the dawn of time, eventually focusing on F# specifically.
Seven Master of Arts students from Constance at the University of Applied Sciences Communication Design faculty will be working on design research concerning multi-touch interfaces during summer term 2008. Faces and history.
Can programming be liberated from the von neumman styleshady_10
John Backus.
Can programming be liberated from the von neumman style.
Conventional programming languages are growing ever more enormous, but not stronger. Inherent defects at the most basic level cause them to be both fat and weak: their primitive word-at-a-time style of programming inherited from their common ancestor --the von Neumann computer, their close coupling of semantics to state transitions, their division of programming into a world of expressions and a world of statements, their inability to effectively use powerful combining forms for building new programs from existing ones, and their lack of useful mathematical properties for reasoning about programs.
In Earlier days every Language was designed for some specific purpose.
For Example- FORTRAN(Formula Translator) was used for Scientific and Mathematical application, COBOL(Common Business Oriented Language) was used for Business application.
* So need of such a language was felt which could with stand most of the purposes.
This is a talk I gave at Papers We Love NYC on April 12, 2017. The talk is based on some papers about this history of COBOL and how it relates to computer science.
How to do Test-Driven Development in C illustrated by solving a Recently Used List kata.
Similar slides can be found here http://www.olvemaudal.com/talks
Let's turn the table. Suppose your goal is to deliberately create buggy programs in C and C++ with serious security vulnerabilities that can be "easily" exploited. Then you need to know about things like stack smashing, shellcode, arc injection, return-oriented programming. You also need to know about annoying protection mechanisms such as address space layout randomization, stack canaries, data execution prevention, and more. These slides will teach you the basics of how to deliberately write insecure programs in C and C++.
A PDF version of the slides can be downloaded from my homepage: http://olvemaudal.com/talks
Here is a video recording of me presenting these slides at NDC 2014: http://vimeo.com/channels/ndc2014/97505677
Enjoy!
Programming is hard. Programming correct C and C++ is particularly hard. Indeed, both in C and certainly in C++, it is uncommon to see a screenful containing only well defined and conforming code.Why do professional programmers write code like this? Because most programmers do not have a deep understanding of the language they are using.While they sometimes know that certain things are undefined or unspecified, they often do not know why it is so. In these slides we will study small code snippets in C and C++, and use them to discuss the fundamental building blocks, limitations and underlying design philosophies of these wonderful but dangerous programming languages.
This content has a CC license. Feel free to use it for whatever you want. You may download the original PDF file from: http://www.pvv.org/~oma/DeepC_slides_oct2012.pdf
Sometimes you see code that is perfectly OK according to the definition of the language, but which is flawed because it breaks too many established idioms and conventions. On the other hand, a solid piece of code is something that looks like it is written by an experienced person who cares about professionalism in programming.
A presentation at Norwegian Developer Conference 2010
First Steps with Globus Compute Multi-User EndpointsGlobus
In this presentation we will share our experiences around getting started with the Globus Compute multi-user endpoint. Working with the Pharmacology group at the University of Auckland, we have previously written an application using Globus Compute that can offload computationally expensive steps in the researcher's workflows, which they wish to manage from their familiar Windows environments, onto the NeSI (New Zealand eScience Infrastructure) cluster. Some of the challenges we have encountered were that each researcher had to set up and manage their own single-user globus compute endpoint and that the workloads had varying resource requirements (CPUs, memory and wall time) between different runs. We hope that the multi-user endpoint will help to address these challenges and share an update on our progress here.
Top 7 Unique WhatsApp API Benefits | Saudi ArabiaYara Milbes
Discover the transformative power of the WhatsApp API in our latest SlideShare presentation, "Top 7 Unique WhatsApp API Benefits." In today's fast-paced digital era, effective communication is crucial for both personal and professional success. Whether you're a small business looking to enhance customer interactions or an individual seeking seamless communication with loved ones, the WhatsApp API offers robust capabilities that can significantly elevate your experience.
In this presentation, we delve into the top 7 distinctive benefits of the WhatsApp API, provided by the leading WhatsApp API service provider in Saudi Arabia. Learn how to streamline customer support, automate notifications, leverage rich media messaging, run scalable marketing campaigns, integrate secure payments, synchronize with CRM systems, and ensure enhanced security and privacy.
Check out the webinar slides to learn more about how XfilesPro transforms Salesforce document management by leveraging its world-class applications. For more details, please connect with sales@xfilespro.com
If you want to watch the on-demand webinar, please click here: https://www.xfilespro.com/webinars/salesforce-document-management-2-0-smarter-faster-better/
Listen to the keynote address and hear about the latest developments from Rachana Ananthakrishnan and Ian Foster who review the updates to the Globus Platform and Service, and the relevance of Globus to the scientific community as an automation platform to accelerate scientific discovery.
How Recreation Management Software Can Streamline Your Operations.pptxwottaspaceseo
Recreation management software streamlines operations by automating key tasks such as scheduling, registration, and payment processing, reducing manual workload and errors. It provides centralized management of facilities, classes, and events, ensuring efficient resource allocation and facility usage. The software offers user-friendly online portals for easy access to bookings and program information, enhancing customer experience. Real-time reporting and data analytics deliver insights into attendance and preferences, aiding in strategic decision-making. Additionally, effective communication tools keep participants and staff informed with timely updates. Overall, recreation management software enhances efficiency, improves service delivery, and boosts customer satisfaction.
Globus Connect Server Deep Dive - GlobusWorld 2024Globus
We explore the Globus Connect Server (GCS) architecture and experiment with advanced configuration options and use cases. This content is targeted at system administrators who are familiar with GCS and currently operate—or are planning to operate—broader deployments at their institution.
Atelier - Innover avec l’IA Générative et les graphes de connaissancesNeo4j
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Allez au-delà du battage médiatique autour de l’IA et découvrez des techniques pratiques pour utiliser l’IA de manière responsable à travers les données de votre organisation. Explorez comment utiliser les graphes de connaissances pour augmenter la précision, la transparence et la capacité d’explication dans les systèmes d’IA générative. Vous partirez avec une expérience pratique combinant les relations entre les données et les LLM pour apporter du contexte spécifique à votre domaine et améliorer votre raisonnement.
Amenez votre ordinateur portable et nous vous guiderons sur la mise en place de votre propre pile d’IA générative, en vous fournissant des exemples pratiques et codés pour démarrer en quelques minutes.
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns
Unlocking Business Potential: Tailored Technology Solutions by Prosigns
Discover how Prosigns, a leading technology solutions provider, partners with businesses to drive innovation and success. Our presentation showcases our comprehensive range of services, including custom software development, web and mobile app development, AI & ML solutions, blockchain integration, DevOps services, and Microsoft Dynamics 365 support.
Custom Software Development: Prosigns specializes in creating bespoke software solutions that cater to your unique business needs. Our team of experts works closely with you to understand your requirements and deliver tailor-made software that enhances efficiency and drives growth.
Web and Mobile App Development: From responsive websites to intuitive mobile applications, Prosigns develops cutting-edge solutions that engage users and deliver seamless experiences across devices.
AI & ML Solutions: Harnessing the power of Artificial Intelligence and Machine Learning, Prosigns provides smart solutions that automate processes, provide valuable insights, and drive informed decision-making.
Blockchain Integration: Prosigns offers comprehensive blockchain solutions, including development, integration, and consulting services, enabling businesses to leverage blockchain technology for enhanced security, transparency, and efficiency.
DevOps Services: Prosigns' DevOps services streamline development and operations processes, ensuring faster and more reliable software delivery through automation and continuous integration.
Microsoft Dynamics 365 Support: Prosigns provides comprehensive support and maintenance services for Microsoft Dynamics 365, ensuring your system is always up-to-date, secure, and running smoothly.
Learn how our collaborative approach and dedication to excellence help businesses achieve their goals and stay ahead in today's digital landscape. From concept to deployment, Prosigns is your trusted partner for transforming ideas into reality and unlocking the full potential of your business.
Join us on a journey of innovation and growth. Let's partner for success with Prosigns.
May Marketo Masterclass, London MUG May 22 2024.pdfAdele Miller
Can't make Adobe Summit in Vegas? No sweat because the EMEA Marketo Engage Champions are coming to London to share their Summit sessions, insights and more!
This is a MUG with a twist you don't want to miss.
Understanding Globus Data Transfers with NetSageGlobus
NetSage is an open privacy-aware network measurement, analysis, and visualization service designed to help end-users visualize and reason about large data transfers. NetSage traditionally has used a combination of passive measurements, including SNMP and flow data, as well as active measurements, mainly perfSONAR, to provide longitudinal network performance data visualization. It has been deployed by dozens of networks world wide, and is supported domestically by the Engagement and Performance Operations Center (EPOC), NSF #2328479. We have recently expanded the NetSage data sources to include logs for Globus data transfers, following the same privacy-preserving approach as for Flow data. Using the logs for the Texas Advanced Computing Center (TACC) as an example, this talk will walk through several different example use cases that NetSage can answer, including: Who is using Globus to share data with my institution, and what kind of performance are they able to achieve? How many transfers has Globus supported for us? Which sites are we sharing the most data with, and how is that changing over time? How is my site using Globus to move data internally, and what kind of performance do we see for those transfers? What percentage of data transfers at my institution used Globus, and how did the overall data transfer performance compare to the Globus users?
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisGlobus
JASMIN is the UK’s high-performance data analysis platform for environmental science, operated by STFC on behalf of the UK Natural Environment Research Council (NERC). In addition to its role in hosting the CEDA Archive (NERC’s long-term repository for climate, atmospheric science & Earth observation data in the UK), JASMIN provides a collaborative platform to a community of around 2,000 scientists in the UK and beyond, providing nearly 400 environmental science projects with working space, compute resources and tools to facilitate their work. High-performance data transfer into and out of JASMIN has always been a key feature, with many scientists bringing model outputs from supercomputers elsewhere in the UK, to analyse against observational or other model data in the CEDA Archive. A growing number of JASMIN users are now realising the benefits of using the Globus service to provide reliable and efficient data movement and other tasks in this and other contexts. Further use cases involve long-distance (intercontinental) transfers to and from JASMIN, and collecting results from a mobile atmospheric radar system, pushing data to JASMIN via a lightweight Globus deployment. We provide details of how Globus fits into our current infrastructure, our experience of the recent migration to GCSv5.4, and of our interest in developing use of the wider ecosystem of Globus services for the benefit of our user community.
Large Language Models and the End of ProgrammingMatt Welsh
Talk by Matt Welsh at Craft Conference 2024 on the impact that Large Language Models will have on the future of software development. In this talk, I discuss the ways in which LLMs will impact the software industry, from replacing human software developers with AI, to replacing conventional software with models that perform reasoning, computation, and problem-solving.
Innovating Inference - Remote Triggering of Large Language Models on HPC Clus...Globus
Large Language Models (LLMs) are currently the center of attention in the tech world, particularly for their potential to advance research. In this presentation, we'll explore a straightforward and effective method for quickly initiating inference runs on supercomputers using the vLLM tool with Globus Compute, specifically on the Polaris system at ALCF. We'll begin by briefly discussing the popularity and applications of LLMs in various fields. Following this, we will introduce the vLLM tool, and explain how it integrates with Globus Compute to efficiently manage LLM operations on Polaris. Attendees will learn the practical aspects of setting up and remotely triggering LLMs from local machines, focusing on ease of use and efficiency. This talk is ideal for researchers and practitioners looking to leverage the power of LLMs in their work, offering a clear guide to harnessing supercomputing resources for quick and effective LLM inference.
Unleash Unlimited Potential with One-Time Purchase
BoxLang is more than just a language; it's a community. By choosing a Visionary License, you're not just investing in your success, you're actively contributing to the ongoing development and support of BoxLang.
Software Engineering, Software Consulting, Tech Lead, Spring Boot, Spring Cloud, Spring Core, Spring JDBC, Spring Transaction, Spring MVC, OpenShift Cloud Platform, Kafka, REST, SOAP, LLD & HLD.
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...Globus
The Earth System Grid Federation (ESGF) is a global network of data servers that archives and distributes the planet’s largest collection of Earth system model output for thousands of climate and environmental scientists worldwide. Many of these petabyte-scale data archives are located in proximity to large high-performance computing (HPC) or cloud computing resources, but the primary workflow for data users consists of transferring data, and applying computations on a different system. As a part of the ESGF 2.0 US project (funded by the United States Department of Energy Office of Science), we developed pre-defined data workflows, which can be run on-demand, capable of applying many data reduction and data analysis to the large ESGF data archives, transferring only the resultant analysis (ex. visualizations, smaller data files). In this talk, we will showcase a few of these workflows, highlighting how Globus Flows can be used for petabyte-scale climate analysis.
22. At Bell Labs. Back In 1969. Ken Thompson wanted to play. He found a
little used PDP-7. Ended up writing a nearly complete operating
system from scratch. In about 4 weeks. In pure assembler of course.
Dennis Ritchie soon joined the effort.While porting Unix to a
PDP-11 they invented C, heavily inspired by Martin Richards’ portable
systems programming language BCPL. In 1972 Unix was rewritten in
C. Due to Steve Johnsons Portable C Compiler (PCC), Unix and C
could be ported to all kinds of computer architectures. C became
the most successful programming language ever. Initially the K&R and
PCC was only reference for C.With significant contributions from
C++ (Bjarne Stroustrup), the C language got standardized in
1989/1990, and thereafter updated in 1999 and 2011.
25. While working on the Multics projects, Dennis and Ken had also been exposed
to the very portable and efficient systems programming language BCPL.
"Both of us were really taken by the language and did a lot of work
with it." (Ken Thompson, 1989 interview)
http://www.princeton.edu/~hos/mike/transcripts/thompson.htm
GET “LIBHDR”
LET START() BE WRITES(“Hello, World”)
26. BCPL (1967) was the brainchild of Martin Richards from the University of
Cambridge
27. BCPL was a very much simplified version of CPL (1963).
28. CPL was the language initially designed for the Atlas computer to be
installed in Cambridge (ordered in 1961, operational in 1964).
29. EDSAC 2 users in 1960
http://en.wikipedia.org/wiki/EDSAC_2
A replacement for EDSAC 2,
30. which was an upgrade of the original EDSAC computer (1949)
http://en.wikipedia.org/wiki/Electronic_Delay_Storage_Automatic_Calculator
31.
32. EDSAC was arguably, the first electronic digital stored-program
computer. It ran its first program May 6, 1949
Maurice Wilkes and Bill Renwick in front of the complete EDSAC
http://en.wikipedia.org/wiki/Electronic_Delay_Storage_Automatic_Calculator
33. Maurice Wilkes' himself commenting on the 1951 film about how EDSAC was
used in practice:
https://youtu.be/x-vS0WcJyNM
34.
35.
36. EDSAC 2 users in 1960
http://en.wikipedia.org/wiki/EDSAC_2
39. (designed by Tony Brooker and Derrick Morris)
http://history.dcs.ed.ac.uk/archive/docs/atlasautocode.html
From David Hartley's article "CPL: FailedVenture or Noble Ancestor?" (2013)
Atlas Autocode
41. Algol
(aka IAL, designed by Friedrich L. Bauer, Hermann Bottenbruch, Heinz Rutishauser, Klaus Samelson, John
Backus, Charles Katz,Alan Perlis, Joseph Henry Wegstein)
http://en.wikipedia.org/wiki/ALGOL_58
http://www.softwarepreservation.org/projects/ALGOL/report/Algol58_preliminary_report_CACM.pdf/
42. In the early 1960's, it was common to think "we are building a new
computer, so we need a new programming language."
From David Hartley's article "CPL: FailedVenture or Noble Ancestor?" (2013)
(David Hartley, in 2013 article)
But, hey….
Autocode? Fortran? Algol? other languages?
43. CPL
Cambridge Programming Language
Combined Programming Language
(Cristophers’ Programming Language)
Cambridge Plus London
"anything not explicity allowed should be forbidden ... nothing should be left
undefined"
From David Hartley's article "CPL: FailedVenture or Noble Ancestor?" (2013)
"It was envisagd that [the language] would be sufficiently general and
versatile to dispense with machine-code programming as far as possible"
46. "Christopher Strachey and the Cambridge CPL Compiler", Martin Richards
Martin Richards started as a research student in 1963
From David Hartley's article "CPL: FailedVenture or Noble Ancestor?" (2013)
47. "Christopher Strachey and the Cambridge CPL Compiler", Martin Richards
Martin Richards started as a research student in 1963double floating point precision
support for complex numbers
polymorphic operators
transfer functions (aka, coercion)
closures and lamda calculus
From David Hartley's article "CPL: FailedVenture or Noble Ancestor?" (2013)
49. Cambridge never succeeded writing a working CPL compiler.
Development on CPL ended December 1966.
Writing a compiler for CPL was too difficult.
50. Inspired by his work on CPL, Martin Richards wanted to create a language:
• that was simple to compile
• with direct mapping to machine code
• that assumes the programmer know what he is doing
"The philosophy of BCPL is not one of the tyrant who thinks he knows
best and lay down the law on what is and what is not allowed;
rather, BCPL acts more as a servant offering his services to the
best of his ability without complaint, even when confronted with
apparent nonsense.The programmer is always assumed to know what he
is doing and is not hemmed in by petty restrictions.”
53. Martin Richards joined MIT’s Project MAC
and through the MULTICS project the Bell Labs people learned about this beautiful
language called BCPL - a language exactly to the taste of Ken and Dennis.
MIT GE Bell Labs
54. Computer Laboratory, Cambridge, December 2014
Humble fans meet Martin Richards, the inventor of BCPL
Jon Jagger, Martin Richards, Olve Maudal
56. Interviewer: Did you develop B?
Thompson: I did B.
Interviewer: As a subset of BCPL?
Thompson: It wasn't a subset. It was almost exactly the same.
...
Thompson: It was the same language as BCPL, it looked
completely different, syntactically it was, you
know, a redo.The semantics was exactly the same
as BCPL.And in fact the syntax of it was, if you
looked at, you didn't look too close, you would
say it was C. Because in fact it was C, without
types.
...
http://www.princeton.edu/~hos/mike/transcripts/thompson.htm
From an interview with Ken Thompson in 1989
57. From the HOPL article by Dennis Ritchie in 1993
BCPL, B and C differ syntactically in many
details, but broadly they are similar.
The C programming language was devised in the
early 1970s as a system implementation language
for the nascent Unix operating system. Derived from
the typeless language BCPL, it evolved a type
structure; created on a tiny machine as a tool to
improve a meager programming environment, it has
become one of the dominant languages of today.
…
58. Users’ Reference to B, Ken Thompson, January 1972The BCPL Reference Manual, Martin Richards, July 1967
vs
59. excerpt from the BCPL reference manual (Richards, 1967), page 6
excerpt from the B reference manual (Thompson, 1972), page 6
60. excerpt from the BCPL reference manual (Richards, 1967), page 6
excerpt from the B reference manual (Thompson, 1972), page 6
61. excerpt from the BCPL reference manual (Richards, 1967), page 6
excerpt from the B reference manual (Thompson, 1972), page 6
62. GET "LIBHDR"
GLOBAL $(
COUNT: 200
ALL: 201
$)
LET TRY(LD, ROW, RD) BE
TEST ROW = ALL THEN
COUNT := COUNT + 1
ELSE $(
LET POSS = ALL & ~(LD | ROW | RD)
UNTIL POSS = 0 DO $(
LET P = POSS & -POSS
POSS := POSS - P
TRY(LD + P << 1, ROW + P, RD + P >> 1)
$)
$)
LET START() = VALOF $(
ALL := 1
FOR I = 1 TO 12 DO $(
COUNT := 0
TRY(0, 0, 0)
WRITEF("%I2-QUEENS PROBLEM HAS %I5 SOLUTIONS*N", I, COUNT)
ALL := 2 * ALL + 1
$)
RESULTIS 0
$)
•Designed by Martin Richards, appeared in 1966, typeless (everything is a word)
•Influenced by Fortran and Algol
•Intended for writing compilers for other languages
•Simplified version of CPL by "removing those features of the full language which make
compilation difficult"
BCPL
64. /* The following program will calculate the constant e-2 to about
4000 decimal digits, and print it 50 characters to the line in
groups of 5 characters. */
main() {
extrn putchar, n, v;
auto i, c, col, a;
i = col = 0;
while(i<n)
v[i++] = 1;
while(col<2*n) {
a = n+1 ;
c = i = 0;
while (i<n) {
c =+ v[i] *10;
v[i++] = c%a;
c =/ a--;
}
putchar(c+'0');
if(!(++col%5))
putchar(col%50?' ': '*n');
}
putchar('*n*n');
}
v[2000];
n 2000;
Designed by Ken Thompson, appeared in ~1969, typeless (everything is a word)
"BCPL squeezed into 8K words of memory and filtered through Thompson's brain"
B
auto
extrn
if
else
while
switch
case
goto
return
66. /* Early C example */
mystrcpy(s,t)
char *s;
char *t;
{
int i;
for (i = 0; (*s++ = *t++) != '0'; i++)
;
return(i);
}
main()
{
char str1[10];
char str2[] = "Hello!";
int len = mystrcpy(str1, str2);
int i;
for (i = 0; i < len; i++)
putchar(str1[i]);
exit(0);
}
Designed by Dennis Ritchie and Ken Thompson
Developed during 1969-1972 in parallel with Unix
Data types added to the language to support the PDP-11
C
int
char
float
double
struct
sizeof
if
else
while
switch
case
goto
return
auto
extrn
default
do
for
break
continue
entry
extern
static
register
67. The C Reference Manual, Dennis Ritchie, Jan 1974 (aka C74)
Fun fact:The C74 reference manual does not mention BCPL at all.
It does not even mention the B reference manual by Ken Thompson.
68. The seminal book "The C Programming Language" (1978) acted for a long time as the
only formal definition of the language.And PCC was the reference implementation for C.
K&R C
“C became the most successful language ever.”
69.
70. in the Computing Laboratory at University of Cambridge.
in the mid/late 70’
71. Bjarne was working on his PhD thesis
http://computersweden.idg.se/polopoly_fs/1.346563!imageManager/1326219611.jpg
Bjarne
Cambridge Computing,The first 75 years, Haroon Ahmed, 2013
"The Design and Evolution of C++", Bjarne Stroustrup, 1994
72. He was working on a simulator to study alternatives for the organization of
system software for distributed systems.
The initial version of this simulator was written in Simula
http://en.wikipedia.org/wiki/Simula
object oriented programming multitasking
Bjørn Myrhaug, Sigurd Kubosh,
Kristen Nygard and Ole Johan Dahl
by the “Simula blackboard”
73. and ran on the IBM 360/165 mainframe.
https://www-03.ibm.com/ibm/history/exhibits/mainframe/mainframe_PP3165.html
System/370 model 165
74. The concepts of Simula and object orientation became increasingly helpful as
the size of the program increased. Unfortunately, the implementation of Simula
did not scale the same way.
75. Eventually, he was foreced to rewrite the simulator in BCPL and run it on the
experimental CAP computer.
76. “The experience of coding and debugging the simulator in BCPL was horrible.”
“Upon leaving Cambridge, I swore never again to attack a problem with tools as
unsuitable as those I had suffered while designing and implementing the simulator.”
77. After finishing his PhD Thesis in Cambridge,
Bjarne was hired by Bell Labs in April 1979
At Bell Labs, Bjarne started to analyze if the UNIX kernel could be distributed
over a network of computers connected by a local area network. Proper tools
was needed….
78. Bjarne started to write a preprocessor
to C that added Simula like classes to C.
“I learned C properly from people like Stu Feldman, Steve Johnson,
Brian Kernighan, and Dennis Ritchie.”
And then Bjarne started to develop “C with Classes”. The main motivation
was to create better support for modularity and concurrency.
79. The success of C++ added to the motivation for a C standard
C++ was the inspiration for the function prototypes and
several other mechanisms stronger type support.
Indeed, while an unusual perspective, it is fair to some extend to
view ANSI C as a strict subset of C++ at the time.
“The first demand from development management was that of 100% compatibility with C.”
But without a standard, that requirement did not make much sense: compatible with what
implementation of C?
Fun fact: All the examples in K&R, 2ed, was compiled with CFront 2.0
81. // C99 example, ISO/IEC 9899:1999
#include <stdio.h>
size_t mystrcpy(char *restrict s, const char *restrict t)
{
size_t i;
for (i = 0; (*s++ = *t++) != '0'; i++)
;
return i;
}
int main(void)
{
char str1[16];
char str2[] = "Hello, C99!";
size_t len = mystrcpy(str1, str2);
for (size_t i = 0; i < len; i++)
putchar(str1[i]);
}
C99 added a lot of stuff to C89, perhaps too much. Especially a lot of features for scientific
computing was added, but also a few things that made life easier for programmers.
C99
82. The main focus:
- security, eg Anneks K (the bounds checking library, contributed by Microsoft)
- support for multicore systems (threads from WG14, memory model from WG21)
The most interesting features:
• Type-generic expressions using the _Generic keyword.
• Multi-threading support
• Improved Unicode support
• Removal of the gets() function
• Bounds-checking interfaces
• Anonymous structures and unions
• Static assertions
• Misc library improvements
Made a few C99 features optional.
C11
84. • Currently working on defect reports
• There are some nasty/interesting differences between C11 and C++11
• IEEE 754 floating point standard updated in 2008
• CPLEX - C parallel language extentions (started after C11)
Next version of C - C2x?
Private conversation with David Keaton,April 2015
85. The Spirit of C
• Trust the programmer.
• Don't prevent the programmer from doing what needs to be done.
• Keep the language small and simple.
• Provide only one way to do an operation.
• Make it fast, even if it is not guaranteed to be portable.
http://www.open-std.org/jtc1/sc22/wg14/www/C99RationaleV5.10.pdf
86. "The philosophy of BCPL is not one of the tyrant who thinks he knows
best and lay down the law on what is and what is not allowed;
rather, BCPL acts more as a servant offering his services to the
best of his ability without complaint, even when confronted with
apparent nonsense.The programmer is always assumed to know what he
is doing and is not hemmed in by petty restrictions.”
(The BCPL book, 1979)
s/BCPL/C/g
87. "The philosophy of C is not one of the tyrant who thinks he knows
best and lay down the law on what is and what is not allowed;
rather, C acts more as a servant offering his services to the
best of his ability without complaint, even when confronted with
apparent nonsense.The programmer is always assumed to know what he
is doing and is not hemmed in by petty restrictions.”
(a rewrite of perhaps the most important paragraph in the BCPL book, 1979)