ELF Hello World Tutorial / Section header table Updated +Created
Array of Elf64_Shdr structs.
Each entry contains metadata about a given section.
e_shoff of the ELF header gives the starting position, 0x40 here.
e_shentsize and e_shnum from the ELF header say that we have 7 entries, each 0x40 bytes long.
So the table takes bytes from 0x40 to 0x40 + 7 + 0x40 - 1 = 0x1FF.
Some section names are reserved for certain section types: www.sco.com/developers/gabi/2003-12-17/ch4.sheader.html#special_sections e.g. .text requires a SHT_PROGBITS type and SHF_ALLOC + SHF_EXECINSTR
Running:
readelf -S hello_world.o
outputs:
There are 7 section headers, starting at offset 0x40:

Section Headers:
  [Nr] Name              Type             Address           Offset
       Size              EntSize          Flags  Link  Info  Align
  [ 0]                   NULL             0000000000000000  00000000
       0000000000000000  0000000000000000           0     0     0
  [ 1] .data             PROGBITS         0000000000000000  00000200
       000000000000000d  0000000000000000  WA       0     0     4
  [ 2] .text             PROGBITS         0000000000000000  00000210
       0000000000000027  0000000000000000  AX       0     0     16
  [ 3] .shstrtab         STRTAB           0000000000000000  00000240
       0000000000000032  0000000000000000           0     0     1
  [ 4] .symtab           SYMTAB           0000000000000000  00000280
       00000000000000a8  0000000000000018           5     6     4
  [ 5] .strtab           STRTAB           0000000000000000  00000330
       0000000000000034  0000000000000000           0     0     1
  [ 6] .rela.text        RELA             0000000000000000  00000370
       0000000000000018  0000000000000018           4     2     4
Key to Flags:
  W (write), A (alloc), X (execute), M (merge), S (strings), l (large)
  I (info), L (link order), G (group), T (TLS), E (exclude), x (unknown)
  O (extra OS processing required) o (OS specific), p (processor specific)
The struct represented by each entry is:
typedef struct {
    Elf64_Word  sh_name;
    Elf64_Word  sh_type;
    Elf64_Xword sh_flags;
    Elf64_Addr  sh_addr;
    Elf64_Off   sh_offset;
    Elf64_Xword sh_size;
    Elf64_Word  sh_link;
    Elf64_Word  sh_info;
    Elf64_Xword sh_addralign;
    Elf64_Xword sh_entsize;
} Elf64_Shdr;
ELF Hello World Tutorial / Section vs segment Updated +Created
We will get into more detail later, but it is good to have it in mind now:
  • section: exists before linking, in object files.
    One ore more sections will be put inside a single segment by the linker.
    Major information sections contain for the linker: is this section:
    • raw data to be loaded into memory, e.g. .data, .text, etc.
    • or metadata about other sections, that will be used by the linker, but disappear at runtime e.g. .symtab, .srttab, .rela.text
  • segment: exists after linking, in the executable file.
    Contains information about how each segment should be loaded into memory by the OS, notably location and permissions.
ELF Hello World Tutorial / Specified file formats Updated +Created
The ELF standard specifies multiple file formats:
  • Object files (.o).
    Intermediate step to generating executables and other formats:
    Source code
    
        |
        | Compilation
        |
        v
    
    Object file
    
        |
        | Linking
        |
        v
    
    Executable
    Object files exist to make compilation faster: with make, we only have to recompile the modified source files based on timestamps.
    We have to do the linking step every time, but it is much less expensive.
  • Executable files (no standard Linux extension).
    This is what the Linux kernel can actually run.
  • Shared object files (.so).
    Libraries meant to be loaded when the executable starts running.
  • Core dumps.
    Such files may be generated by the Linux kernel when the program does naughty things, e.g. segfault.
    They exist to help debugging the program.
In this tutorial, we consider only object and executable files.
ELF Hello World Tutorial / Standards Updated +Created
The LSB basically links to other standards with minor extensions, in particular:
A handy summary can be found at:
man elf
ELF Hello World Tutorial / STT_FILE Updated +Created
Entry 1 has ELF64_R_TYPE == STT_FILE. ELF64_R_TYPE is continued inside of st_info.
  • 10 8: st_name = 01000000 = character 1 in the .strtab, which until the following \0 makes hello_world.asm
    This piece of information file may be used by the linker to decide on which segment sections go: e.g. in ld linker script we write:
    segment_name :
    {
        file(section)
    }
    to pick a section from a given file.
    Most of the time however, we will just dump all sections with a given name together with:
    segment_name :
    {
        *(section)
    }
  • 10 12: st_info = 04
    Bits 0-3 = ELF64_R_TYPE = Type = 4 = STT_FILE: the main purpose of this entry is to use st_name to indicate the name of the file which generated this object file.
    Bits 4-7 = ELF64_ST_BIND = Binding = 0 = STB_LOCAL. Required value for STT_FILE.
  • 10 13: st_shndx = Symbol Table Section header Index = f1ff = SHN_ABS. Required for STT_FILE.
  • 20 0: st_value = 8x 00: required for value for STT_FILE
  • 20 8: st_size = 8x 00: no allocated size
