Skip to content

Instantly share code, notes, and snippets.

View sheharyaar's full-sized avatar

Shehar Yaar sheharyaar

  • Indian Institute of Technology (IIT), Kharagpur
  • Jamshedpur, Jaharkhand, India
  • 00:59 (UTC +05:30)
  • LinkedIn in/lagnos
View GitHub Profile

xt_action_param

param used by
@sheharyaar
sheharyaar / cache-line.md
Created June 16, 2024 07:16
My random notes on cs stuff..

cache alignment and packing

  1. Data is transferred between memory and cache in blocks of fixed size, called cache lines or cache blocks. When a cache line is copied from memory into the cache, a cache entry is created.
  2. The cache entry will include the copied data as well as the requested memory location (called a tag).

Resources

  1. https://stackoverflow.com/questions/39971639/what-does-cacheline-aligned-mean
  2. https://en.algorithmica.org/hpc/cpu-cache/cache-lines/
  3. https://en.algorithmica.org/hpc/cpu-cache/alignment/
  4. https://en.wikipedia.org/wiki/Data_structure_alignment
  5. https://ryonaldteofilo.medium.com/memory-and-data-alignment-in-c-b870b02c80fb

Host

$ sudo qemu-system-x86_64 \
 --enable-kvm \
 -cpu host -smp $(nproc) \
 -m 8192 \
 -kernel linux-next/arch/x86_64/boot/bzImage \
 -append "rw nokaslr root=/dev/vda1" \
 -device virtio-net,netdev=vmnic -netdev user,id=vmnic \
 -device VGA,vgamem_mb=256 \
@sheharyaar
sheharyaar / dtschema.md
Created May 7, 2024 21:51
Steps to write yamls for Devicetree bindings and test them
@sheharyaar
sheharyaar / contents.md
Last active May 7, 2024 09:07
My notes on Lua and Lua C API for GSoC 2024 Lablua project
@sheharyaar
sheharyaar / blockchain-resources.md
Last active June 19, 2024 18:38
Blockchain Resources

Blockchain Resources

Pre-requisites

  • Cryptography : Study about hashing, one-way hashes, elliptic curves and popular ones like sha256, etc. (just a basic idea)
  • Data Structure : Merkle trees, Merkle patricia trees
  • Distributed Systems and Networking : UDP features and uses, Pub-sub protocols, Gossip protocols, DNS and service discovery

Resources for BlockChain

@sheharyaar
sheharyaar / fortran90.md
Last active September 4, 2023 13:45
Fortran 90 notes for my High Performance Computing semester course

Fortran90 Notes

Contents

  1. Variables
  2. Arrays
  3. Dynamic Allocation
  4. Loops and Conditionals
  5. File I/O
  6. Functions / Routines
@sheharyaar
sheharyaar / frontend-notes.md
Last active November 11, 2023 22:00
Frontend Notes

CSS Notes

Box Model

  • Every element has a box around it. Display, margin, border and padding affect the behaviour of the box

Display

  • Changing the value of the display property can change whether the outer display type of a box is block or inline. This changes the way it displays alongside other elements in the layout.
  • Flex and Grid (display: flex and display: grid) are used to affect the contents
  • Block and inline
  • If an element is given block display, then it has a newline before and after it (it starts in a new line).
@sheharyaar
sheharyaar / GO-Concurrency.md
Last active January 11, 2023 12:36
Notes on Golang Concurrency

Go Concurrency

Contents

  1. Goroutines
    1. GO Waitgroups
    2. GO Scheduler
    3. GO States
    4. Synchronous system calls
    5. Netpoller