Hali

@Cg9G-UQmRMyh-L6Jvkq_Gw

NCKU EE master graduate

Joined on Dec 14, 2023

  • Linux Kernel Linux Kernel Project Operating System Capstone Lab0 Digital IC Design Image Demosaicing Circuit
     Like  Bookmark
  • Linked List 25. Reverse Nodes in k-Group 82. Remove Duplicates from Sorted List II 206. Reverse Linked List 2487. Remove Nodes From Linked List Linked List Array String Hash Table Binary Tree
     Like  Bookmark
  • The Linux kernel utilizes the task_struct structure, which can be viewed here to manage threads.​​​​struct task_struct { ​​​​ ... ​​​​ pid_t pid; ​​​​ pid_t tgid; ​​​​ ... ​​​​} Every thread in a Thread Group maps to a task structure in the kernel. The pid variable correspond to a thread ID, and tgid, meaning Thread Group ID corresponds to a process ID.User layerSystem callVariable mapped in Kernel <br/> task_struct structureThread IDpid_t gettid(void)pid_t pidProcess IDpid_t getpid(void)pid_t tgid Use the following command to retrieve the information about threads, where LWP represents the thread ID and NLWP indicates the Number of LWPs. Additionally, the process systemd+ is multi-thread, with four threads having thread IDs 1195, 1358, 1359,and 1360.​​​​$ ps -eLF -L
     Like  Bookmark
  •  Like  Bookmark
  • Learning Note Home Memory Management Memory leak analysis with valgrind Segmentation fault analysis Operating System Thread Safety Analysis
     Like  Bookmark
  • contributed by PoChuan994 進度紀錄 [x] 在 GitHub 上 fork lab0-c [ ] 依據上述指示著手修改 queue.[ch] 和連帶的檔案,測試後用 Git 管理各項修改,要能滿足 $ make test 自動評分系統的所有項目。 [ ] 研讀 Linux 核心原始程式碼的 lib/list_sort.c 並嘗試引入到 lab0-c 專案,比較你自己實作的 merge sort 和 Linux 核心程式碼之間效能落差,也該嘗試改進針對鏈結串列排序實作的效能 [ ] 確保 qtest 提供的 web 命令得以搭配上述佇列實作使用,目前一旦網頁伺服器啟動後,原本處理命令列操作的 linenoise 套件就無法使用,請提出改善機制 [ ] 在 qtest 提供新的命令 shuffle,允許藉由 Fisher–Yates shuffle 演算法,對佇列中所有節點進行洗牌 (shuffle) 操作,需要以統計的原理來分析你的實作,探究洗牌的「亂度」 [ ] 在 qtest 中執行 option entropy 1 並搭配 ih RAND 10 一類的命令,觀察亂數字串的分布,並運用「資訊與熵互補,資訊就是負熵」的觀念,設計一組新的命令或選項,得以在 qtest 切換不同的 PRNG 的實作 (可選定 Xorshift),搭配統計分析工具,比較亂數產生器 (如 Xorshift vs. 內建) 的品質 [ ] 研讀論文〈Dude, is my code constant time?〉,解釋本程式的 "simulation" 模式是如何透過以實驗而非理論分析,達到驗證時間複雜度,需要解釋 Student's t-distribution 及程式實作的原理。
     Like  Bookmark
  • This note serves as a document on thread safety analysis and implementation of mutex locks and atomic operations in the C standard library. Invironment setting:Ubuntu Linux version: 24.04.1 LTS gcc version: 13.3.0 II. Experiments 1. Race condition case 1.1 Implementation Both threads in the following .c file access the static variable counter without any protection against race conditions.​​​​#include <pthread.h> ​​​​#include <stdio.h> ​​​​#include <stdlib.h>
     Like  Bookmark
  • This website serves as a documentation platform for my learning notes on computer science. I'm a master graduate in electronic engineer from NCKU. About me:Medium GitHub
     Like  Bookmark
  • Environment Setting:Ubuntu Linux: 24.04.1 LTS gcc: 13.3.0 What is segmentation fault? How can segmentation occurs? II. Experiment Case 1: Invalid write to a read-only section int main()
     Like  Bookmark
  • I'm learning memory management using the valgrind tool and documenting it in this note. Environment setting Ubuntu Linux version: 24.04.1 LTS gcc version: 13.3.0 Valgrind version: 3.22.0 II. Valgrind tool Memory leak types:definitely lost: program is leaking memory indirectly lost: program is leaking memory in a pointer-based structure. (E.g. if the root node of a binary tree is "definitely lost", all the children will be "indirectly lost".) If you fix the "definitely lost" leaks, the "indirectly lost" leaks should go away.
     Like  Bookmark