Now from the readelf, we interpret the others quickly.
ELF Hello World Tutorial / .symtab Updated +Created
Section type: sh_type == SHT_SYMTAB.
Common name: "symbol table".
First the we note that:
  • sh_link = 5
  • sh_info = 6
For SHT_SYMTAB sections, those numbers mean that:
  • strings that give symbol names are in section 5, .strtab
  • the relocation data is in section 6, .rela.text
A good high level tool to disassemble that section is:
nm hello_world.o
which gives:
0000000000000000 T _start
0000000000000000 d hello_world
000000000000000d a hello_world_len
This is however a high level view that omits some types of symbols and in which the symbol types . A more detailed disassembly can be obtained with:
readelf -s hello_world.o
which gives:
Symbol table '.symtab' contains 7 entries:
   Num:    Value          Size Type    Bind   Vis      Ndx Name
     0: 0000000000000000     0 NOTYPE  LOCAL  DEFAULT  UND
     1: 0000000000000000     0 FILE    LOCAL  DEFAULT  ABS hello_world.asm
     2: 0000000000000000     0 SECTION LOCAL  DEFAULT    1
     3: 0000000000000000     0 SECTION LOCAL  DEFAULT    2
     4: 0000000000000000     0 NOTYPE  LOCAL  DEFAULT    1 hello_world
     5: 000000000000000d     0 NOTYPE  LOCAL  DEFAULT  ABS hello_world_len
     6: 0000000000000000     0 NOTYPE  GLOBAL DEFAULT    2 _start
The binary format of the table is documented at www.sco.com/developers/gabi/2003-12-17/ch4.symtab.html
The data is:
readelf -x .symtab hello_world.o
which gives:
Hex dump of section '.symtab':
  0x00000000 00000000 00000000 00000000 00000000 ................
  0x00000010 00000000 00000000 01000000 0400f1ff ................
  0x00000020 00000000 00000000 00000000 00000000 ................
  0x00000030 00000000 03000100 00000000 00000000 ................
  0x00000040 00000000 00000000 00000000 03000200 ................
  0x00000050 00000000 00000000 00000000 00000000 ................
  0x00000060 11000000 00000100 00000000 00000000 ................
  0x00000070 00000000 00000000 1d000000 0000f1ff ................
  0x00000080 0d000000 00000000 00000000 00000000 ................
  0x00000090 2d000000 10000200 00000000 00000000 -...............
  0x000000a0 00000000 00000000                   ........
