More Related Content
More from Takuya ASADA (20)
SMP Implementation on *BSD/MIPS
- 2. ∧ ∧
( ω ) ≡
( ≡
/ )
(/ ∪
- 4. MIPS
• SGI
• DEC NEC
• Windows CE
NINTENDO64 PS PS2 PSP
• 1999 RISC 1/3 MIPS
• ARM
- 5. MIPS
BSD
• BSD MIPS NetBSD
Mach
• NetBSD 1.2 1996 DECstation
•
IIJ SEIL Juniper JunOS
- 6. MIPS SMP
• MIPS SMP
SGI
SGI Linux/MIPS
BSD
• SoC
- 7. MIPS
•
• Broadcom SiByte SB-1 Cisco
• Cavium Networks OCTEON
• 2010
• RMI XLR Processor/XLS Processor
• SONY PSP PSP CPU R4000×2
IO
- 8. BSD/MIPS SMP
• SGI BSD
SMP
• NetBSD Octane2
64bit 64bit
BSD OpenBSD OpenBSD
• CPU
- 10. OCTANE2
• CPU: R12000 400MHz 2MB L2 x 2
• RAM: 1024MB
• SCSI HDD
• 100BASE-T Ethernet
- 12. CPU
MP
• CPU cpu_info
• etc..
• MIPS
extern struct cpu_info cpu_info_primary;
#define
curcpu()
(&cpu_info_primary)
• CPU cpu_info curcpu()
MP
- 13. •
volatile intrmask_t cpl;
int splraise(int newcpl) {
int oldcpl;
__asm__ (" .set noreordern");
oldcpl = cpl;
cpl = oldcpl | newcpl;
__asm__ (" syncn .set reordern");
return (oldcpl);
}
• cpl cpu_info →curcpu()->ci_cpl
• (><;;
- 14. •
→
• cpu_info
•
CPU
•
- 15. MP ,
MUTEX
•
• spinlock
• atomic MIPS LL/SC
•
• MUTEX
• →
• mtx_enter(), mtx_try_enter()
•
- 16. • Q: extern int cnt; cnt++;
• A:
r0←cnt
r1←r0
r2←r1 + 1
r0 ←r2
• CPU CPU
•
LL/SC
- 19. IPI
•
cpu_unidle, signal, TLB shootdown
•
IPI: Inter-Processor Interrupt
•
- 21. MP
•
•
→CPU TLB
• TLB
• →TLB Shootdown
- 22. '()*+, -./01
!"#$%&
!!"#$%&'(&)*+,-.
!"#$%&'(&)*+, .
!2+345678
!-./019:;<=
>?@ABCD7E
>?@ABCD7E+
35FG+'0HI
!-./019"J#
$AB
!K:;<5=>? !"#$
!"#$%&
L-./01/M !!"#$%&'(&)*+,-.
!!"#$%&'(&)*+, .
!"#$%&'/+!-!. 9NOP
QRSTUC678V 2+34MY0678 !"#$
WXI Z[OPQRSTU !"#$%&
C678VWXI !!"#$%&'(&)*+,-.
2+34V 2+34MY0678
Z[OPQRSTU
C678VWXI
C 8VWXI
2+345Y0678 !=>?AB@FG+ !=>?AB@FG+
bcde bcde
"#$-]^@_9 !K:;<5=>? !K:;<5=>?
`a !!"#$%&'(&)*+!,-!0!1
!!"#$%&'(&)*+ ,- 0 1 !!"#$%&'(&)*+!,-!0!1
$ ' )*+
!"#$-]^@_9 !"#$-]^@_9
`a `a
fghi )G+j1k0Y^lmno 0.
- 26. • VM syuu1228
BSD/MIPS SMP, Plan9, KVM, UNIX etc...
, http://bit.ly/67BvV
• KVM softlab
KVM , Intel-VT, AMD SVM,
http://bit.ly/lTFlw
- 27. • P2PSIP
OverlayWeaver, Genkidama, DHT, P2P,
, : http://bit.ly/phIp4
•
, , ,