New Intel Tiger Lake CPU still suffering Meltdown & Spectre

Just came across an ad for the new Lenovo X1 Carbon Gen9, containing an Intel Tiger Lake CPU . This notebook looks interesting to me. I thought, this might replace my aging notebook. And as usual I checked the promoted internal CPU for the security vulnerabilities Specte & Meltdown: https://meltdownattack.com/.

I checked the list of affected CPUs: https://software.intel.com/security-software-guidance/processors-affected-transient-execution-attack-mitigation-product-cpu-model

I must tell you, I am very disappointed! The X1 Carbon Gen9 contains a the Intel CPU family “Tiger Lake”, still being listed as “affected processor” by the Specte & Meltdown security vulnerability!

Unbelievable!! Intel did not manage to release a Spectre & Meltdown proof CPU within 3 years!

Well, as it seems, waiting for a notebook containing a Spectre & Meltdown proof CPU, I will never purchase any notebook containing the CPU family Tiger Lake. Probably I will have to wait way way longer for Intel to fix this security vulnerability in future CPUs 🙁

Rust Function implementing Generator

The following example demonstrates how to implement a Rust-function implementing a generator (unstable feature in nightly compiler)

#![feature(generators, generator_trait)]
use std::ops::{Generator, GeneratorState};
use std::pin::Pin;

fn generator() -> impl Generator<
Yield=(),
Return=()>
{
   let generator = || {
      println!("2");
      yield;
      println!("4");
    };
   generator
}

#[derive(Debug, Clone)]
enum MyError {
   Fault
}

fn generator2() -> impl Generator<
   Yield=Result<u32, MyError>,
   Return=&'static str>
{
   let generator = || {
      yield Ok(1);
      yield Err(MyError::Fault);
      return "foo";
   };
   generator
}

fn main() {
   let mut generator = generator();

   println!("1");
   Pin::new(&mut generator).resume(());
   println!("3");
   Pin::new(&mut generator).resume(());
   println!("5");

   println!("-------");

   let mut generator2 = generator2();

   match Pin::new(&mut generator2).resume(()) {
      GeneratorState::Yielded(val) => { println!("{:?}", val); }
      _ => panic!("unexpected value from resume"),
   }

   match Pin::new(&mut generator2).resume(()) {
      GeneratorState::Yielded(val) => { println!  ("{:?}", val); }
      _ => panic!("unexpected value from resume"),
   }

   match Pin::new(&mut generator2).resume(()) {
      GeneratorState::Complete(val) => { println!("{}", val); }
      _ => panic!("unexpected value from resume"),
   }
}

LibreOffice – Import Cisco Network Icons to Gallery

Cisco Network Icons are available for download as Zip-file (Use the Search Engine of your choice to find this Zip-file), containing the icons as EPS. We want to use these icons in LibreOffice to create network diagrams.

Each of these EPS-files contains a preview TIFF image of low resolution, that would be used for import into LibreOffice-Gallery. Just, these TIFF images would result in diagrams of low quality. Instead one should convert each EPS-file into a high-quality, scalable SVG-file, being imported to the LibreOffice Gallery.

So, after unzipping all EPS-files into a folder, use the following script to iterate all EPS-files of the local folder, to convert each EPS-file to a high-quality, scalable SVG.

Finally, use “New Theme” of the “Gallery” to create a new theme and import all SVG-icons to it. Now, when you add such icon to your diagram, additional glue-points can be added to each icon to connect “Connectors” to it (lines following the icon when being moved around)

for epsfile in *.eps; do 
   echo "${epsfile}"
   ps2pdf -dEPSCrop "${epsfile}" - | pdftocairo -svg - "${epsfile}.svg"
done

Erlang for Blockchain

I’m really wondering why most Blockchain-Projects are coming up with new domain specific languages (DSP) when they could use Erlang! Erlang is a (mostly) functional language with a carrier-class VM, designed for concurrent computation, networking and providing fault-tolerance. Mind this!!