1 Unix Kernel C OS 2 Linux kernel pw 3 level1:linux kernel 3.1 Linux Kernel Linux kernel kernel kernel /usr/src/linux/ Linux 3 make config(make oldcon

Size: px
Start display at page:

Download "1 Unix Kernel C OS 2 Linux kernel pw 3 level1:linux kernel 3.1 Linux Kernel Linux kernel kernel kernel /usr/src/linux/ Linux 3 make config(make oldcon"

Transcription

1 unix Unix Kernel (015717B) (025747J) (035712A) (035718K) (035739B) (035757A) (035763E) 1

2 1 Unix Kernel C OS 2 Linux kernel pw 3 level1:linux kernel 3.1 Linux Kernel Linux kernel kernel kernel /usr/src/linux/ Linux 3 make config(make oldconfig) make config 1 1 [y/n].config makeoldconfig make config Skip make menuconfig make menuconfig ncurses 2

3 .config make xconfig X Window System tcl/tk pw 3 make menuconfig root /usr/src/linux [root@pw019 ~]% make xconfig Level3 on save /usr/src/linux/.config [root@pw019 ~]% make dep [root@pw019 ~]% make clean make dep make clian 3

4 make ~]% make bzimage ~]% /sbin/installkernel new arch/i386/boot/bzimagesystem.map make bzimage vmlinux System.map arch/i386/boot/bzimage vmlinux arch/i386/boot/bzimage ( ) vmlinux bzimage bzimage System.map vmlinux symbol symbol c symbol System.map /sbin/installkernel arch/i386/boot/bzimage vmlinux new /boot/ make make [root@pw019 ~]% make modules [root@pw019 ~]% make modules_install [root@pw019 ~]% make install make modules_install /lib/modules/ /etc/ lilo.conf lilo.conf [root@pw019 /etc]%cat lilo.conf prompt timeout=50 default=linux boot=/dev/hda map=/boot/map 4

5 install=menu message=/boot/message image=/boot/vmlinuz vl15 label=linux initrd=/boot/initrd vl15.img read-only root=/dev/hda1 append=" resume2=swap:/dev/hda2" /etc]% cat lilo.conf prompt timeout=50 default=new boot=/dev/hda map=/boot/map install=menu message=/boot/message image=/boot/vmlinuz new label=new read-only root=/dev/hda1 append=" resume2=swap:/dev/hda2" default label image vmlinuz vl15 vmlinux new initrd initrd /etc]% /sbin/lilo -v ~]% reboot 5

6 kernel kernel linux ~]% uname -r vl7 pw Level1 kernel pw Level (Level2 ) kernel Level1 Level 4 level2:open system call OS OS CPU CPU 4.1 make (ld) /usr/lib/libc.so ld 6

7 /* GNU ld script Use the shared librarys but some functions are only in the staticc library. so try that secondarily. */ OUTPUT_FORMAT(elf32-i386) GROUP(/lib/libc.so.6 /usr/lib/libc_nonshared.a ) /lib/libc.so trap Linux int 0x80 /usr/src/linux/init/main.c 369 printk("kernel command line : %\n".saved_command_line); 370 parse_options(command line); 371 trap_init(); 372 init_irq(); 373 sched_init(); 371 trap_init() /usr/src/linux/arch/i386/kernel/traps.c 957 void init trap_init(void) 958 { set_system_gate(syscall_vector,&system_call); SYSCALL_VECTOR 0x trap trap /usr/src/linux/arch/i386/kernel/ entry.s entry.s 222 ENTRY(system_call) 223 push %eax 7

8 224 SAVE_ALL 225 GET_CURRENT(%ebx) 226 testb $0x02.tsk_ptrace(%ebx) 227 jne tracesys 228 cmpl $(NR_syscalls).%eas 229 jae badsys 230 call * SYMBOL_NAME(sys_call_table)(.%eax.4) 231 movl %eax.eax(%esp) 230 call * SYMBOL_NAME(sys_call_table)(.%eax.4) eax 4.4 kernel open /usr/src/linux/fs/open.c /usr/src/linux /fs/ /usr/src/linux/kernel/ 4.5 Level 8

9 5 level3:gdb 5.1 GDB GDB GNU GNU FSF(Free Software Foundation) UNIX UNIX GDB DDD(Data Display Debugger) GDB OS 5.2 GDB OS GDB OS GDB GDB GDB GDB 9

10 2. GDB GDB breakpoint handle_exception GDB GDB GDB set_debug_traps handle_exception Compiling the kernel on the development machine 3 xconfig oldconfig 10

11 grub lilo 7 grub 5.6 lilo grub grub 6 level4: system call 6.1 linux/include/asm(-i386)/unistd.h #define NR_exit 1 #define NR_fork 2... #define NR_( ) ( ) 6.2 linux/arch/i386/kernel/entry.s.data ENTRY(sys_call_table).long SYMBOL_NAME(sys_ni_call) /* 0 */.long SYMBOL_NAME(sys_exit).long SYMBOL_NAME(sys_fork)....long SYMBOL_NAME(sys_( )) 11

12 Linux2.6.XX entry.s linux/arch/i386/kernel/syscall_teble.s.long sys_( ) 6.3 linux/arch/i386/kernel/makefile obj-y := process.o semaphore.o signal.o entry.o traps.o irq.o vm86.o ptrace.o i8259.o ioport.o ldt.o setup.o time.o sys_i386.o pci-dma.o i386_ksyms.o i387.o bluesmoke.o dmi_scan.o ( ).o 6.4 ( ).h linux/include/linux #ifndef LINUX_( )_H #define LINUX_( )_H #include #include #include ( ) #endif _syscallx (X 0 ) X=2 _syscall2(( ),( ),( ),( ),( ),( )); ( ) 12

13 6.5 ( ).c linux/arch/i386/kernel #include asmlinkage ( ) sys_( )( ) { /* */ int sys_arg_triple() arg_triple.h #ifndef LINUX_ARG_TRIPLE_H #define LINUX_ARG_TRIPLE_H #include #include _syscall1(int, arg_triple, int, arg1); #endif arg_triple.c #include asmlinkage int sys_arg_triple(int arg1) { int j = 3; j = j * arg1; return j; syscalltest.c #include #include #include int main() { int i = 3; printf("test arg_triple(%d) = %d?n", i, arg_triple(i)); 13

14 return 0; include 6.6 syscalltest.c ~/info4]% ls syscalltest.c ~/info4]% gcc -o test.out syscalltest.c ~/info4]%./test.out Incorrectly built binary which accesses errno or h_errno directly. Needs to be fixed. test arg_triple(3) = 9 [j03063@pw039 ~/info4]% 6.7 Linux 7 level5: OS 7.1 OS ID ***************** 14

15 test.c ***************** #include #include int sys_test(char* comment) { int pid; pid = current->pid; if(comment) printk("syscall_test: %s pid = %d?n", comment, pid); return 0; level4 7.2 AP ************* test.h ************ #ifndef TEST_H #define TEST_H #include #include #include #ifndef KERNEL syscall1(int, test, char*, comment) #endif #endif AP AP syscall, linux/unistd.h syscallx() (X 0 5 ) syscallx()

