亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? semalib.s

?? vxwork源代碼
?? S
?? 第 1 頁 / 共 2 頁
字號:
/* semALib.s - i80x86 internal VxWorks binary semaphore assembly library *//* Copyright 1984-2002 Wind River Systems, Inc. *//*modification history--------------------01l,20mar02,hdn  preserved previous state of the int enable bit (spr 74016)01k,09nov01,pcm  added VxWorks semaphore events01j,23aug01,hdn  added FUNC/FUNC_LABEL, replaced .align with .balign01i,30apr98,cjtc bug fixes in semaphore instrumentation01h,28apr98,pr   fixed problem with registers in WV code.01g,16apr98,pr   cleanup.01f,17feb98,pr   added WindView 2.0 code.01f,24jun97,sub  fixed semTakeGlobal and semGiveGlobal for VxMP - SPR # 883301e,29jul96,sbs  Made windview conditionally compile.01d,08aug94,hdn  added support for WindView.01c,02jun93,hdn  split into sem[CM]ALib.s to increase modularity.		 added shared memory semaphores support.		 added signal restart.		 updated to 5.1		  - fixed #else and #endif		  - changed ASMLANGUAGE to _ASMLANGUAGE		  - changed copyright notice01b,13oct92,hdn  debugged.01a,07apr92,hdn  written based on TRON version.*//*DESCRIPTIONThis module contains internals to the VxWorks kernel.These routines have been coded in assembler because they are optimized forperformance.*/#define _ASMLANGUAGE#include "vxWorks.h"#include "vwModNum.h"#include "asm.h"#include "eventLib.h"#include "semLib.h"#include "private/semLibP.h"#include "private/classLibP.h"#include "private/taskLibP.h"#include "private/eventP.h"		.data	.globl	FUNC(copyright_wind_river)	.long	FUNC(copyright_wind_river)#ifndef PORTABLE	/* externals */	.globl	FUNC(semIntRestrict)	.globl	FUNC(semInvalid)	.globl	FUNC(semGiveDefer)	.globl	FUNC(windExit)	.globl	FUNC(windPendQPut)	.globl	FUNC(windPendQGet)	.globl	VAR(smObjPoolMinusOne)	/* internals */	.globl	GTEXT(semGive)		/* optimized semGive demultiplexer */	.globl	GTEXT(semTake)		/* optimized semTake demultiplexer */	.globl	GTEXT(semBGive)		/* optimized binary semaphore give */	.globl	GTEXT(semBTake)		/* optimized binary semaphore take */	.globl	GTEXT(semQGet)		/* semaphore queue get routine */	.globl	GTEXT(semQPut)		/* semaphore queue put routine */	.globl	GTEXT(semOTake)		/* optimized old semaphore take */	.globl	GTEXT(semClear)		/* optimized old semaphore semClear */	.globl	GTEXT(semEvRsrcSend)	.text	.balign 16/********************************************************************************* semGiveKern - add give routine to work queue**/semGiveKern:	jmp	FUNC(semGiveDefer)	/* let C rtn defer work and ret *//********************************************************************************* semGive - give a semaphore***STATUS semGive (semId)*    SEM_ID semId;		/* semaphore id to give **/	.balign 16, 0x90semGiveReturn:			/* This small block is before the semGive */	popfl			/* as the default branch for a conditional */ 	ret			/* jump is jump back. */	.balign 16,0x90FUNC_LABEL(semGive)	movl	SP_ARG1(%esp),%ecx	/* semId goes into %ecx */	testl	$1,%ecx			/* is it a global semId */	jne	semGiveGlobal		/* if LSB is 1, its a global sem */	xorl	%edx, %edx		/* Clear edx */#ifdef	WV_INSTRUMENTATION	/* 	 * windview instrumentation - BEGIN	 * semGive: object status class	 */	cmpl	FUNC(evtAction), %edx	/*  is WindView on? */	je	noSemGiveEvt        cmpl    $FUNC(semClass),(%ecx)	/* check validity */        je	objOkGive        cmpl	$FUNC(semInstClass),(%ecx) /* check validity */        jne     noSemGiveEvt		/* invalid semaphore */objOkGive:	movl	$ WV_CLASS_3_ON,%eax        andl    FUNC(wvEvtClass),%eax	/* is event collection on? */        cmpl    $ WV_CLASS_3_ON,%eax	/* is event collection on? */	jne	trgCheckSemGive	pushl	%eax	pushl	%ecx			/* semId */	pushl	%edx	/* is this semaphore object instrumented? */	movl	(%ecx),%eax		/* %ecx - semId */	cmpl	$0,SEM_INST_RTN(%eax)	/* event routine attached? */	je	trgNoSemGive	/* log event for this object */	pushl	%edx			/* $0 */	pushl	%edx			/* $0 */	movw	SEM_RECURSE(%ecx),%dx	/* recursively called */	pushl	%edx		movl	SEM_STATE(%ecx),%edx	/* state/count/owner */	pushl	%edx	pushl	%ecx			/* semId */	pushl	$ 3			/* number of paramters */	pushl	$ EVENT_SEMGIVE		/* EVENT_SEMGIVE, event id */	movl	SEM_INST_RTN(%eax),%edx	/* get logging routine */	call	*%edx			/* call routine */	addl	$28,%esptrgNoSemGive:	popl	%edx	popl	%ecx			/* semId */	popl	%eaxtrgCheckSemGive:	movl	$ TRG_CLASS_3,%eax     	orl 	$ TRG_ON,%eax        cmpl    FUNC(trgEvtClass),%eax	/* any trigger? */	jne	noSemGiveEvt        movl    FUNC(_func_trgCheck),%eax    /* triggering routine */        cmpl    %edx, %eax		/* Note: %edx = 0 */        je      noSemGiveEvt	pushl	%ecx			/* semId */	pushl	%edx        pushl   %edx			/* $0 */        pushl   %edx			/* $0 */	movw	SEM_RECURSE(%ecx),%dx	/* recursively called */	pushl	%edx		movl	SEM_STATE(%ecx),%edx	/* state/count/owner */	pushl	%edx	pushl	%ecx			/* semId */	pushl	%ecx			/* objId */        pushl   $ TRG_CLASS3_INDEX      /* TRG_CLASS3_INDEX */	pushl	$ EVENT_SEMGIVE		/* EVENT_SEMGIVE, event id */        call    *%eax                   /* call triggering routine */        addl    $32,%esp	popl	%edx	popl	%ecx			/* semId */noSemGiveEvt:	/* windview instrumentation - END */#endif  /* WV_INSTRUMENTATION */	movl	FUNC(kernelState),%eax	/* are we in kernel state? */	cmpl	%edx, %eax		/* %edx already 0 */	jne	semGiveKern		/* %eax = 0 if we are not */	movb	SEM_TYPE(%ecx),%dl	/* put the sem class into %edx */	andb	$ SEM_TYPE_MASK,%dl	/* mask %edx to MAX_SEM_TYPE value */	jne	semGiveNotBinary	/* optimize for BINARY if %edx == 0 */		/* 		 * BINARY SEMAPHORE OPTIMIZATION		 * assumptions are:		 *  - %ecx = semId (%ecx is a volatile register)		 */FUNC_LABEL(semBGive)		pushfl				/* save IF in EFLAGS */		cli				/* LOCK INTERRUPTS */		cmpl    $FUNC(semClass),(%ecx)	/* check validity */		/*		 * FIXME-PR: if this is going to be part of the kernel 		 *           permanently, it should be rearranged. It  		 *           does an extra instruction that is not needed.		 */#ifdef	WV_INSTRUMENTATION		je	objOkBGive		/* object is okay */		/* windview - check the validity of instrumented class */		cmpl    $FUNC(semInstClass),(%ecx) /* check validity */		jne	    semIsInvalidUnlock	/* semaphore id error */objOkBGive:#else		jne     semIsInvalidUnlock	/* invalid semaphore */#endif  /* WV_INSTRUMENTATION */		movl    SEM_Q_HEAD(%ecx),%eax		movl    SEM_STATE(%ecx), %edx	/* %edx = previous semOwner */		movl    %eax,SEM_STATE(%ecx)		testl   %eax, %eax		/* is new semOwner NULL? */		jne	    FUNC(semQGet)	/* if not empty, get from q */		cmpl    SEM_EVENTS_TASKID (%ecx), %eax		jz	    semGiveReturn	/* skip if taskId == NULL */		testl   %edx, %edx		/* is prev semOwner NULL? */		jnz     FUNC(semEvRsrcSend)	/* if not, jump */		popfl				/* UNLOCK INTERRUPTS */		ret				/* return OK */	.balign 16,0x90semGiveNotBinary:        /*	 * Call semGive indirectly via semGiveTbl.  Note that the index could	 * equal zero after it is masked.  semBGive is the zeroeth element	 * of the table, but for it to function correctly in the optimized	 * version above, we must be certain not to clobber %ecx.  Note, also	 * that old semaphores will also call semBGive above.	 */	movl	FUNC(semGiveTbl)(,%edx,4),%edx	jmp	*%edx			    /* invoke give rtn, it will ret */	.balign 16,0x90semGiveGlobal:	addl	FUNC(smObjPoolMinusOne),%ecx /* convert id to local addr */	movb	7(%ecx),%dl		    /* get semaphore type in %dl */				            /* offset 7 is used as the type					     * is stored in  network order					     */			andl	$ SEM_TYPE_MASK,%edx	    /* mask %edx to MAX_SEM_TYPE */	movl	FUNC(semGiveTbl)(,%edx,4),%edx /* %edx is the give rtn. */	pushl	%ecx			    /* push converted semId */	call	*%edx			    /* call appropriate give rtn. */	addl	$4,%esp			    /* clean up */	ret/********************************************************************************* semEvRsrcSend - send a semaphore event on semGive** This sub-routine is only executed if a semaphore state change has occurred,* and semId->events.taskId is not NULL.** INTERNAL* assumptions are:*  - %ecx = semId (%ecx is a volatile register)*  - %eax = 0*/	.balign	16, 0x90FUNC_LABEL(semEvRsrcSend)	movl	$1, FUNC(kernelState)	/* ENTER KERNEL */	popfl				/* UNLOCK INTERRUPTS */	movl	FUNC(errno), %eax	pushl	%esi			/* Save %esi */	pushl	%edi			/* Save %edi */	pushl	%ebx			/* Save %ebx */	pushl	%eax			/* Save errno */	movl	%ecx, %esi		/* %esi = semId */	/*	 * Both semId->events.options and semId->options are being pushed	 * onto the stack.  But where is semId->options?  SEM_TYPE is located	 * at offset 0x04, and SEM_OPTIONS is located at offset 0x05.  As the 	 * x86 series is little-endian, semId->options will be loaded into the	 * %bh portion of the %ebx register.  It should also be noted that both	 * semId->options and semId->events.options are a single byte.	 */	movl	SEM_EVENTS_OPTIONS (%ecx), %edi	/* Get semId->events.options */	movl	SEM_TYPE (%ecx), %ebx		/* Get semId->options */	movl	SEM_EVENTS_REGISTERED (%ecx), %edx	movl	SEM_EVENTS_TASKID (%ecx), %eax	pushl	%edx			/* semId->events.registered param */	pushl	%eax			/* semId->events.taskId param */	call	FUNC(eventRsrcSend)	/* eventRsrcSend (%eax, %edx) */	addl	$8, %esp		/* Remove params from stack */	/*	 * This next block does the C code	 * if ((evSendStatus != OK) && !(semOptions & EVENT_SEND_NOTIFY_ERROR))	 * Two tests can be condensed into one since ...	 * OK & x = 0, and ERROR & x = x	 * Thus (evSendStatus & semOptions & EVENT_SEND_NOTIFY_ERROR) works.	 * To avoid extra jumps (and flushing of the pipeline), the setXX	 * commands are used.	 */	movl	%eax, %edx		/* edx = %eax (backup) */	xorl	%ecx, %ecx		/* Clear <retStatus> */	andl	%ebx, %eax		/* %eax = {0, semOptions << 8} */	testl	$(SEM_EVENTSEND_ERR_NOTIFY << 8), %eax	setz	%cl			/* 1 if will return OK, 0 if ERROR */	/*	 * "if ((evtOptions & EVENTS_SEND_ONCE) || (evSendStatus != OK))"	 * combined into one test.  semId->events.taskId is cleared if the 	 * if-statement was TRUE.  No branching--cool.	 */	xorl	%eax, %eax		/* Clear %eax */	decl	%ecx			/* retStatus = {OK, ERROR} */	orl	%edi, %edx		/* Combine two tests into one */	incl	%eax			/* %eax  = $EVENTS_SEND_ONCE */	movl	$S_eventLib_EVENTSEND_FAILED, %edi	/* new errno */	andl	%edx, %eax		/* %eax = {1,0} */	popl	%ebx			/* old <errno> */	decl	%eax			/* %eax = {0x0, 0xffffffff} */	subl	%ebx, %edi		/* new <errno> - old <errno> */	andl	%eax, SEM_EVENTS_TASKID (%esi)	/* {0, unchanged} */	andl	%ecx, %edi		/* %edi = {0, new errno - old errno} */	movl	%ecx, %esi		/* Save <retStatus> */	addl	%ebx, %edi		/* %edi = {old errno, new errno} */	call	FUNC(windExit)		/* EXIT KERNEL */	movl	%edi, FUNC(errno)	/* Restore errno */	movl	%esi, %eax		/* Restore <retStatus> */	popl	%ebx			/* Restore %ebx */	popl	%edi			/* Restore %edi */	popl	%esi			/* Restore %esi */	ret/********************************************************************************* semIsInvalid - unlock interupts and call semInvalid ().*/	.balign 16,0x90semIsInvalidUnlock:	popfl				/* UNLOCK INTERRUPTS */semIsInvalid:	jmp	FUNC(semInvalid)	/* let C rtn do work and ret *//********************************************************************************* semTake - take a semaphore*

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久se精品一区精品二区| 麻豆国产精品一区二区三区| 国产精品乱人伦一区二区| 久久久久久久综合| 久久久久久久久久久99999| 欧美美女喷水视频| 日本道在线观看一区二区| 99国产精品久久久久久久久久 | 国产成人精品三级| 成人免费观看视频| www.亚洲免费av| 欧美电影在线免费观看| 日韩精品一区二区三区视频| 精品不卡在线视频| 国产精品麻豆视频| 日韩国产欧美在线播放| 国产精品1区二区.| 欧美肥大bbwbbw高潮| 国产欧美一区二区精品性色超碰| 综合欧美亚洲日本| 亚洲chinese男男1069| www.欧美亚洲| 日韩欧美www| 午夜欧美2019年伦理| 北岛玲一区二区三区四区| 日韩一级片网站| 亚洲国产日韩综合久久精品| 国模冰冰炮一区二区| 欧美日韩欧美一区二区| 国产精品国产三级国产aⅴ中文| 另类欧美日韩国产在线| 一本大道久久a久久精二百| 欧美高清精品3d| 亚洲国产综合91精品麻豆| 波多野结衣在线aⅴ中文字幕不卡| 日韩午夜激情电影| 日本视频一区二区三区| 欧日韩精品视频| 亚洲制服欧美中文字幕中文字幕| 成人av中文字幕| 一区免费观看视频| 99久久婷婷国产精品综合| 国产午夜亚洲精品理论片色戒| 久久精品av麻豆的观看方式| 91精品国产麻豆| 国产一区视频在线看| 久久久久久久免费视频了| 国产一区二区三区精品欧美日韩一区二区三区| 欧美欧美欧美欧美首页| 美女视频免费一区| 国产清纯在线一区二区www| aaa国产一区| 亚洲一区二区黄色| 精品国产sm最大网站| 国产不卡免费视频| 亚洲综合成人网| 久久久影院官网| 色av成人天堂桃色av| 免费在线观看不卡| 欧美韩国日本不卡| 欧美剧情电影在线观看完整版免费励志电影 | 久久色.com| 日本道精品一区二区三区| 蜜桃一区二区三区四区| 国产精品午夜电影| 日韩一区二区三区在线观看| 北条麻妃国产九九精品视频| 日本欧美一区二区在线观看| 国产精品美日韩| www国产成人| 91精品国产色综合久久不卡蜜臀 | 亚洲人精品一区| 久久久久国色av免费看影院| 欧美中文字幕久久| 国产成人啪午夜精品网站男同| 午夜精品久久久久久久蜜桃app| 日本一区二区三区在线观看| 精品伦理精品一区| 在线播放中文一区| 欧美精品国产精品| 欧美色涩在线第一页| 99精品视频在线观看| 成人app在线| 成人美女视频在线看| 不卡的av中国片| 成人亚洲一区二区一| 成人一级视频在线观看| jlzzjlzz国产精品久久| 不卡电影免费在线播放一区| 国产98色在线|日韩| eeuss影院一区二区三区| 97精品电影院| 91高清视频在线| 欧美系列亚洲系列| 日韩视频一区二区三区在线播放| 欧美猛男gaygay网站| 日韩午夜在线观看视频| 精品国产污污免费网站入口| 国产欧美中文在线| 伊人性伊人情综合网| 五月天亚洲精品| 精品一区二区日韩| 色婷婷激情综合| 欧美色综合网站| 精品国内二区三区| 一区二区三区四区蜜桃| 九九**精品视频免费播放| 波多野结衣一区二区三区| 欧美日韩aaa| 国产精品视频观看| 日韩国产高清影视| 色94色欧美sute亚洲13| 337p日本欧洲亚洲大胆精品| 亚洲在线观看免费视频| 国产成人免费在线| 日韩欧美一级在线播放| 一区二区三区四区蜜桃| 成人午夜电影久久影院| 欧美成人乱码一区二区三区| 午夜精品123| 在线免费不卡电影| 中文字幕一区二区在线播放| 国产精品资源网站| 精品国产乱码久久久久久久久| 性感美女久久精品| 欧美性受xxxx黑人xyx性爽| 欧美激情一区二区在线| 国产999精品久久| 久久久精品国产免费观看同学| 狠狠色丁香久久婷婷综合_中| 欧美老女人第四色| 奇米色一区二区三区四区| 日韩一区和二区| 久久成人免费电影| 久久精品欧美一区二区三区麻豆| 国产一区二区主播在线| 国产欧美一区二区三区网站| 国产.欧美.日韩| 亚洲小说春色综合另类电影| 欧美日韩综合在线| 久久99精品国产.久久久久| 欧美不卡一区二区三区四区| 精品一区二区三区不卡| 中文字幕一区二区在线观看 | 亚洲丝袜另类动漫二区| 色婷婷av久久久久久久| 亚洲成av人片| 亚洲精品一区二区三区精华液| 国产盗摄精品一区二区三区在线 | 丁香网亚洲国际| 一区二区久久久| 久久麻豆一区二区| 91视视频在线观看入口直接观看www | 热久久免费视频| 国产精品国产三级国产普通话三级| 99久久99久久精品免费看蜜桃| 亚洲一区二区av在线| 国产喂奶挤奶一区二区三区| 欧美日韩视频一区二区| 99久久精品一区| 九九视频精品免费| 午夜影院在线观看欧美| 最新日韩av在线| 久久久无码精品亚洲日韩按摩| 欧美性高清videossexo| 91丨九色丨国产丨porny| 激情六月婷婷久久| 天天综合色天天综合| 亚洲与欧洲av电影| 中文字幕欧美区| 精品日产卡一卡二卡麻豆| 欧美老肥妇做.爰bbww| 欧美日韩一区二区三区四区| 在线观看网站黄不卡| caoporn国产精品| 成人av在线一区二区三区| 国产福利91精品| 丁香天五香天堂综合| 国产福利精品一区二区| 成人免费视频caoporn| 成人精品小蝌蚪| 在线视频一区二区免费| 欧洲另类一二三四区| 777xxx欧美| 久久美女艺术照精彩视频福利播放| 久久久美女艺术照精彩视频福利播放| 日韩美女在线视频| 欧美韩国日本不卡| 亚洲色图色小说| 黄一区二区三区| 波波电影院一区二区三区| 欧洲一区在线观看| 欧美一卡二卡三卡| 国产精品黄色在线观看 | 94-欧美-setu| 91精品国产综合久久精品| 国产日韩欧美高清在线| 一区二区理论电影在线观看| 玖玖九九国产精品| 99v久久综合狠狠综合久久|