The entries are of type:
typedef struct {
    Elf64_Word  st_name;
    unsigned char   st_info;
    unsigned char   st_other;
    Elf64_Half  st_shndx;
    Elf64_Addr  st_value;
    Elf64_Xword st_size;
} Elf64_Sym;
Like in the section table, the first entry is magical and set to a fixed meaningless values.
Eli Benderski Updated +Created
Amazing systems programming tutorials. Whenever you Google a hard topic, his blog comes up.
Also has many great contributions on Stack Overflow: stackoverflow.com/users/8206/eli-bendersky
As of 2016, Eli worked at Google (reference). TODO before that, I had found his earlier info previously but lost it.
Eli focuses mostly on compiler toolchains.
Eligius pool Updated +Created
Created by Luke Dashjr.
The pool is named after Saint Eligius, patron of miners[ref]
Eligius also means to "choose" or "chosen" in Latin: en.wiktionary.org/wiki/Eligius, same root as "to elect" in modern English presumably.
Figure 1.
Saint Eligius by Petrus Christus
. Source. Eligius pool is named after Saint Eligius, patron of goldsmiths and miners[ref]
Elis Regina Updated +Created
Mostly interpreter of songs written by others. But she's just too amazing, many of her interpretations are better than the original.
God, even Ciro Santilli is slightly shocked by her death, which happened before he was born, can you imagine it at the time? She was MPB's golden girl...
Video 1.
Atrás da Porta performed by Elis Regina
. Source. Composed by Francis Hime and Chico Buarque.
Video 2.
Águas de março performed by Elis Regina
. Source. From the 1972 eponymous album. Composed by Antônio Carlos Jobim.
Elliptic-curve Diffie-Hellman Updated +Created
The algorithm is completely analogous to Diffie-Hellman key exchange in that you efficiently raise a number to a power times and send the result over while keeping as private key.
The only difference is that a different group is used: instead of using the cyclic group, we use the elliptic curve group of an elliptic curve over a finite field.
Video 1.
Elliptic curves by Computerphile (2018)
Source. youtu.be/NF1pwjL9-DE?t=143 shows the continuous group well, but then fails to explain the discrete part.
Josephson effect Updated +Created
Discrete quantum effect observed in superconductors with a small insulating layer, a device known as a Josephson junction.
To understand the behaviour effect, it is important to look at the Josephson equations consider the following Josephson effect regimes separately:
A good summary from Wikipedia by physicist Andrew Whitaker:
at a junction of two superconductors, a current will flow even if there is no drop in voltage; that when there is a voltage drop, the current should oscillate at a frequency related to the drop in voltage; and that there is a dependence on any magnetic field
Bibliography:
Josephson equations Updated +Created
Two equations derived from first principles by Brian Josephson that characterize the device, somewhat like an I-V curve:
where:
Note how these equations are not a typical I-V curve, as they are not an instantaneous dependency between voltage and current: the history of the voltage matters! Or in other words, the system has an internal state, represented by the Josephson phase at a given point in time.
To understand them better, it is important to look at some important cases separately:
Elliptic curve point addition Updated +Created
Elliptic curve point addition is the group operation of an elliptic curve group, i.e. it is a function that takes two points of an elliptic curve as input, and returns a third point of the elliptic curve as its output, while obeying the group axioms.
The operation is defined e.g. at en.wikipedia.org/w/index.php?title=Elliptic_curve_point_multiplication&oldid=1168754060#Point_operations. For example, consider the most common case for two different points different. If the two points are given in coordinates:
then the addition is defined in the general case as:
with some slightly different definitions for point doubling and the identity point.
This definition relies only on operations that we know how to do on arbitrary fields:and it therefore works for elliptic curves defined over any field.
Just remember that:
means:
and that always exists because it is the inverse element, which is guaranteed to exist for multiplication due to the group axioms it obeys.
The group function is usually called elliptic curve point addition, and repeated addition as done for DHKE is called elliptic curve point multiplication.
Figure 1.
Visualisation of elliptic curve point addition
. Source.
Elon Musk Updated +Created
Musk is a truly ambivalent personality. Some points are very good. Some are very bad.
Respect on the technical side by Ciro Santilli.
But the way he treated his first wife Justine Musk, is very very weird, incomprehensible: www.marieclaire.com/sex-love/a5380/millionaire-starter-wife/
Positive Cirocoins for possibly going to reverse Twitter's unfair Trump ban if his Twitter acquisition goes through:
Negative Cirocoins for according to Wikipedia:
Within the merged company [Thiel's Confinity + Elon's X.com], Musk returned as CEO. Musk's preference for Microsoft software over Unix created a rift in the company and caused Thiel to resign.
Video 1.
The REAL Reason Why Tesla Made All Patents Open-Source by The not so boring Man (2021)
Source. Supercut from various interviews/presentations in which Elon saying that Tesla has open source patents and pro open source stuff. Can we trust it? Maybe.
Engine Updated +Created
Enthalpy Updated +Created
Adds up chemical energy and kinetic energy.
Wikipedia mentions however that the kinetic energy is often negligible, even for gases.
The sum is of interest when thinking about reactions because chemical reactions can change the number of molecules involved, and therefore the pressure.
To predict if a reaction is spontaneous or not, negative enthalpy is not enough, we must also consider entropy via Gibbs free energy.
enwiki-latest-categorylinks.sql Updated +Created
enwiki-latest-category.sql Updated +Created
dumps.wikimedia.org/enwiki/latest/enwiki-latest-category.sql.gz contains a list of categories. It only contains the categories and some counts, but it doesn't contain the subcategories and pages under each category, so it is a bit pointless.
The SQL first defines the table:
CREATE TABLE `category` (
  `cat_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  `cat_title` varbinary(255) NOT NULL DEFAULT '',
  `cat_pages` int(11) NOT NULL DEFAULT 0,
  `cat_subcats` int(11) NOT NULL DEFAULT 0,
  `cat_files` int(11) NOT NULL DEFAULT 0,
  PRIMARY KEY (`cat_id`),
  UNIQUE KEY `cat_title` (`cat_title`),
  KEY `cat_pages` (`cat_pages`)
) ENGINE=InnoDB AUTO_INCREMENT=249228235 DEFAULT CHARSET=binary ROW_FORMAT=COMPRESSED;
followed by a few humongous inserts:
INSERT INTO `category` VALUES (2,'Unprintworthy_redirects',1597224,20,0),(3,'Computer_storage_devices',88,11,0)
which we can see at: en.wikipedia.org/wiki/Category:Computer_storage_devices
Se see that en.wikipedia.org/wiki/Category:Computer_storage_devices_by_company
so it contains only categories.
We can check this with:
sed -s 's/),/\n/g' enwiki-latest-category.sql | grep Computer_storage_devices
and it shows:
(3,'Computer_storage_devices',88,11,0
(521773,'Computer_storage_devices_by_company',6,6,0
There doesn't seem to be any interlink between the categories, only page and subcategory counts therefore.
Epic Rap Battles of History Updated +Created
Most of the videos are crap, but the following ones almost killed Ciro Santilli of laughter:
Video 1.
Rasputin vs Stalin by Epic Rap Battles of History (2013)
Source. See also: cirosantilli.com/china-dictatorship/stalin.
Monty Python has a few precursors to the "random famous people mixed together compting" format, although not in the rap fight format:
Video 3.
Philosophers' Football Match by Monty Python (1972)
Source. If you can understand the jokes, your philosophy level is pretty good. Like more than zero. Wiki page: en.wikipedia.org/wiki/The_Philosophers%27_Football_Match. Ciro loves how that page currently uses a standard footbal match template to describe the match!
Equation of state Updated +Created

There are unlisted articles, also show them or only show them.