16 ****************** test2.c ****************** #include #include int main(int argc, char** argv) { if(argc == 2) test(argv[1]); return 0; 7.4 /var/log/messages [root@pw039 j03012]%./a.out foo [root@pw039 j03012]% tail -1 /var/log/messages Jan 12 20:09:09 pw039 kernel: syscall_test: foo pid = level4 test.c pid = current- pid ID 8 level6: ( ) 8.1 Linux Linux 16

17 Linux 1 mount 8.2 /* */ #include #include #include /* */ MODULE_DESCRIPTION( "Sample null device driver." ); /* */ MODULE_LICENSE( "GPL" ); /* */ static int devmajor = 241; static char* devname = "newnull2"; static char* msg = "module [newnull2.o]"; /* linux/fs.h struct file_operations */ /* */ static struct file_operations newnulldev_fops = { owner : THIS_MODULE, /* */ ; /* 17

18 register_chrdev */ int init_module( void ) { if ( register_chrdev( devmajor, devname, newnulldev_fops ) ) { printk( KERN_INFO "%s : register_chrdev failed\n" ); return -EBUSY; return 0; /* unregister_chrdev */ void cleanup_module( void ) { if ( unregister_chrdev( devmajor, devname ) ) { printk( KERN_INFO "%s : unregister_chrdev failed\n" ); /*... */ printk( KERN_INFO "%s : removed from kernel\n", msg ); 8.3 [j03018@pw022 ~]% gcc -DMODULE -D KERNEL -O -c newnull2.c newnull2.o 18

19 root ~]% mknod /dev/newnull2 c [j03018@pw022 ~]% chmod 0666 /dev/newnull2 mknod newnull newnull.o insmod [j03018@pw022 ~]% /sbin/insmod nuwnull2.o [j03018@pw022 ~]% cat /proc/devices Character devices: 1 mem 2 pty 3 ttyp 4 ttys 5 cua 7 vcs 10 misc 14 sound 128 ptm 136 pts 162 raw 180 usb 226 drm 241 newnull2 Block devices: 19

20 2 fd 3 ide0 22 ide1 241 newnull2 /usr/include/linux/ major.h /proc devices major.h #ifndef _LINUX_MAJOR_H #define _LINUX_MAJOR_H #define MAX_CHRDEV 255 #define MAX_BLKDEV 255 #define UNNAMED_MAJOR 0 #define MEM_MAJOR 1 #define RAMDISK_MAJOR 1 #define FLOPPY_MAJOR 2 #define PTY_MASTER_MAJOR 2 #define IDE0_MAJOR #define MSR_MAJOR 202 #define CPUID_MAJOR 203 #define OSST_MAJOR 206 /* OnStream-SCx0 SCSI tape */ #define IBM_TTY3270_MAJOR 227 /* Official allocations now */ #define IBM_FS3270_MAJOR static inline int ide_blk_major(int m) { return IDE_DISK_MAJOR(m); 20

21 #endif 8.4 newnull2.o: kernel-module version mismatch chardev.o was compiled for kernel version vl7 while this kernel is version vl15. pw Linux pw /usr/src/linux ~]% uname -r vl15 linux Linux Linux pw 21

22 9 9.1 open/close/read/write chardev.c chardev.c /* */ #include /* copy_from_user, copy_to_user */ #include #include /* inode, file, file_operations */ #include /* printk */ #include #include... /* 242 */ static int devmajor = 242;... /* */ /* 32 */ #define MAXBUF 32 static unsigned char devbuf[ MAXBUF ]; static int buf_pos;... /* * open() * 1 open * * open linux/fs.h * struct file_operations open * 0 * linux/errno.h * */ 22

23 static int chardev_open( struct inode* inode, struct file* filp ) { printk( KERN_INFO "%s : open() called\n", msg ); spin_lock( chardev_spin_lock ); if ( access_num ) { spin_unlock( chardev_spin_lock ); return -EBUSY; access_num ++; spin_unlock( chardev_spin_lock ); return 0; /* * release() * * * * close * * */ static int chardev_release( struct inode* inode, struct file* filp ) { printk( KERN_INFO "%s : close() called\n", msg ); spin_lock( chardev_spin_lock ); access_num --; spin_unlock( chardev_spin_lock ); return 0; 23

24 /* * read() * * */ static ssize_t chardev_read( struct file* filp, char* buf, size_t count, loff_t* pos ) { int copy_len; int i; printk( KERN_INFO "%s : read() called\n", msg ); if ( count > buf_pos ) copy_len = buf_pos; else copy_len = count; /*buf devbuf */ /* 0*/ /* */ if ( copy_to_user( buf, devbuf, copy_len ) ) { printk( KERN_INFO "%s : copy_to_user failed\n", msg ); return -EFAULT; /* */ /* */ *pos += copy_len; for ( i = copy_len; i < buf_pos; i ++ ) devbuf[ i - copy_len ] = devbuf[i]; buf_pos -= copy_len; printk( KERN_INFO "%s : buf_pos = %d\n", msg, buf_pos ); 24

25 return copy_len; /* * write() * */ static ssize_t chardev_write( struct file* filp, const char* buf, size_t count, loff_t* pos ) { int copy_len; printk( KERN_INFO "%s : write() called\n", msg ); if ( buf_pos == MAXBUF ) { printk( KERN_INFO "%s : no space left\n", msg ); return -ENOSPC; if ( count > ( MAXBUF - buf_pos ) ) copy_len = MAXBUF - buf_pos; else copy_len = count; /* buf */ /*copy_from_user */ /*devbuf + buf_pos buf */ /* copy_len */ if ( copy_from_user( devbuf + buf_pos, buf, copy_len ) ) { printk( KERN_INFO "%s : copy_from_user failed\n", msg ); return -EFAULT; *pos += copy_len; buf_pos += copy_len; 25

26 printk( KERN_INFO "%s : buf_pos = %d\n", msg, buf_pos ); return copy_len; /* */ /* read write open release 4 4 */ /* */ static struct file_operations chardev_fops = { owner : THIS_MODULE, read : chardev_read, write : chardev_write, open : chardev_open, release : chardev_release, ; /* End of chardev.c */ 9.2 linux/fs.h struct file_operations linux/fs.h 884:struct file_operations { 885- struct module *owner; 886- loff_t (*llseek) (struct file *, loff_t, int); 887- ssize_t (*read) (struct file *, char *, size_t, loff_t *); 888- ssize_t (*write) (struct file *, const char *, size_t, loff_t *); 889- int (*readdir) (struct file *, void *, filldir_t); 890- unsigned int (*poll) (struct file *, struct poll_table_struct *); 26

27 891- int (*ioctl) (struct inode *, struct file *, unsigned int, unsigned long); 892- int (*mmap) (struct file *, struct vm_area_struct *); 893- int (*open) (struct inode *, struct file *); 894- int (*flush) (struct file *); 895- int (*release) (struct inode *, struct file *); 896- int (*fsync) (struct file *, struct dentry *, int datasync); 897- int (*fasync) (int, struct file *, int); 898- int (*lock) (struct file *, int, struct file_lock *); 899- ssize_t (*readv) (struct file *, const struct iovec *, unsigned long, loff_t *); 900- ssize_t (*writev) (struct file *, const struct iovec *, unsigned long, loff_t *); 901- ssize_t (*sendpage) (struct file *, struct page *, int, size_t, loff_t *, int); 902- unsigned long (*get_unmapped_area)(struct file *, unsigned long, unsigned long, unsigned long, unsigned long); 903-; Level6 j03018]% cat /proc/devices Character devices: 1 mem 2 pty 3 ttyp 4 ttys 5 cua 7 vcs 10 misc 14 sound 128 ptm 136 pts 162 raw 180 usb 226 drm 241 newnull2 242 chardev Block devices: 27

28 2 fd 3 ide0 22 ide1 9.3 [root@pw022 ~]% echo HELLO WORLD > /dev/chardev chardev [root@pw022 ~]% cat /dev/chardev HELLO WORLD /dev/chardev Level6 LevelX Linux pw / 28

Linuxデバイスドライバ.PDF

Linuxデバイスドライバ.PDF Linux hidaka@devdrv.com 2002/10/9 Linux Kernel Conference 2002 1 Linux 2 Linux 3 Software Hardware Device Algolith m Protocol Applicati on 4 CPU 128MB NIC ATI Radeon GeForce2 MX400 Matrox G400 DISK 5 OS

More information

Microsoft PowerPoint - dev1.ppt

Microsoft PowerPoint - dev1.ppt オペレーティングシステム 2005 デバイス管理 (1) 2005 年 12 月 8 日海谷治彦 1 目次 i386におけるデバイス Linuxにおけるデバイスの抽象化 Linuxから見たデバイスの分類 デバイスドライバ 2 i386 周辺の構造 第 3 回より再録 文献 6 p.57 3 I/O ポートを使った入出力 CPUからは,I/Oポートというメモリのようなモノにデータを置いたり読んだりすることで,

More information

ARM gcc Kunihiko IMAI 2009 1 11 ARM gcc 1 2 2 2 3 3 4 3 4.1................................. 3 4.2............................................ 4 4.3........................................

More information

13 I/O

13 I/O 13 I/O 98-0997-3 14 2 7 Linux OS OS OS I/O I/O TS-I/O I/O I/O TS-I/O TS-I/O 3 1 7 2 9 2.1..................... 9 2.2.................. 10 2.3 2...................... 12 2.4 Linux................... 14

More information

FreeBSD 1

FreeBSD 1 FreeBSD 1 UNIX OS 1 ( ) open, close, read, write, ioctl (cdevsw) OS DMA 2 (8 ) (24 ) 256 open/close/read/write Ioctl 3 2 2 I/O I/O CPU 4 open/close/read/write open, read, write open/close read/write /dev

More information

1 Level1 Linux kernel kernel (config) kernel 11 Kernel linux kernel /usr/src/ linux- - The Linux Kernel Archives kernel /usr/src/ /usr/src/li

1 Level1 Linux kernel kernel (config) kernel 11 Kernel linux kernel /usr/src/ linux- - The Linux Kernel Archives kernel /usr/src/ /usr/src/li UNIX Unix Kernel 2006 7 1 045709E 045713C 045736B 045739G 1 Level1 Linux kernel kernel (config) kernel 11 Kernel linux-2617 111 kernel /usr/src/ linux- - The Linux Kernel Archives kernel /usr/src/ /usr/src/linux-

More information

tutorial_lc.dvi

tutorial_lc.dvi 00 Linux v.s. RT Linux v.s. ART-Linux Linux RT-Linux ART-Linux Linux kumagai@emura.mech.tohoku.ac.jp 1 1.1 Linux Yes, No.,. OS., Yes. Linux,.,, Linux., Linux.,, Linux. Linux.,,. Linux,.,, 0..,. RT-Linux

More information

C

C C 1 2 1.1........................... 2 1.2........................ 2 1.3 make................................................ 3 1.4....................................... 5 1.4.1 strip................................................

More information

atmark-dist ディベロッパーズガイド

atmark-dist ディベロッパーズガイド atmark-dist Developers Guide http://www.atmark-techno.com/ Armadillo http://armadillo.atmark-techno.com/ SUZAKU http://suzaku.atmark-techno.com/ atmark-dist developers guide version 1.0.2 1. 1 1.1. 1 1.2.

More information

Condition DAQ condition condition 2 3 XML key value

Condition DAQ condition condition 2 3 XML key value Condition DAQ condition 2009 6 10 2009 7 2 2009 7 3 2010 8 3 1 2 2 condition 2 3 XML key value 3 4 4 4.1............................. 5 4.2...................... 5 5 6 6 Makefile 7 7 9 7.1 Condition.h.............................

More information

% finger apt-get kernel-package, libc6-dev, gcc, make, bin86, bzip2, libdb3-dev, libncurses-dev, fakeroot

% finger apt-get kernel-package, libc6-dev, gcc, make, bin86, bzip2, libdb3-dev, libncurses-dev, fakeroot apt-get % uname -r http://www.kernel.org/ % finger @kernel.org finger apt-get kernel-package, libc6-dev, gcc, make, bin86, bzip2, libdb3-dev, libncurses-dev, fakeroot apt-get apt-get # apt-get install

More information

double float

double float 2015 3 13 1 2 2 3 2.1.......................... 3 2.2............................. 3 3 4 3.1............................... 4 3.2 double float......................... 5 3.3 main.......................

More information

r07.dvi

r07.dvi 19 7 ( ) 2019.4.20 1 1.1 (data structure ( (dynamic data structure 1 malloc C free C (garbage collection GC C GC(conservative GC 2 1.2 data next p 3 5 7 9 p 3 5 7 9 p 3 5 7 9 1 1: (single linked list 1

More information

ohp07.dvi

ohp07.dvi 19 7 ( ) 2019.4.20 1 (data structure) ( ) (dynamic data structure) 1 malloc C free 1 (static data structure) 2 (2) C (garbage collection GC) C GC(conservative GC) 2 2 conservative GC 3 data next p 3 5

More information

Linux MontaVista Software Japan, Inc. 2 Linux Conference Sep/18/20

Linux MontaVista Software Japan, Inc. 2 Linux Conference Sep/18/20 Linux Linux MontaVista Software Japan, Inc. 2 Linux Conference Sep/18/20 MontaVista Software Japan, Inc. 3 Linux Conference Sep/18/20 Linux 350 300 250 200 150 100 50 0 Linux & ($mil.) 2000 2001 2002 2003

More information

r08.dvi

r08.dvi 19 8 ( ) 019.4.0 1 1.1 (linked list) ( ) next ( 1) (head) (tail) ( ) top head tail head data next 1: NULL nil ( ) NULL ( NULL ) ( 1 ) (double linked list ) ( ) 1 next 1 prev 1 head cur tail head cur prev

More information

第5回お試しアカウント付き並列プログラミング講習会

第5回お試しアカウント付き並列プログラミング講習会 qstat -l ID (qstat -f) qscript ID BATCH REQUEST: 253443.batch1 Name: test.sh Owner: uid=32637, gid=30123 Priority: 63 State: 1(RUNNING) Created at: Tue Jun 30 05:36:24 2009 Started at: Tue Jun 30 05:36:27

More information

Linux XScreenSaver T020074

Linux XScreenSaver T020074 Linux XScreenSaver T020074 Linux XScreenSaver XScreenSaver Linux Linux Linux X Window System X Window System Xlib XScreenSaver X Window System Xlib XScreenSaver Xlib vroot.h Xlib XScreenSaver Linux Linux

More information

program.dvi

program.dvi 2001.06.19 1 programming semi ver.1.0 2001.06.19 1 GA SA 2 A 2.1 valuename = value value name = valuename # ; Fig. 1 #-----GA parameter popsize = 200 mutation rate = 0.01 crossover rate = 1.0 generation

More information

slide5.pptx

slide5.pptx ソフトウェア工学入門 第 5 回コマンド作成 1 head コマンド作成 1 早速ですが 次のプログラムを head.c という名前で作成してください #include #include static void do_head(file *f, long nlines); int main(int argc, char *argv[]) { if (argc!=

More information

ohp08.dvi

ohp08.dvi 19 8 ( ) 2019.4.20 1 (linked list) ( ) next ( 1) (head) (tail) ( ) top head tail head data next 1: 2 (2) NULL nil ( ) NULL ( NULL ) ( 1 ) (double linked list ) ( 2) 3 (3) head cur tail head cur prev data

More information

untitled

untitled II yacc 005 : 1, 1 1 1 %{ int lineno=0; 3 int wordno=0; 4 int charno=0; 5 6 %} 7 8 %% 9 [ \t]+ { charno+=strlen(yytext); } 10 "\n" { lineno++; charno++; } 11 [^ \t\n]+ { wordno++; charno+=strlen(yytext);}

More information

新・明解C言語 実践編

新・明解C言語 実践編 第 1 章 見 21 1-1 見えないエラー 見 List 1-1 "max2x1.h" a, b max2 List 1-1 chap01/max2x1.h max2 "max2x1.h" #define max2(a, b) ((a) > (b)? (a) : (b)) max2 List 1-2 List 1-2 chap01/max2x1test.c max2 #include

More information

PowerPoint プレゼンテーション

PowerPoint プレゼンテーション Linux におけるデバイスドライバの 開発とデバッグの実際 株式会社デバイスドライバーズ hidaka@devdrv.com 2002/10/9 Linux Kernel Conference 2002 1 2002/10/9 Linux Kernel Conference 2002 Device Drivers 2 はじめに デバイスドライバとは? なぜ Linux なのか? デファクト コネクティビティ

More information

A/B (2018/10/19) Ver kurino/2018/soft/soft.html A/B

A/B (2018/10/19) Ver kurino/2018/soft/soft.html A/B A/B (2018/10/19) Ver. 1.0 kurino@math.cst.nihon-u.ac.jp http://edu-gw2.math.cst.nihon-u.ac.jp/ kurino/2018/soft/soft.html 2018 10 19 A/B 1 2018 10 19 2 1 1 1.1 OHP.................................... 1

More information

II ( ) prog8-1.c s1542h017%./prog8-1 1 => 35 Hiroshi 2 => 23 Koji 3 => 67 Satoshi 4 => 87 Junko 5 => 64 Ichiro 6 => 89 Mari 7 => 73 D

II ( ) prog8-1.c s1542h017%./prog8-1 1 => 35 Hiroshi 2 => 23 Koji 3 => 67 Satoshi 4 => 87 Junko 5 => 64 Ichiro 6 => 89 Mari 7 => 73 D II 8 2003 11 12 1 6 ( ) prog8-1.c s1542h017%./prog8-1 1 => 35 Hiroshi 2 => 23 Koji 3 => 67 Satoshi 4 => 87 Junko 5 => 64 Ichiro 6 => 89 Mari 7 => 73 Daisuke 8 =>. 73 Daisuke 35 Hiroshi 64 Ichiro 87 Junko

More information

: Nonblocking I/O readpartial read EOF Solaris FILE 256 ungetc SEGV errno stdio considered harmful p.

: Nonblocking I/O readpartial read EOF Solaris FILE 256 ungetc SEGV errno stdio considered harmful p. stdio considered harmful akr@m17n.org 2005 06 02 stdio considered harmful p. : Nonblocking I/O readpartial read EOF Solaris FILE 256 ungetc SEGV errno stdio considered harmful p. : stdio stdio Nonblocking

More information

HITACHI Gigabit Fibre Channel (SUSE Linux Enterprise Server IOCard-FP2-Z-199(1)

HITACHI Gigabit Fibre Channel (SUSE Linux Enterprise Server IOCard-FP2-Z-199(1) HITACHI Gigabit Fibre Channel (SUSE Linux Enterprise Server IOCard-FP2-Z-199(1) 2 (VCCI) Linux Linus Torvalds Red Hat Red Hat Inc. SUSE SUSE LLC All rights reservedcopyright 2014, Hitachi,Ltd. Licensed

More information

CM-3G 周辺モジュール拡張技術文書 MS5607センサ(温度、気圧)

CM-3G 周辺モジュール拡張技術文書 MS5607センサ(温度、気圧) CM-3G 周辺モジュール拡張技術文書 MS5607 センサ ( 温度 気圧 ) ( 第 1 版 ) Copyright (C)2016 株式会社コンピューテックス 目次 1. はじめに... 1 2. MS5607 について... 1 3. 接続図... 1 4. アプリケーション ソース... 2 5. アプリケーションのコンパイル方法... 7 6. アプリケーションの実行... 8 1. はじめに

More information

( ) 3 1 ( ), ( ).. 1

( ) 3 1 ( ), ( ).. 1 30 2019 1 22 ( ) 3 1 ( ), 2-9 5 ( ).. 1 1. ( T):,? ( O):, T:,? O:!?,!?,... T:,,,? O:!?,,, OS? T:,, SSD, OS, CPU, OS SSD,? O:,,...? T: : OS,,, ( ) (1),. Linux, Unix OS. (2), (permission), (owner)., ( :

More information

新版明解C言語 実践編

新版明解C言語 実践編 2 List - "max.h" a, b max List - max "max.h" #define max(a, b) ((a) > (b)? (a) : (b)) max List -2 List -2 max #include "max.h" int x, y; printf("x"); printf("y"); scanf("%d", &x); scanf("%d", &y); printf("max(x,

More information

Microsoft Word - C.....u.K...doc

Microsoft Word - C.....u.K...doc C uwêííôöðöõ Ð C ÔÖÐÖÕ ÐÊÉÌÊ C ÔÖÐÖÕÊ C ÔÖÐÖÕÊ Ç Ê Æ ~ if eíè ~ for ÒÑÒ ÌÆÊÉÉÊ ~ switch ÉeÍÈ ~ while ÒÑÒ ÊÍÍÔÖÐÖÕÊ ~ 1 C ÔÖÐÖÕ ÐÊÉÌÊ uê~ ÏÒÏÑ Ð ÓÏÖ CUI Ô ÑÊ ÏÒÏÑ ÔÖÐÖÕÎ d ÈÍÉÇÊ ÆÒ Ö ÒÐÑÒ ÊÔÎÏÖÎ d ÉÇÍÊ

More information

1.... 1 2.... 1 2.1. RATS... 1 2.1.1. expat... 1 2.1.2. expat... 1 2.1.3. expat... 2 2.2. RATS... 2 2.2.1. RATS... 2 2.2.2.... 3 3. RATS... 4 3.1.... 4 3.2.... 4 3.3.... 6 3.3.1.... 6 3.3.2.... 6 3.3.3....

More information

3.2 Linux root vi(vim) vi emacs emacs 4 Linux Kernel Linux Git 4.1 Git Git Linux Linux Linus Fedora root yum install global(debian Ubuntu apt-get inst

3.2 Linux root vi(vim) vi emacs emacs 4 Linux Kernel Linux Git 4.1 Git Git Linux Linux Linus Fedora root yum install global(debian Ubuntu apt-get inst 1 OS Linux OS OS Linux Kernel 900 1000 IPA( :http://www.ipa.go.jp/) 8 12 ( ) 16 ( ) 4 5 22 60 2 3 6 Linux Linux 2 LKML 3 3.1 Linux Fedora 13 Ubuntu Fedora CentOS 3.2 Linux root vi(vim) vi emacs emacs 4

More information

東京エリア Debian 勉強会 - 資料

東京エリア Debian 勉強会 - 資料 .... Debian dancer@debian.or.jp IRC nick: dancerj 2009 1 17 Agenda / / ustream Debian Debian 2009 2008 12 / / ustream Debian Debconf Debian 2008 2009 Debian JP on IAX 2009 1 9 IAX :asterisk :iaxcomm 1

More information

最新Linuxデバイスドライバ開発応用-修正版-PDF.PDF

最新Linuxデバイスドライバ開発応用-修正版-PDF.PDF Linux Kernel Conference 2004 Linux - / - info@devdrv.co.jp 2004/10/14 Device Drivers Limited 1 Device Drivers Limited 2 IF Device Drivers Limited 3 Linux Device Drivers Limited 4 2.6 2.6 2.6 Device Drivers

More information

ex01.dvi

ex01.dvi ,. 0. 0.0. C () /******************************* * $Id: ex_0_0.c,v.2 2006-04-0 3:37:00+09 naito Exp $ * * 0. 0.0 *******************************/ #include int main(int argc, char **argv) double

More information

大統一Debian勉強会 gdb+python拡張を使ったデバッグ手法

大統一Debian勉強会 gdb+python拡張を使ったデバッグ手法 Debian 2013 gdb+python nozzy@debian.or.jp 2013 6 29 Level Debian Up Debian Debian debian sid unstable Debian debian sid unstable *-dbg Debian debian sid unstable *-dbg gdb Debian debian sid unstable *-dbg

More information

1.ppt

1.ppt /* * Program name: hello.c */ #include int main() { printf( hello, world\n ); return 0; /* * Program name: Hello.java */ import java.io.*; class Hello { public static void main(string[] arg)

More information

Introduction Purpose This training course demonstrates the use of the High-performance Embedded Workshop (HEW), a key tool for developing software for

Introduction Purpose This training course demonstrates the use of the High-performance Embedded Workshop (HEW), a key tool for developing software for Introduction Purpose This training course demonstrates the use of the High-performance Embedded Workshop (HEW), a key tool for developing software for embedded systems that use microcontrollers (MCUs)

More information

lexex.dvi

lexex.dvi (2018, c ) http://istksckwanseiacjp/ ishiura/cpl/ 4 41 1 mini-c lexc,, 2 testlexc, lexc mini-c 1 ( ) mini-c ( ) (int, char, if, else, while, return 6 ) ( ) (+, -, *, /, %, &, =, ==,!=, >, >=,

More information

月刊リナックスジャパン掲載記事

月刊リナックスジャパン掲載記事 7Linux RESOURCE 1 Linux I/O root 1 root chmod +s root 2 2 3 1bit CPU Linux kill Ctrl c Segmentation fault 3 4 1 10/1 2 3core file 4 fsck Linux Japan August 2001 file_operation 3 I/O 2 3 1 1 5 OS insmod

More information

para02-2.dvi

para02-2.dvi 2002 2 2002 4 23 : MPI MPI 1 MPI MPI(Message Passing Interface) MPI UNIX Windows Machintosh OS, MPI 2 1 1 2 2.1 1 1 1 1 1 1 Fig. 1 A B C F Fig. 2 A B F Fig. 1 1 1 Fig. 2 2.2 Fig. 3 1 . Fig. 4 Fig. 3 Fig.

More information

LinuxDeviceDriver2003-PDF.PDF

LinuxDeviceDriver2003-PDF.PDF Linux Kernel Conference 2003 Linux info@devdrv.com 2003/10/9 Device Drivers Limited 1 Linux 2.6 Device Drivers Limited 2 SpinLock Atomic (SMP) HyperThreading(HT) tasklet task_queue /proc Device Drivers

More information

RHEA key

RHEA key 2 P (k, )= k e k! 3 4 Probability 0.4 0.35 0.3 0.25 Poisson ( λ = 1) Poisson (λ = 3) Poisson ( λ = 10) Poisson (λ = 20) Poisson ( λ = 30) Gaussian (µ = 1, s = 1) Gaussian ( µ = 3, s = 3) Gaussian (µ =

More information

ex12.dvi

ex12.dvi 1 0. C, char., char, 0,. C, ("),., char str[]="abc" ; str abc.,, str 4. str 3. char str[10]="abc" ;, str 10, str 3., char s[]="abc", t[10] ;, t = s. ASCII, 0x00 0x7F, char., "abc" 3, 1. 1 8 256, 2., 2

More information

I J

I J I 065763J 8 7 7 31 jikken/ +----- accumulation_demupa.c +----- accumulation_rain.c +----- frequency_demupa.c +----- frequency_rain.c +----- go.sh +----- graph_maker.sh +----- mesure-ryudai/ 2007/4/1 2007/6/30

More information

r11.dvi

r11.dvi 19 11 ( ) 2019.4.20 1 / 1.1 ( n n O(n 2 O(n 2 ) ( 1 d n 1 n logn O(nlogn n ( n logn C 1.2 ( ( merge 2 1 1 3 1 4 5 4 2 3 7 9 7 1 2 3 4 5 7 9 1: 2 ivec merge int *ivec_new(int size) { int *a = (int*)malloc((size+1)

More information

ohp11.dvi

ohp11.dvi 19 11 ( ) 2019.4.20 1 / ( ) n O(n 2 ) O(n 2 ) ( ) 1 d n 1 n logn O(nlogn) n ( n logn C ) 2 ( ) ( merge) 2 1 1 3 1 4 5 4 2 3 7 9 7 1 2 3 4 5 7 9 1: 2 ivec merge 3 ( ) (2) int *ivec_new(int size) { int *a

More information

MINI2440マニュアル

MINI2440マニュアル Open-JTAG LPC2388 + GCC + Eclipse http://www.csun.co.jp info@csun.co.jp Ver1.4 2009/7/31 LPC2388 OpenJTAG copyright@2009 http://www.csun.co.jp info@csun.co.jp 1 ...3 ARM...4...5...6 4.2 OpenJTAG...6 4.2...8

More information

waylandを動かす

waylandを動かす wayland nozzy@debian.or.jp 2013 11 16 2013 11 16 1/31 wayland! weston! wayland weston wayland Kristian Høgsberg 2013 11 16 2/31 wayland! weston! 2013 11 16 3/31 weston ( ) 2013 11 16 4/31 weston (weston.ini

More information

ohp03.dvi

ohp03.dvi 19 3 ( ) 2019.4.20 CS 1 (comand line arguments) Unix./a.out aa bbb ccc ( ) C main void int main(int argc, char *argv[]) {... 2 (2) argc argv argc ( ) argv (C char ) ( 1) argc 4 argv NULL. / a. o u t \0

More information

GNU Emacs GNU Emacs

GNU Emacs GNU Emacs GNU Emacs 2015 10 2 1 GNU Emacs 1 1.1....................................... 1 1.2....................................... 1 1.2.1..................................... 1 1.2.2.....................................

More information

Linux on ITRON-ハイブリッド構造の実装

Linux on ITRON-ハイブリッド構造の実装 Linux on ITRON ハイブリッド構造の実装 目次... 2 Linux... 3... 4... 5 Linux Emblix... 6... 6... 7 OS... 8 FIFO... 8... 11...14 OS...14 Linux...17...18 OS...20...21...22...22 /...25 OS...28 ITRON...29...30 /...30 ITRON...30

More information

ex01.dvi

ex01.dvi ,. 0. 0.0. C () /******************************* * $Id: ex_0_0.c,v.2 2006-04-0 3:37:00+09 naito Exp $ * * 0. 0.0 *******************************/ #include int main(int argc, char **argv) { double

More information

橡Pro PDF

橡Pro PDF 1 void main( ) char c; /* int c; */ int sum=0; while ((c = getchar())!= EOF) if(isdigit(c) ) sum += (c-'0'); printf("%d\n", sum); main()int i,sum=0; for(i=0;i

More information

新コンフィギュレータのフレームワークについて

新コンフィギュレータのフレームワークについて : 2007 12 7 6: 2009 5 9 TOPPERS 1.... 4 1.1... 4 1.2 TOPPERS... 4 2.... 4 2.1... 4 3.... 8 4.... 9 4.1... 9 4.2... 10 4.3... 10 4.3.1... 11 4.3.2 INCLUDE... 11 4.3.3 C... 12 4.4 API... 14 4.2.1 API...

More information

/ SCHEDULE /06/07(Tue) / Basic of Programming /06/09(Thu) / Fundamental structures /06/14(Tue) / Memory Management /06/1

/ SCHEDULE /06/07(Tue) / Basic of Programming /06/09(Thu) / Fundamental structures /06/14(Tue) / Memory Management /06/1 I117 II I117 PROGRAMMING PRACTICE II 2 MEMORY MANAGEMENT 2 Research Center for Advanced Computing Infrastructure (RCACI) / Yasuhiro Ohara yasu@jaist.ac.jp / SCHEDULE 1. 2011/06/07(Tue) / Basic of Programming

More information

untitled

untitled H8/300,H8S,H8SX [H8S,H8/300 Tool Chain Ver6.2.0.0] #define Inline static inline //************************************************** Inline char sil_and_mem(char *mem,char and) return (*((volatile

More information

unix.dvi

unix.dvi 1 UNIX 1999 4 27 1 UNIX? 2 1.1 Windows/Macintosh? : : : : : : : : : : : : : : : : : : : : : : : : 2 1.2 UNIX OS : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : 2 1.3 : : : : : : : : : : : :

More information

imcs04 ソフトウェアマニュアル imcs04 ソフトウェアマニュアル Ver1.4 株式会社イクシスリサーチ , ixs Research Corporation All right reserved.

imcs04 ソフトウェアマニュアル imcs04 ソフトウェアマニュアル Ver1.4 株式会社イクシスリサーチ , ixs Research Corporation All right reserved. Ver1.4 株式会社イクシスリサーチ 1 1998 2011, ixs Research Corporation All right reserved. 目 次 1. 概要...3 2. エンドポイント...3 2.1 エンドポイント2...3 2.2 エンドポイント3...3 3 USBドライバについて...5 3.1 デバイスのオープン, クローズ...5 3.2 imcs04 のデータを取り込む...5

More information

Java updated

Java updated Java 2003.07.14 updated 3 1 Java 5 1.1 Java................................. 5 1.2 Java..................................... 5 1.3 Java................................ 6 1.3.1 Java.......................

More information

X Window System X X &

X Window System X X & 1 1 1.1 X Window System................................... 1 1.2 X......................................... 1 1.3 X &................................ 1 1.3.1 X.......................... 1 1.3.2 &....................................

More information

1 $ cat aboutipa 2 IPA is a Japanese quasi-government 3 organization established in accor- 4 dance with The Law for Information 5 Processing Technolog

1 $ cat aboutipa 2 IPA is a Japanese quasi-government 3 organization established in accor- 4 dance with The Law for Information 5 Processing Technolog 1 $ cat aboutipa 2 IPA is a Japanese quasi-government 3 organization established in accor- 4 dance with The Law for Information 5 Processing Technology Promotion, 6 (Law No.90, May 22, 1979). 7 $./upper

More information

‚æ4›ñ

‚æ4›ñ ( ) ( ) ( ) A B C D E F G H I J K L M N O P Q R S T U V W X Y Z a b c d e f g h i j k l m n o p q r s t u v w x y z 0 1 2 3 4 5 6 7 8 9 (OUS) 9 26 1 / 28 ( ) ( ) ( ) A B C D Z a b c d z 0 1 2 9 (OUS) 9

More information

2 1. Ubuntu 1.1 OS OS OS ( OS ) OS ( OS ) VMware Player VMware Player jp/download/player/ URL VMware Plaeyr VMware

2 1. Ubuntu 1.1 OS OS OS ( OS ) OS ( OS ) VMware Player VMware Player   jp/download/player/ URL VMware Plaeyr VMware 1 2010 k-okada@jsk.t.u-tokyo.ac.jp http://www.jsk.t.u-tokyo.ac.jp/~k-okada/lecture/ 2010 4 5 Linux 1 Ubuntu Ubuntu Linux 1 Ubuntu Ubuntu 3 1. 1 Ubuntu 2. OS Ubuntu OS 3. OS Ubuntu https://wiki.ubuntulinux.jp/ubuntutips/install/installdualboot

More information

[user@linux tmp]$ tar xzvf utvpn-src-unix-v100-7092-beta-2010.06.25.tar.gz [user@linux tmp]$ cd utvpn-unix-v100-7092-beta [user@linux utvpn-unix-v100-7092-beta]$ ls License-ja.txt configure makefiles src

More information

Red Hat Enterprise Linux ES (v. 3)

Red Hat Enterprise Linux ES (v. 3) 2005-02-01 Red Hat Enterprise Linux ES (v. 3) PRIMERGY Linux Linux PRIMERGY Linux (SupportDesk Product ) All Rights Reserved, Copyright (C) 2004 1 1. 1.1 Linux ) SCSI ID=1, 2, 3 /dev/sda, /dev/sdb, /dev/sdc

More information

DA100データアクイジションユニット通信インタフェースユーザーズマニュアル

DA100データアクイジションユニット通信インタフェースユーザーズマニュアル Instruction Manual Disk No. RE01 6th Edition: November 1999 (YK) All Rights Reserved, Copyright 1996 Yokogawa Electric Corporation 801234567 9 ABCDEF 1 2 3 4 1 2 3 4 1 2 3 4 1 2

More information

C B

C B C 095707B 2010 6 8 1 LEVE1 2 1.1 LEVEL 1.1................................................ 2 1.1.1 1................................................ 2 1.1.2 1.2..............................................

More information

[ 1] 1 Hello World!! 1 #include <s t d i o. h> 2 3 int main ( ) { 4 5 p r i n t f ( H e l l o World!! \ n ) ; 6 7 return 0 ; 8 } 1:

[ 1] 1 Hello World!! 1 #include <s t d i o. h> 2 3 int main ( ) { 4 5 p r i n t f ( H e l l o World!! \ n ) ; 6 7 return 0 ; 8 } 1: 005 9 7 1 1.1 1 Hello World!! 5 p r i n t f ( H e l l o World!! \ n ) ; 7 return 0 ; 8 } 1: 1 [ ] Hello World!! from Akita National College of Technology. 1 : 5 p r i n t f ( H e l l o World!! \ n ) ;

More information

解きながら学ぶC++入門編

解きながら学ぶC++入門編 !... 38!=... 35 "... 112 " "... 311 " "... 4, 264 #... 371 #define... 126, 371 #endif... 369 #if... 369 #ifndef... 369 #include... 3, 311 #undef... 371 %... 17, 18 %=... 85 &... 222 &... 203 &&... 40 &=...

More information

tuat1.dvi

tuat1.dvi ( 1 ) http://ist.ksc.kwansei.ac.jp/ tutimura/ 2012 6 23 ( 1 ) 1 / 58 C ( 1 ) 2 / 58 2008 9 2002 2005 T E X ptetex3, ptexlive pt E X UTF-8 xdvi-jp 3 ( 1 ) 3 / 58 ( 1 ) 4 / 58 C,... ( 1 ) 5 / 58 6/23( )

More information

/* do-while */ #include <stdio.h> #include <math.h> int main(void) double val1, val2, arith_mean, geo_mean; printf( \n ); do printf( ); scanf( %lf, &v

/* do-while */ #include <stdio.h> #include <math.h> int main(void) double val1, val2, arith_mean, geo_mean; printf( \n ); do printf( ); scanf( %lf, &v 1 http://www7.bpe.es.osaka-u.ac.jp/~kota/classes/jse.html kota@fbs.osaka-u.ac.jp /* do-while */ #include #include int main(void) double val1, val2, arith_mean, geo_mean; printf( \n );

More information

slide6.pptx

slide6.pptx ソフトウェア工学入門 第 6 回コマンド作成 2 ファイルシステム 今後のスケジュール 5/28. コマンド作成 2 ( 本日 ) 6/4. ファイルシステム プロセス ハードウェア 6/11. 第 2 回個別試験 grep プログラム 1 次のプログラムを作成し grep.c という名前で保存しなさい #include #include #include

More information

Complex Lab – Operating Systems - Graphical Console

Complex Lab – Operating Systems - Graphical Console Complex Lab Operating Systems Graphical Console Martin Küttler Last assignment Any questions? Any bug reports, whishes, etc.? 1 / 13 We are here Pong Server Paddle Client 1 Paddle Client 2 Memory Management

More information

- - http://168iroha.net 018 10 14 i 1 1 1.1.................................................... 1 1.................................................... 7.1................................................

More information

VLD Kazutoshi Kobayashi

VLD Kazutoshi Kobayashi VLD Kazutoshi Kobayashi (kobayasi@kuee.kyoto-u.ac.jp) 2005 8 26-29 1, Verilog-HDL, Verilog-HDL. Verilog-HDL,, FPGA,, HDL,. 1.1, 1. (a) (b) (c) FPGA (d). 2. 10,, Verilog-HDL, FPGA,. 1.2,,,, html. % netscape

More information

debian_install.dvi

debian_install.dvi 2002 Debian GNU/Linux 3.0 1 potato 1.1 Windows 1. 3 2. rescue.bin root.bin driver-1.bin 1 1.2 1. Debian GNU/Linux Debian http://http.us.debian.org/debian http://ftp.jp.debian.org Fig. 1 Fig. 1 Debian 2.

More information

r03.dvi

r03.dvi 19 ( ) 019.4.0 CS 1 (comand line arguments) Unix./a.out aa bbb ccc ( ) C main void... argc argv argc ( ) argv (C char ) ( 1) argc 4 argv NULL. / a. o u t \0 a a \0 b b b \0 c c c \0 1: // argdemo1.c ---

More information

untitled

untitled RPC (( Remote Procedure Call (RPC: Message-Oriented Middleware (MOM) data-streaming =(protocol) A B A B Connection protocol = connection oriented protocol TCP (Transmission Control Protocol) connectionless

More information

新・明解C言語 ポインタ完全攻略

新・明解C言語 ポインタ完全攻略 2 1-1 1-1 /* 1-1 */ 1 int n = 100; int *p = &n; printf(" n %d\n", n); /* n int */ printf("*&n %d\n", *&n); /* *&n int */ printf(" p %p\n", p); /* p int * */ printf("&*p %p\n", &*p); /* &*p int * */ printf("sizeof(n)

More information

Raspberry Pi3 / arm64 - Debian/Ubuntu ミートアップ in 札幌

Raspberry Pi3 / arm64 - Debian/Ubuntu ミートアップ in 札幌 Raspberry Pi3 / arm64 Debian/Ubuntu in 2016 6 17 : @iwamatsu Debian Project Official Developer Debian : Debian linux kernel, Debian Bluetooth, Debian Science (OpenCV), Erlang, Debian Go : Linux kernel

More information

2008 DS T050049

2008 DS T050049 DS T050049. PSP DS DS DS RPG DS OS Windows XP DevkiPro OS DS CPU ARM devkitarm MSYS MinGW MSYS MinGW Unix OS C++ C++ make nds nds DS DS micro SD Card nds DS DS DS nds C Java C++ nds nds DS 2008 DS T050049

More information

Version Page 1

Version Page 1 HP Compartment Guard for Linux Version 2.0 Version 2.0 168-8585 3 29 21 03-3331-6111 Page 1 Version 2.0 Revision Rev1.0 2004/3/4 Version 2.0 Release K.Iwasaki Rev1.1 2004/3/17 K.Iwasaki Page 2 Version

More information

1 C STL(1) C C C libc C C C++ STL(Standard Template Library ) libc libc C++ C STL libc STL iostream Algorithm libc STL string vector l

1 C STL(1) C C C libc C C C++ STL(Standard Template Library ) libc libc C++ C STL libc STL iostream Algorithm libc STL string vector l C/C++ 2007 6 18 1 C STL(1) 2 1.1............................................... 2 1.2 stdio................................................ 3 1.3.......................................... 10 2 11 2.1 sizeof......................................

More information

r1.dvi

r1.dvi 2014 1 2014.4.10 0 / 1 / 2 / 3 Lisp 4 5 ( ) 1 (5 1 ) 5 1 1.1? 0 1 (bit sequence) 5 101 3 11 2 (binary system) 2 1000 8 1 ( ) ( )? ( 1) r1 1000 1001 r2 1002... r3 1: (memory) (address) CPU (instruction)

More information

Original : Hello World! (0x0xbfab85e0) Copy : Hello World! (0x0x804a050) fgets mstrcpy malloc mstrcpy (main ) mstrcpy malloc free fgets stream 1 ( \n

Original : Hello World! (0x0xbfab85e0) Copy : Hello World! (0x0x804a050) fgets mstrcpy malloc mstrcpy (main ) mstrcpy malloc free fgets stream 1 ( \n 2008 3 10 1 mstrcpy char *mstrcpy(const char *src); mstrcpy malloc (main free ) stdio.h fgets char *fgets(char *s, int size, FILE *stream); s size ( ) stream FILE ( man ) 40 ( ) %./a.out String : test

More information

RX600 & RX200シリーズ アプリケーションノート RX用仮想EEPROM

RX600 & RX200シリーズ アプリケーションノート RX用仮想EEPROM R01AN0724JU0170 Rev.1.70 MCU EEPROM RX MCU 1 RX MCU EEPROM VEE VEE API MCU MCU API RX621 RX62N RX62T RX62G RX630 RX631 RX63N RX63T RX210 R01AN0724JU0170 Rev.1.70 Page 1 of 33 1.... 3 1.1... 3 1.2... 3

More information

東京エリアDebian勉強会   Buffalo Linkstation向け Debian Installer - 第139回 2016年5月度

東京エリアDebian勉強会   Buffalo Linkstation向け Debian Installer - 第139回 2016年5月度 Debian Buffalo Linkstation Debian Installer 139 2016 5 Roger Shimizu 2016 5 21 Agenda 1 2 3 Buffalo Linkstation Debian Installer 4 Linkstation Debian 5 6 Demo 10 ( ) Debian user. 2 Linkstation LS-WXL

More information

PC Windows 95, Windows 98, Windows NT, Windows 2000, MS-DOS, UNIX CPU

PC Windows 95, Windows 98, Windows NT, Windows 2000, MS-DOS, UNIX CPU 1. 1.1. 1.2. 1 PC Windows 95, Windows 98, Windows NT, Windows 2000, MS-DOS, UNIX CPU 2. 2.1. 2 1 2 C a b N: PC BC c 3C ac b 3 4 a F7 b Y c 6 5 a ctrl+f5) 4 2.2. main 2.3. main 2.4. 3 4 5 6 7 printf printf

More information

超初心者用

超初心者用 3 1999 10 13 1. 2. hello.c printf( Hello, world! n ); cc hello.c a.out./a.out Hello, world printf( Hello, world! n ); 2 Hello, world printf n printf 3. ( ) int num; num = 100; num 100 100 num int num num

More information

slide4.pptx

slide4.pptx ソフトウェア工学入門 第 4 回ライブラリ関数 ライブラリ関数 stdio stdio : 標準入出力ライブラリ カーネルレベルのストリームに API を追加し インタフェースを提供する カーネル fd read(2) write(2) stdio バッファ BUFSIZ プログラム BUFSIZ ごと 小さい単位 バッファ : 一時的にデータを保存しておく場所のことバッファリング : バッファを経由してデータをやり取りすること

More information

£Ã¥×¥í¥°¥é¥ß¥ó¥°ÆþÌç (2018) - Â裵²ó ¨¡ À©¸æ¹½Â¤¡§¾ò·ïʬ´ô ¨¡

£Ã¥×¥í¥°¥é¥ß¥ó¥°ÆþÌç (2018) - Â裵²ó  ¨¡ À©¸æ¹½Â¤¡§¾ò·ïʬ´ô ¨¡ (2018) 2018 5 17 0 0 if switch if if ( ) if ( 0) if ( ) if ( 0) if ( ) (0) if ( 0) if ( ) (0) ( ) ; if else if ( ) 1 else 2 if else ( 0) 1 if ( ) 1 else 2 if else ( 0) 1 if ( ) 1 else 2 (0) 2 if else

More information

WinHPC ppt

WinHPC ppt MPI.NET C# 2 2009 1 20 MPI.NET MPI.NET C# MPI.NET C# MPI MPI.NET 1 1 MPI.NET C# Hello World MPI.NET.NET Framework.NET C# API C# Microsoft.NET java.net (Visual Basic.NET Visual C++) C# class Helloworld

More information

file"a" file"b" fp = fopen("a", "r"); while(fgets(line, BUFSIZ, fp)) {... fclose(fp); fp = fopen("b", "r"); while(fgets(line, BUFSIZ, fp)) {... fclose

filea fileb fp = fopen(a, r); while(fgets(line, BUFSIZ, fp)) {... fclose(fp); fp = fopen(b, r); while(fgets(line, BUFSIZ, fp)) {... fclose I117 9 2 School of Information Science, Japan Advanced Institute of Science and Technology file"a" file"b" fp = fopen("a", "r"); while(fgets(line, BUFSIZ, fp)) {... fclose(fp); fp = fopen("b", "r"); while(fgets(line,

More information

2008 IIA (program) pro(before)+gram(write) (artificial language) (programming languege) (programming) (machine language) (assembly language) ( )

2008 IIA (program) pro(before)+gram(write) (artificial language) (programming languege) (programming) (machine language) (assembly language) ( ) 2008 IIA 1 1.1 (program) pro(before)+gram(write) (artificial language) (programming languege) (programming) (machine language) (assembly language) () (high-level language) 3 (machine language) (CPU) 0

More information

£Ã¥×¥í¥°¥é¥ß¥ó¥°ÆþÌç (2018) - Â裶²ó ¨¡ À©¸æ¹½Â¤¡§·«¤êÊÖ¤· ¨¡

£Ã¥×¥í¥°¥é¥ß¥ó¥°ÆþÌç (2018) - Â裶²ó  ¨¡ À©¸æ¹½Â¤¡§·«¤êÊÖ¤· ¨¡ (2018) 2018 5 24 ( ) while ( ) do while ( ); for ( ; ; ) while int i = 0; while (i < 100) { printf("i = %3d\n", i); i++; while int i = 0; i while (i < 100) { printf("i = %3d\n", i); i++; while int i =

More information

Quartus II ハンドブック Volume 5、セクションIV. マルチプロセッサの調整

Quartus II ハンドブック  Volume 5、セクションIV. マルチプロセッサの調整 IV. SOPC Builder Nios II 9 Avalon Mutex 10 Avalon Mailbox 9 10 / 9 v5.1.0 2005 5 v5.0.0 Nios II 2004 12 v1.0 10 v5.1.0 2005 5 v5.0.0 Altera Corporation IV 1 Quartus II Volume 5 IV 2 Altera Corporation

More information

I /07/30 Dependable Network Innovation Center, Japan Advanced Institute of Science and Technology

I /07/30 Dependable Network Innovation Center, Japan Advanced Institute of Science and Technology I441 2013/07/30 Dependable Network Innovation Center, Japan Advanced Institute of Science and Technology I/O Japan Advanced Institute of Science and Technology 2013/07/30 1 fork/pthread create I/O Japan

More information