CombinedText
stringlengths
4
3.42M
-- -- Copyright (C) 2020, AdaCore -- -- This spec has been automatically generated from STM32F0x8.svd pragma Ada_2012; pragma Style_Checks (Off); with System; package Interfaces.STM32.RCC is pragma Preelaborate; pragma No_Elaboration_Code_All; --------------- -- Registers -- --------------- subtype CR_HSION_Field is Interfaces.STM32.Bit; subtype CR_HSIRDY_Field is Interfaces.STM32.Bit; subtype CR_HSITRIM_Field is Interfaces.STM32.UInt5; subtype CR_HSICAL_Field is Interfaces.STM32.Byte; subtype CR_HSEON_Field is Interfaces.STM32.Bit; subtype CR_HSERDY_Field is Interfaces.STM32.Bit; subtype CR_HSEBYP_Field is Interfaces.STM32.Bit; subtype CR_CSSON_Field is Interfaces.STM32.Bit; subtype CR_PLLON_Field is Interfaces.STM32.Bit; subtype CR_PLLRDY_Field is Interfaces.STM32.Bit; -- Clock control register type CR_Register is record -- Internal High Speed clock enable HSION : CR_HSION_Field := 16#1#; -- Read-only. Internal High Speed clock ready flag HSIRDY : CR_HSIRDY_Field := 16#1#; -- unspecified Reserved_2_2 : Interfaces.STM32.Bit := 16#0#; -- Internal High Speed clock trimming HSITRIM : CR_HSITRIM_Field := 16#10#; -- Read-only. Internal High Speed clock Calibration HSICAL : CR_HSICAL_Field := 16#0#; -- External High Speed clock enable HSEON : CR_HSEON_Field := 16#0#; -- Read-only. External High Speed clock ready flag HSERDY : CR_HSERDY_Field := 16#0#; -- External High Speed clock Bypass HSEBYP : CR_HSEBYP_Field := 16#0#; -- Clock Security System enable CSSON : CR_CSSON_Field := 16#0#; -- unspecified Reserved_20_23 : Interfaces.STM32.UInt4 := 16#0#; -- PLL enable PLLON : CR_PLLON_Field := 16#0#; -- Read-only. PLL clock ready flag PLLRDY : CR_PLLRDY_Field := 16#0#; -- unspecified Reserved_26_31 : Interfaces.STM32.UInt6 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for CR_Register use record HSION at 0 range 0 .. 0; HSIRDY at 0 range 1 .. 1; Reserved_2_2 at 0 range 2 .. 2; HSITRIM at 0 range 3 .. 7; HSICAL at 0 range 8 .. 15; HSEON at 0 range 16 .. 16; HSERDY at 0 range 17 .. 17; HSEBYP at 0 range 18 .. 18; CSSON at 0 range 19 .. 19; Reserved_20_23 at 0 range 20 .. 23; PLLON at 0 range 24 .. 24; PLLRDY at 0 range 25 .. 25; Reserved_26_31 at 0 range 26 .. 31; end record; subtype CFGR_SW_Field is Interfaces.STM32.UInt2; subtype CFGR_SWS_Field is Interfaces.STM32.UInt2; subtype CFGR_HPRE_Field is Interfaces.STM32.UInt4; subtype CFGR_PPRE_Field is Interfaces.STM32.UInt3; subtype CFGR_ADCPRE_Field is Interfaces.STM32.Bit; subtype CFGR_PLLSRC_Field is Interfaces.STM32.UInt2; subtype CFGR_PLLXTPRE_Field is Interfaces.STM32.Bit; subtype CFGR_PLLMUL_Field is Interfaces.STM32.UInt4; subtype CFGR_MCO_Field is Interfaces.STM32.UInt3; subtype CFGR_MCOPRE_Field is Interfaces.STM32.UInt3; subtype CFGR_PLLNODIV_Field is Interfaces.STM32.Bit; -- Clock configuration register (RCC_CFGR) type CFGR_Register is record -- System clock Switch SW : CFGR_SW_Field := 16#0#; -- Read-only. System Clock Switch Status SWS : CFGR_SWS_Field := 16#0#; -- AHB prescaler HPRE : CFGR_HPRE_Field := 16#0#; -- APB Low speed prescaler (APB1) PPRE : CFGR_PPRE_Field := 16#0#; -- unspecified Reserved_11_13 : Interfaces.STM32.UInt3 := 16#0#; -- ADC prescaler ADCPRE : CFGR_ADCPRE_Field := 16#0#; -- PLL input clock source PLLSRC : CFGR_PLLSRC_Field := 16#0#; -- HSE divider for PLL entry PLLXTPRE : CFGR_PLLXTPRE_Field := 16#0#; -- PLL Multiplication Factor PLLMUL : CFGR_PLLMUL_Field := 16#0#; -- unspecified Reserved_22_23 : Interfaces.STM32.UInt2 := 16#0#; -- Microcontroller clock output MCO : CFGR_MCO_Field := 16#0#; -- unspecified Reserved_27_27 : Interfaces.STM32.Bit := 16#0#; -- Microcontroller Clock Output Prescaler MCOPRE : CFGR_MCOPRE_Field := 16#0#; -- PLL clock not divided for MCO PLLNODIV : CFGR_PLLNODIV_Field := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for CFGR_Register use record SW at 0 range 0 .. 1; SWS at 0 range 2 .. 3; HPRE at 0 range 4 .. 7; PPRE at 0 range 8 .. 10; Reserved_11_13 at 0 range 11 .. 13; ADCPRE at 0 range 14 .. 14; PLLSRC at 0 range 15 .. 16; PLLXTPRE at 0 range 17 .. 17; PLLMUL at 0 range 18 .. 21; Reserved_22_23 at 0 range 22 .. 23; MCO at 0 range 24 .. 26; Reserved_27_27 at 0 range 27 .. 27; MCOPRE at 0 range 28 .. 30; PLLNODIV at 0 range 31 .. 31; end record; subtype CIR_LSIRDYF_Field is Interfaces.STM32.Bit; subtype CIR_LSERDYF_Field is Interfaces.STM32.Bit; subtype CIR_HSIRDYF_Field is Interfaces.STM32.Bit; subtype CIR_HSERDYF_Field is Interfaces.STM32.Bit; subtype CIR_PLLRDYF_Field is Interfaces.STM32.Bit; subtype CIR_HSI14RDYF_Field is Interfaces.STM32.Bit; subtype CIR_HSI48RDYF_Field is Interfaces.STM32.Bit; subtype CIR_CSSF_Field is Interfaces.STM32.Bit; subtype CIR_LSIRDYIE_Field is Interfaces.STM32.Bit; subtype CIR_LSERDYIE_Field is Interfaces.STM32.Bit; subtype CIR_HSIRDYIE_Field is Interfaces.STM32.Bit; subtype CIR_HSERDYIE_Field is Interfaces.STM32.Bit; subtype CIR_PLLRDYIE_Field is Interfaces.STM32.Bit; subtype CIR_HSI14RDYE_Field is Interfaces.STM32.Bit; subtype CIR_HSI48RDYIE_Field is Interfaces.STM32.Bit; subtype CIR_LSIRDYC_Field is Interfaces.STM32.Bit; subtype CIR_LSERDYC_Field is Interfaces.STM32.Bit; subtype CIR_HSIRDYC_Field is Interfaces.STM32.Bit; subtype CIR_HSERDYC_Field is Interfaces.STM32.Bit; subtype CIR_PLLRDYC_Field is Interfaces.STM32.Bit; subtype CIR_HSI14RDYC_Field is Interfaces.STM32.Bit; subtype CIR_HSI48RDYC_Field is Interfaces.STM32.Bit; subtype CIR_CSSC_Field is Interfaces.STM32.Bit; -- Clock interrupt register (RCC_CIR) type CIR_Register is record -- Read-only. LSI Ready Interrupt flag LSIRDYF : CIR_LSIRDYF_Field := 16#0#; -- Read-only. LSE Ready Interrupt flag LSERDYF : CIR_LSERDYF_Field := 16#0#; -- Read-only. HSI Ready Interrupt flag HSIRDYF : CIR_HSIRDYF_Field := 16#0#; -- Read-only. HSE Ready Interrupt flag HSERDYF : CIR_HSERDYF_Field := 16#0#; -- Read-only. PLL Ready Interrupt flag PLLRDYF : CIR_PLLRDYF_Field := 16#0#; -- Read-only. HSI14 ready interrupt flag HSI14RDYF : CIR_HSI14RDYF_Field := 16#0#; -- Read-only. HSI48 ready interrupt flag HSI48RDYF : CIR_HSI48RDYF_Field := 16#0#; -- Read-only. Clock Security System Interrupt flag CSSF : CIR_CSSF_Field := 16#0#; -- LSI Ready Interrupt Enable LSIRDYIE : CIR_LSIRDYIE_Field := 16#0#; -- LSE Ready Interrupt Enable LSERDYIE : CIR_LSERDYIE_Field := 16#0#; -- HSI Ready Interrupt Enable HSIRDYIE : CIR_HSIRDYIE_Field := 16#0#; -- HSE Ready Interrupt Enable HSERDYIE : CIR_HSERDYIE_Field := 16#0#; -- PLL Ready Interrupt Enable PLLRDYIE : CIR_PLLRDYIE_Field := 16#0#; -- HSI14 ready interrupt enable HSI14RDYE : CIR_HSI14RDYE_Field := 16#0#; -- HSI48 ready interrupt enable HSI48RDYIE : CIR_HSI48RDYIE_Field := 16#0#; -- unspecified Reserved_15_15 : Interfaces.STM32.Bit := 16#0#; -- Write-only. LSI Ready Interrupt Clear LSIRDYC : CIR_LSIRDYC_Field := 16#0#; -- Write-only. LSE Ready Interrupt Clear LSERDYC : CIR_LSERDYC_Field := 16#0#; -- Write-only. HSI Ready Interrupt Clear HSIRDYC : CIR_HSIRDYC_Field := 16#0#; -- Write-only. HSE Ready Interrupt Clear HSERDYC : CIR_HSERDYC_Field := 16#0#; -- Write-only. PLL Ready Interrupt Clear PLLRDYC : CIR_PLLRDYC_Field := 16#0#; -- Write-only. HSI 14 MHz Ready Interrupt Clear HSI14RDYC : CIR_HSI14RDYC_Field := 16#0#; -- Write-only. HSI48 Ready Interrupt Clear HSI48RDYC : CIR_HSI48RDYC_Field := 16#0#; -- Write-only. Clock security system interrupt clear CSSC : CIR_CSSC_Field := 16#0#; -- unspecified Reserved_24_31 : Interfaces.STM32.Byte := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for CIR_Register use record LSIRDYF at 0 range 0 .. 0; LSERDYF at 0 range 1 .. 1; HSIRDYF at 0 range 2 .. 2; HSERDYF at 0 range 3 .. 3; PLLRDYF at 0 range 4 .. 4; HSI14RDYF at 0 range 5 .. 5; HSI48RDYF at 0 range 6 .. 6; CSSF at 0 range 7 .. 7; LSIRDYIE at 0 range 8 .. 8; LSERDYIE at 0 range 9 .. 9; HSIRDYIE at 0 range 10 .. 10; HSERDYIE at 0 range 11 .. 11; PLLRDYIE at 0 range 12 .. 12; HSI14RDYE at 0 range 13 .. 13; HSI48RDYIE at 0 range 14 .. 14; Reserved_15_15 at 0 range 15 .. 15; LSIRDYC at 0 range 16 .. 16; LSERDYC at 0 range 17 .. 17; HSIRDYC at 0 range 18 .. 18; HSERDYC at 0 range 19 .. 19; PLLRDYC at 0 range 20 .. 20; HSI14RDYC at 0 range 21 .. 21; HSI48RDYC at 0 range 22 .. 22; CSSC at 0 range 23 .. 23; Reserved_24_31 at 0 range 24 .. 31; end record; subtype APB2RSTR_SYSCFGRST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_ADCRST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_TIM1RST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_SPI1RST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_USART1RST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_TIM15RST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_TIM16RST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_TIM17RST_Field is Interfaces.STM32.Bit; subtype APB2RSTR_DBGMCURST_Field is Interfaces.STM32.Bit; -- APB2 peripheral reset register (RCC_APB2RSTR) type APB2RSTR_Register is record -- SYSCFG and COMP reset SYSCFGRST : APB2RSTR_SYSCFGRST_Field := 16#0#; -- unspecified Reserved_1_8 : Interfaces.STM32.Byte := 16#0#; -- ADC interface reset ADCRST : APB2RSTR_ADCRST_Field := 16#0#; -- unspecified Reserved_10_10 : Interfaces.STM32.Bit := 16#0#; -- TIM1 timer reset TIM1RST : APB2RSTR_TIM1RST_Field := 16#0#; -- SPI 1 reset SPI1RST : APB2RSTR_SPI1RST_Field := 16#0#; -- unspecified Reserved_13_13 : Interfaces.STM32.Bit := 16#0#; -- USART1 reset USART1RST : APB2RSTR_USART1RST_Field := 16#0#; -- unspecified Reserved_15_15 : Interfaces.STM32.Bit := 16#0#; -- TIM15 timer reset TIM15RST : APB2RSTR_TIM15RST_Field := 16#0#; -- TIM16 timer reset TIM16RST : APB2RSTR_TIM16RST_Field := 16#0#; -- TIM17 timer reset TIM17RST : APB2RSTR_TIM17RST_Field := 16#0#; -- unspecified Reserved_19_21 : Interfaces.STM32.UInt3 := 16#0#; -- Debug MCU reset DBGMCURST : APB2RSTR_DBGMCURST_Field := 16#0#; -- unspecified Reserved_23_31 : Interfaces.STM32.UInt9 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for APB2RSTR_Register use record SYSCFGRST at 0 range 0 .. 0; Reserved_1_8 at 0 range 1 .. 8; ADCRST at 0 range 9 .. 9; Reserved_10_10 at 0 range 10 .. 10; TIM1RST at 0 range 11 .. 11; SPI1RST at 0 range 12 .. 12; Reserved_13_13 at 0 range 13 .. 13; USART1RST at 0 range 14 .. 14; Reserved_15_15 at 0 range 15 .. 15; TIM15RST at 0 range 16 .. 16; TIM16RST at 0 range 17 .. 17; TIM17RST at 0 range 18 .. 18; Reserved_19_21 at 0 range 19 .. 21; DBGMCURST at 0 range 22 .. 22; Reserved_23_31 at 0 range 23 .. 31; end record; subtype APB1RSTR_TIM2RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_TIM3RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_TIM6RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_TIM7RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_TIM14RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_WWDGRST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_SPI2RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_USART2RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_USART3RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_USART4RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_USART5RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_I2C1RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_I2C2RST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_USBRST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_CANRST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_CRSRST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_PWRRST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_DACRST_Field is Interfaces.STM32.Bit; subtype APB1RSTR_CECRST_Field is Interfaces.STM32.Bit; -- APB1 peripheral reset register (RCC_APB1RSTR) type APB1RSTR_Register is record -- Timer 2 reset TIM2RST : APB1RSTR_TIM2RST_Field := 16#0#; -- Timer 3 reset TIM3RST : APB1RSTR_TIM3RST_Field := 16#0#; -- unspecified Reserved_2_3 : Interfaces.STM32.UInt2 := 16#0#; -- Timer 6 reset TIM6RST : APB1RSTR_TIM6RST_Field := 16#0#; -- TIM7 timer reset TIM7RST : APB1RSTR_TIM7RST_Field := 16#0#; -- unspecified Reserved_6_7 : Interfaces.STM32.UInt2 := 16#0#; -- Timer 14 reset TIM14RST : APB1RSTR_TIM14RST_Field := 16#0#; -- unspecified Reserved_9_10 : Interfaces.STM32.UInt2 := 16#0#; -- Window watchdog reset WWDGRST : APB1RSTR_WWDGRST_Field := 16#0#; -- unspecified Reserved_12_13 : Interfaces.STM32.UInt2 := 16#0#; -- SPI2 reset SPI2RST : APB1RSTR_SPI2RST_Field := 16#0#; -- unspecified Reserved_15_16 : Interfaces.STM32.UInt2 := 16#0#; -- USART 2 reset USART2RST : APB1RSTR_USART2RST_Field := 16#0#; -- USART3 reset USART3RST : APB1RSTR_USART3RST_Field := 16#0#; -- USART4 reset USART4RST : APB1RSTR_USART4RST_Field := 16#0#; -- USART5 reset USART5RST : APB1RSTR_USART5RST_Field := 16#0#; -- I2C1 reset I2C1RST : APB1RSTR_I2C1RST_Field := 16#0#; -- I2C2 reset I2C2RST : APB1RSTR_I2C2RST_Field := 16#0#; -- USB interface reset USBRST : APB1RSTR_USBRST_Field := 16#0#; -- unspecified Reserved_24_24 : Interfaces.STM32.Bit := 16#0#; -- CAN interface reset CANRST : APB1RSTR_CANRST_Field := 16#0#; -- unspecified Reserved_26_26 : Interfaces.STM32.Bit := 16#0#; -- Clock Recovery System interface reset CRSRST : APB1RSTR_CRSRST_Field := 16#0#; -- Power interface reset PWRRST : APB1RSTR_PWRRST_Field := 16#0#; -- DAC interface reset DACRST : APB1RSTR_DACRST_Field := 16#0#; -- HDMI CEC reset CECRST : APB1RSTR_CECRST_Field := 16#0#; -- unspecified Reserved_31_31 : Interfaces.STM32.Bit := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for APB1RSTR_Register use record TIM2RST at 0 range 0 .. 0; TIM3RST at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; TIM6RST at 0 range 4 .. 4; TIM7RST at 0 range 5 .. 5; Reserved_6_7 at 0 range 6 .. 7; TIM14RST at 0 range 8 .. 8; Reserved_9_10 at 0 range 9 .. 10; WWDGRST at 0 range 11 .. 11; Reserved_12_13 at 0 range 12 .. 13; SPI2RST at 0 range 14 .. 14; Reserved_15_16 at 0 range 15 .. 16; USART2RST at 0 range 17 .. 17; USART3RST at 0 range 18 .. 18; USART4RST at 0 range 19 .. 19; USART5RST at 0 range 20 .. 20; I2C1RST at 0 range 21 .. 21; I2C2RST at 0 range 22 .. 22; USBRST at 0 range 23 .. 23; Reserved_24_24 at 0 range 24 .. 24; CANRST at 0 range 25 .. 25; Reserved_26_26 at 0 range 26 .. 26; CRSRST at 0 range 27 .. 27; PWRRST at 0 range 28 .. 28; DACRST at 0 range 29 .. 29; CECRST at 0 range 30 .. 30; Reserved_31_31 at 0 range 31 .. 31; end record; subtype AHBENR_DMA1EN_Field is Interfaces.STM32.Bit; subtype AHBENR_DMA2EN_Field is Interfaces.STM32.Bit; subtype AHBENR_SRAMEN_Field is Interfaces.STM32.Bit; subtype AHBENR_FLITFEN_Field is Interfaces.STM32.Bit; subtype AHBENR_CRCEN_Field is Interfaces.STM32.Bit; subtype AHBENR_IOPAEN_Field is Interfaces.STM32.Bit; subtype AHBENR_IOPBEN_Field is Interfaces.STM32.Bit; subtype AHBENR_IOPCEN_Field is Interfaces.STM32.Bit; subtype AHBENR_IOPDEN_Field is Interfaces.STM32.Bit; subtype AHBENR_IOPFEN_Field is Interfaces.STM32.Bit; subtype AHBENR_TSCEN_Field is Interfaces.STM32.Bit; -- AHB Peripheral Clock enable register (RCC_AHBENR) type AHBENR_Register is record -- DMA1 clock enable DMA1EN : AHBENR_DMA1EN_Field := 16#0#; -- DMA2 clock enable DMA2EN : AHBENR_DMA2EN_Field := 16#0#; -- SRAM interface clock enable SRAMEN : AHBENR_SRAMEN_Field := 16#1#; -- unspecified Reserved_3_3 : Interfaces.STM32.Bit := 16#0#; -- FLITF clock enable FLITFEN : AHBENR_FLITFEN_Field := 16#1#; -- unspecified Reserved_5_5 : Interfaces.STM32.Bit := 16#0#; -- CRC clock enable CRCEN : AHBENR_CRCEN_Field := 16#0#; -- unspecified Reserved_7_16 : Interfaces.STM32.UInt10 := 16#0#; -- I/O port A clock enable IOPAEN : AHBENR_IOPAEN_Field := 16#0#; -- I/O port B clock enable IOPBEN : AHBENR_IOPBEN_Field := 16#0#; -- I/O port C clock enable IOPCEN : AHBENR_IOPCEN_Field := 16#0#; -- I/O port D clock enable IOPDEN : AHBENR_IOPDEN_Field := 16#0#; -- unspecified Reserved_21_21 : Interfaces.STM32.Bit := 16#0#; -- I/O port F clock enable IOPFEN : AHBENR_IOPFEN_Field := 16#0#; -- unspecified Reserved_23_23 : Interfaces.STM32.Bit := 16#0#; -- Touch sensing controller clock enable TSCEN : AHBENR_TSCEN_Field := 16#0#; -- unspecified Reserved_25_31 : Interfaces.STM32.UInt7 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for AHBENR_Register use record DMA1EN at 0 range 0 .. 0; DMA2EN at 0 range 1 .. 1; SRAMEN at 0 range 2 .. 2; Reserved_3_3 at 0 range 3 .. 3; FLITFEN at 0 range 4 .. 4; Reserved_5_5 at 0 range 5 .. 5; CRCEN at 0 range 6 .. 6; Reserved_7_16 at 0 range 7 .. 16; IOPAEN at 0 range 17 .. 17; IOPBEN at 0 range 18 .. 18; IOPCEN at 0 range 19 .. 19; IOPDEN at 0 range 20 .. 20; Reserved_21_21 at 0 range 21 .. 21; IOPFEN at 0 range 22 .. 22; Reserved_23_23 at 0 range 23 .. 23; TSCEN at 0 range 24 .. 24; Reserved_25_31 at 0 range 25 .. 31; end record; subtype APB2ENR_SYSCFGEN_Field is Interfaces.STM32.Bit; subtype APB2ENR_ADCEN_Field is Interfaces.STM32.Bit; subtype APB2ENR_TIM1EN_Field is Interfaces.STM32.Bit; subtype APB2ENR_SPI1EN_Field is Interfaces.STM32.Bit; subtype APB2ENR_USART1EN_Field is Interfaces.STM32.Bit; subtype APB2ENR_TIM15EN_Field is Interfaces.STM32.Bit; subtype APB2ENR_TIM16EN_Field is Interfaces.STM32.Bit; subtype APB2ENR_TIM17EN_Field is Interfaces.STM32.Bit; subtype APB2ENR_DBGMCUEN_Field is Interfaces.STM32.Bit; -- APB2 peripheral clock enable register (RCC_APB2ENR) type APB2ENR_Register is record -- SYSCFG clock enable SYSCFGEN : APB2ENR_SYSCFGEN_Field := 16#0#; -- unspecified Reserved_1_8 : Interfaces.STM32.Byte := 16#0#; -- ADC 1 interface clock enable ADCEN : APB2ENR_ADCEN_Field := 16#0#; -- unspecified Reserved_10_10 : Interfaces.STM32.Bit := 16#0#; -- TIM1 Timer clock enable TIM1EN : APB2ENR_TIM1EN_Field := 16#0#; -- SPI 1 clock enable SPI1EN : APB2ENR_SPI1EN_Field := 16#0#; -- unspecified Reserved_13_13 : Interfaces.STM32.Bit := 16#0#; -- USART1 clock enable USART1EN : APB2ENR_USART1EN_Field := 16#0#; -- unspecified Reserved_15_15 : Interfaces.STM32.Bit := 16#0#; -- TIM15 timer clock enable TIM15EN : APB2ENR_TIM15EN_Field := 16#0#; -- TIM16 timer clock enable TIM16EN : APB2ENR_TIM16EN_Field := 16#0#; -- TIM17 timer clock enable TIM17EN : APB2ENR_TIM17EN_Field := 16#0#; -- unspecified Reserved_19_21 : Interfaces.STM32.UInt3 := 16#0#; -- MCU debug module clock enable DBGMCUEN : APB2ENR_DBGMCUEN_Field := 16#0#; -- unspecified Reserved_23_31 : Interfaces.STM32.UInt9 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for APB2ENR_Register use record SYSCFGEN at 0 range 0 .. 0; Reserved_1_8 at 0 range 1 .. 8; ADCEN at 0 range 9 .. 9; Reserved_10_10 at 0 range 10 .. 10; TIM1EN at 0 range 11 .. 11; SPI1EN at 0 range 12 .. 12; Reserved_13_13 at 0 range 13 .. 13; USART1EN at 0 range 14 .. 14; Reserved_15_15 at 0 range 15 .. 15; TIM15EN at 0 range 16 .. 16; TIM16EN at 0 range 17 .. 17; TIM17EN at 0 range 18 .. 18; Reserved_19_21 at 0 range 19 .. 21; DBGMCUEN at 0 range 22 .. 22; Reserved_23_31 at 0 range 23 .. 31; end record; subtype APB1ENR_TIM2EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_TIM3EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_TIM6EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_TIM7EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_TIM14EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_WWDGEN_Field is Interfaces.STM32.Bit; subtype APB1ENR_SPI2EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_USART2EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_USART3EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_USART4EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_USART5EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_I2C1EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_I2C2EN_Field is Interfaces.STM32.Bit; subtype APB1ENR_USBRST_Field is Interfaces.STM32.Bit; subtype APB1ENR_CANEN_Field is Interfaces.STM32.Bit; subtype APB1ENR_CRSEN_Field is Interfaces.STM32.Bit; subtype APB1ENR_PWREN_Field is Interfaces.STM32.Bit; subtype APB1ENR_DACEN_Field is Interfaces.STM32.Bit; subtype APB1ENR_CECEN_Field is Interfaces.STM32.Bit; -- APB1 peripheral clock enable register (RCC_APB1ENR) type APB1ENR_Register is record -- Timer 2 clock enable TIM2EN : APB1ENR_TIM2EN_Field := 16#0#; -- Timer 3 clock enable TIM3EN : APB1ENR_TIM3EN_Field := 16#0#; -- unspecified Reserved_2_3 : Interfaces.STM32.UInt2 := 16#0#; -- Timer 6 clock enable TIM6EN : APB1ENR_TIM6EN_Field := 16#0#; -- TIM7 timer clock enable TIM7EN : APB1ENR_TIM7EN_Field := 16#0#; -- unspecified Reserved_6_7 : Interfaces.STM32.UInt2 := 16#0#; -- Timer 14 clock enable TIM14EN : APB1ENR_TIM14EN_Field := 16#0#; -- unspecified Reserved_9_10 : Interfaces.STM32.UInt2 := 16#0#; -- Window watchdog clock enable WWDGEN : APB1ENR_WWDGEN_Field := 16#0#; -- unspecified Reserved_12_13 : Interfaces.STM32.UInt2 := 16#0#; -- SPI 2 clock enable SPI2EN : APB1ENR_SPI2EN_Field := 16#0#; -- unspecified Reserved_15_16 : Interfaces.STM32.UInt2 := 16#0#; -- USART 2 clock enable USART2EN : APB1ENR_USART2EN_Field := 16#0#; -- USART3 clock enable USART3EN : APB1ENR_USART3EN_Field := 16#0#; -- USART4 clock enable USART4EN : APB1ENR_USART4EN_Field := 16#0#; -- USART5 clock enable USART5EN : APB1ENR_USART5EN_Field := 16#0#; -- I2C 1 clock enable I2C1EN : APB1ENR_I2C1EN_Field := 16#0#; -- I2C 2 clock enable I2C2EN : APB1ENR_I2C2EN_Field := 16#0#; -- USB interface clock enable USBRST : APB1ENR_USBRST_Field := 16#0#; -- unspecified Reserved_24_24 : Interfaces.STM32.Bit := 16#0#; -- CAN interface clock enable CANEN : APB1ENR_CANEN_Field := 16#0#; -- unspecified Reserved_26_26 : Interfaces.STM32.Bit := 16#0#; -- Clock Recovery System interface clock enable CRSEN : APB1ENR_CRSEN_Field := 16#0#; -- Power interface clock enable PWREN : APB1ENR_PWREN_Field := 16#0#; -- DAC interface clock enable DACEN : APB1ENR_DACEN_Field := 16#0#; -- HDMI CEC interface clock enable CECEN : APB1ENR_CECEN_Field := 16#0#; -- unspecified Reserved_31_31 : Interfaces.STM32.Bit := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for APB1ENR_Register use record TIM2EN at 0 range 0 .. 0; TIM3EN at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; TIM6EN at 0 range 4 .. 4; TIM7EN at 0 range 5 .. 5; Reserved_6_7 at 0 range 6 .. 7; TIM14EN at 0 range 8 .. 8; Reserved_9_10 at 0 range 9 .. 10; WWDGEN at 0 range 11 .. 11; Reserved_12_13 at 0 range 12 .. 13; SPI2EN at 0 range 14 .. 14; Reserved_15_16 at 0 range 15 .. 16; USART2EN at 0 range 17 .. 17; USART3EN at 0 range 18 .. 18; USART4EN at 0 range 19 .. 19; USART5EN at 0 range 20 .. 20; I2C1EN at 0 range 21 .. 21; I2C2EN at 0 range 22 .. 22; USBRST at 0 range 23 .. 23; Reserved_24_24 at 0 range 24 .. 24; CANEN at 0 range 25 .. 25; Reserved_26_26 at 0 range 26 .. 26; CRSEN at 0 range 27 .. 27; PWREN at 0 range 28 .. 28; DACEN at 0 range 29 .. 29; CECEN at 0 range 30 .. 30; Reserved_31_31 at 0 range 31 .. 31; end record; subtype BDCR_LSEON_Field is Interfaces.STM32.Bit; subtype BDCR_LSERDY_Field is Interfaces.STM32.Bit; subtype BDCR_LSEBYP_Field is Interfaces.STM32.Bit; subtype BDCR_LSEDRV_Field is Interfaces.STM32.UInt2; subtype BDCR_RTCSEL_Field is Interfaces.STM32.UInt2; subtype BDCR_RTCEN_Field is Interfaces.STM32.Bit; subtype BDCR_BDRST_Field is Interfaces.STM32.Bit; -- Backup domain control register (RCC_BDCR) type BDCR_Register is record -- External Low Speed oscillator enable LSEON : BDCR_LSEON_Field := 16#0#; -- Read-only. External Low Speed oscillator ready LSERDY : BDCR_LSERDY_Field := 16#0#; -- External Low Speed oscillator bypass LSEBYP : BDCR_LSEBYP_Field := 16#0#; -- LSE oscillator drive capability LSEDRV : BDCR_LSEDRV_Field := 16#0#; -- unspecified Reserved_5_7 : Interfaces.STM32.UInt3 := 16#0#; -- RTC clock source selection RTCSEL : BDCR_RTCSEL_Field := 16#0#; -- unspecified Reserved_10_14 : Interfaces.STM32.UInt5 := 16#0#; -- RTC clock enable RTCEN : BDCR_RTCEN_Field := 16#0#; -- Backup domain software reset BDRST : BDCR_BDRST_Field := 16#0#; -- unspecified Reserved_17_31 : Interfaces.STM32.UInt15 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for BDCR_Register use record LSEON at 0 range 0 .. 0; LSERDY at 0 range 1 .. 1; LSEBYP at 0 range 2 .. 2; LSEDRV at 0 range 3 .. 4; Reserved_5_7 at 0 range 5 .. 7; RTCSEL at 0 range 8 .. 9; Reserved_10_14 at 0 range 10 .. 14; RTCEN at 0 range 15 .. 15; BDRST at 0 range 16 .. 16; Reserved_17_31 at 0 range 17 .. 31; end record; subtype CSR_LSION_Field is Interfaces.STM32.Bit; subtype CSR_LSIRDY_Field is Interfaces.STM32.Bit; subtype CSR_RMVF_Field is Interfaces.STM32.Bit; subtype CSR_OBLRSTF_Field is Interfaces.STM32.Bit; subtype CSR_PINRSTF_Field is Interfaces.STM32.Bit; subtype CSR_PORRSTF_Field is Interfaces.STM32.Bit; subtype CSR_SFTRSTF_Field is Interfaces.STM32.Bit; subtype CSR_IWDGRSTF_Field is Interfaces.STM32.Bit; subtype CSR_WWDGRSTF_Field is Interfaces.STM32.Bit; subtype CSR_LPWRRSTF_Field is Interfaces.STM32.Bit; -- Control/status register (RCC_CSR) type CSR_Register is record -- Internal low speed oscillator enable LSION : CSR_LSION_Field := 16#0#; -- Read-only. Internal low speed oscillator ready LSIRDY : CSR_LSIRDY_Field := 16#0#; -- unspecified Reserved_2_23 : Interfaces.STM32.UInt22 := 16#0#; -- Remove reset flag RMVF : CSR_RMVF_Field := 16#0#; -- Option byte loader reset flag OBLRSTF : CSR_OBLRSTF_Field := 16#0#; -- PIN reset flag PINRSTF : CSR_PINRSTF_Field := 16#1#; -- POR/PDR reset flag PORRSTF : CSR_PORRSTF_Field := 16#1#; -- Software reset flag SFTRSTF : CSR_SFTRSTF_Field := 16#0#; -- Independent watchdog reset flag IWDGRSTF : CSR_IWDGRSTF_Field := 16#0#; -- Window watchdog reset flag WWDGRSTF : CSR_WWDGRSTF_Field := 16#0#; -- Low-power reset flag LPWRRSTF : CSR_LPWRRSTF_Field := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for CSR_Register use record LSION at 0 range 0 .. 0; LSIRDY at 0 range 1 .. 1; Reserved_2_23 at 0 range 2 .. 23; RMVF at 0 range 24 .. 24; OBLRSTF at 0 range 25 .. 25; PINRSTF at 0 range 26 .. 26; PORRSTF at 0 range 27 .. 27; SFTRSTF at 0 range 28 .. 28; IWDGRSTF at 0 range 29 .. 29; WWDGRSTF at 0 range 30 .. 30; LPWRRSTF at 0 range 31 .. 31; end record; subtype AHBRSTR_IOPARST_Field is Interfaces.STM32.Bit; subtype AHBRSTR_IOPBRST_Field is Interfaces.STM32.Bit; subtype AHBRSTR_IOPCRST_Field is Interfaces.STM32.Bit; subtype AHBRSTR_IOPDRST_Field is Interfaces.STM32.Bit; subtype AHBRSTR_IOPFRST_Field is Interfaces.STM32.Bit; subtype AHBRSTR_TSCRST_Field is Interfaces.STM32.Bit; -- AHB peripheral reset register type AHBRSTR_Register is record -- unspecified Reserved_0_16 : Interfaces.STM32.UInt17 := 16#0#; -- I/O port A reset IOPARST : AHBRSTR_IOPARST_Field := 16#0#; -- I/O port B reset IOPBRST : AHBRSTR_IOPBRST_Field := 16#0#; -- I/O port C reset IOPCRST : AHBRSTR_IOPCRST_Field := 16#0#; -- I/O port D reset IOPDRST : AHBRSTR_IOPDRST_Field := 16#0#; -- unspecified Reserved_21_21 : Interfaces.STM32.Bit := 16#0#; -- I/O port F reset IOPFRST : AHBRSTR_IOPFRST_Field := 16#0#; -- unspecified Reserved_23_23 : Interfaces.STM32.Bit := 16#0#; -- Touch sensing controller reset TSCRST : AHBRSTR_TSCRST_Field := 16#0#; -- unspecified Reserved_25_31 : Interfaces.STM32.UInt7 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for AHBRSTR_Register use record Reserved_0_16 at 0 range 0 .. 16; IOPARST at 0 range 17 .. 17; IOPBRST at 0 range 18 .. 18; IOPCRST at 0 range 19 .. 19; IOPDRST at 0 range 20 .. 20; Reserved_21_21 at 0 range 21 .. 21; IOPFRST at 0 range 22 .. 22; Reserved_23_23 at 0 range 23 .. 23; TSCRST at 0 range 24 .. 24; Reserved_25_31 at 0 range 25 .. 31; end record; subtype CFGR2_PREDIV_Field is Interfaces.STM32.UInt4; -- Clock configuration register 2 type CFGR2_Register is record -- PREDIV division factor PREDIV : CFGR2_PREDIV_Field := 16#0#; -- unspecified Reserved_4_31 : Interfaces.STM32.UInt28 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for CFGR2_Register use record PREDIV at 0 range 0 .. 3; Reserved_4_31 at 0 range 4 .. 31; end record; subtype CFGR3_USART1SW_Field is Interfaces.STM32.UInt2; subtype CFGR3_I2C1SW_Field is Interfaces.STM32.Bit; subtype CFGR3_CECSW_Field is Interfaces.STM32.Bit; subtype CFGR3_USBSW_Field is Interfaces.STM32.Bit; subtype CFGR3_ADCSW_Field is Interfaces.STM32.Bit; subtype CFGR3_USART2SW_Field is Interfaces.STM32.UInt2; -- Clock configuration register 3 type CFGR3_Register is record -- USART1 clock source selection USART1SW : CFGR3_USART1SW_Field := 16#0#; -- unspecified Reserved_2_3 : Interfaces.STM32.UInt2 := 16#0#; -- I2C1 clock source selection I2C1SW : CFGR3_I2C1SW_Field := 16#0#; -- unspecified Reserved_5_5 : Interfaces.STM32.Bit := 16#0#; -- HDMI CEC clock source selection CECSW : CFGR3_CECSW_Field := 16#0#; -- USB clock source selection USBSW : CFGR3_USBSW_Field := 16#0#; -- ADC clock source selection ADCSW : CFGR3_ADCSW_Field := 16#0#; -- unspecified Reserved_9_15 : Interfaces.STM32.UInt7 := 16#0#; -- USART2 clock source selection USART2SW : CFGR3_USART2SW_Field := 16#0#; -- unspecified Reserved_18_31 : Interfaces.STM32.UInt14 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for CFGR3_Register use record USART1SW at 0 range 0 .. 1; Reserved_2_3 at 0 range 2 .. 3; I2C1SW at 0 range 4 .. 4; Reserved_5_5 at 0 range 5 .. 5; CECSW at 0 range 6 .. 6; USBSW at 0 range 7 .. 7; ADCSW at 0 range 8 .. 8; Reserved_9_15 at 0 range 9 .. 15; USART2SW at 0 range 16 .. 17; Reserved_18_31 at 0 range 18 .. 31; end record; subtype CR2_HSI14ON_Field is Interfaces.STM32.Bit; subtype CR2_HSI14RDY_Field is Interfaces.STM32.Bit; subtype CR2_HSI14DIS_Field is Interfaces.STM32.Bit; subtype CR2_HSI14TRIM_Field is Interfaces.STM32.UInt5; subtype CR2_HSI14CAL_Field is Interfaces.STM32.Byte; subtype CR2_HSI48ON_Field is Interfaces.STM32.Bit; subtype CR2_HSI48RDY_Field is Interfaces.STM32.Bit; subtype CR2_HSI48CAL_Field is Interfaces.STM32.Bit; -- Clock control register 2 type CR2_Register is record -- HSI14 clock enable HSI14ON : CR2_HSI14ON_Field := 16#0#; -- Read-only. HR14 clock ready flag HSI14RDY : CR2_HSI14RDY_Field := 16#0#; -- HSI14 clock request from ADC disable HSI14DIS : CR2_HSI14DIS_Field := 16#0#; -- HSI14 clock trimming HSI14TRIM : CR2_HSI14TRIM_Field := 16#10#; -- Read-only. HSI14 clock calibration HSI14CAL : CR2_HSI14CAL_Field := 16#0#; -- HSI48 clock enable HSI48ON : CR2_HSI48ON_Field := 16#0#; -- Read-only. HSI48 clock ready flag HSI48RDY : CR2_HSI48RDY_Field := 16#0#; -- unspecified Reserved_18_23 : Interfaces.STM32.UInt6 := 16#0#; -- Read-only. HSI48 factory clock calibration HSI48CAL : CR2_HSI48CAL_Field := 16#0#; -- unspecified Reserved_25_31 : Interfaces.STM32.UInt7 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for CR2_Register use record HSI14ON at 0 range 0 .. 0; HSI14RDY at 0 range 1 .. 1; HSI14DIS at 0 range 2 .. 2; HSI14TRIM at 0 range 3 .. 7; HSI14CAL at 0 range 8 .. 15; HSI48ON at 0 range 16 .. 16; HSI48RDY at 0 range 17 .. 17; Reserved_18_23 at 0 range 18 .. 23; HSI48CAL at 0 range 24 .. 24; Reserved_25_31 at 0 range 25 .. 31; end record; ----------------- -- Peripherals -- ----------------- -- Reset and clock control type RCC_Peripheral is record -- Clock control register CR : aliased CR_Register; -- Clock configuration register (RCC_CFGR) CFGR : aliased CFGR_Register; -- Clock interrupt register (RCC_CIR) CIR : aliased CIR_Register; -- APB2 peripheral reset register (RCC_APB2RSTR) APB2RSTR : aliased APB2RSTR_Register; -- APB1 peripheral reset register (RCC_APB1RSTR) APB1RSTR : aliased APB1RSTR_Register; -- AHB Peripheral Clock enable register (RCC_AHBENR) AHBENR : aliased AHBENR_Register; -- APB2 peripheral clock enable register (RCC_APB2ENR) APB2ENR : aliased APB2ENR_Register; -- APB1 peripheral clock enable register (RCC_APB1ENR) APB1ENR : aliased APB1ENR_Register; -- Backup domain control register (RCC_BDCR) BDCR : aliased BDCR_Register; -- Control/status register (RCC_CSR) CSR : aliased CSR_Register; -- AHB peripheral reset register AHBRSTR : aliased AHBRSTR_Register; -- Clock configuration register 2 CFGR2 : aliased CFGR2_Register; -- Clock configuration register 3 CFGR3 : aliased CFGR3_Register; -- Clock control register 2 CR2 : aliased CR2_Register; end record with Volatile; for RCC_Peripheral use record CR at 16#0# range 0 .. 31; CFGR at 16#4# range 0 .. 31; CIR at 16#8# range 0 .. 31; APB2RSTR at 16#C# range 0 .. 31; APB1RSTR at 16#10# range 0 .. 31; AHBENR at 16#14# range 0 .. 31; APB2ENR at 16#18# range 0 .. 31; APB1ENR at 16#1C# range 0 .. 31; BDCR at 16#20# range 0 .. 31; CSR at 16#24# range 0 .. 31; AHBRSTR at 16#28# range 0 .. 31; CFGR2 at 16#2C# range 0 .. 31; CFGR3 at 16#30# range 0 .. 31; CR2 at 16#34# range 0 .. 31; end record; -- Reset and clock control RCC_Periph : aliased RCC_Peripheral with Import, Address => RCC_Base; end Interfaces.STM32.RCC;
with Ada.Text_IO; use Ada.Text_IO; procedure Greet_No_Op is begin for I in reverse 5 .. 1 loop Put_Line ("Hello, World!" & Integer'Image (I)); end loop; end Greet_No_Op;
with Ada.Real_Time; use Ada.Real_Time; use type Ada.Real_Time.Time_Span; package tools is Big_Bang : constant Ada.Real_Time.Time := Clock; procedure Current_Time (Origen : Ada.Real_Time.Time); procedure Print_an_Integer (x: in integer); procedure Print_a_Float (x : in float); procedure Starting_Notice (T: in String); procedure Finishing_Notice (T: in String); procedure Execution_Time (Time : Ada.Real_Time.Time_Span); end tools;
----------------------------------------------------------------------- -- net-dhcp -- DHCP client -- Copyright (C) 2016, 2017, 2018 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Ada.Real_Time; with Net.Interfaces; with Net.Buffers; with Net.Sockets.Udp; -- == DHCP Client == -- The DHCP client can be used to configure the IPv4 network stack by using -- the DHCP protocol (RFC 2131). The DHCP client uses a UDP socket on port 68 -- to send and receive DHCP messages. The DHCP client state is maintained by -- two procedures which are called asynchronously: the <tt>Process</tt> -- and <tt>Receive</tt> procedures. The <tt>Process</tt> procedure is responsible -- for sending requests to the DHCP server and to manage the timeouts used for -- the retransmissions, renewal and lease expiration. On its hand, the <tt>Receive</tt> -- procedure is called by the UDP socket layer when a DHCP packet is received. -- These two procedures are typically called from different tasks. -- -- To make the implementation simple and ready to use, the DHCP client uses a pre-defined -- configuration that should meet most requirements. The DHCP client asks for the following -- DHCP options: -- -- * Option 1: Subnetmask -- * Option 3: Router -- * Option 6: Domain name server -- * Option 12: Hostname -- * Option 15: Domain name -- * Option 26: Interface MTU size -- * Option 28: Brodcast address -- * Option 42: NTP server -- * Option 72: WWW server -- * Option 51: Lease time -- * Option 58: Renew time -- * Option 59: Rebind time -- -- It sends the following options to help the server identify the client: -- -- * Option 60: Vendor class identifier, the string "Ada Embedded Network" is sent. -- * Option 61: Client identifier, the Ethernet address is used as identifier. -- -- === Initialization === -- To use the client, one will have to declare a global aliased DHCP client instance -- (the aliased is necessary as the UDP socket layer needs to get an access to it): -- -- C : aliased Net.DHCP.Client; -- -- The DHCP client instance must then be initialized after the network interface -- is initialized. The <tt>Initialize</tt> procedure needs an access to the interface -- instance. -- -- C.Initialize (Ifnet'Access); -- -- The initialization only binds the UDP socket to the port 68 and prepares the DHCP -- state machine. At this stage, no DHCP packet is sent yet but the UDP socket is now -- able to receive them. -- -- === Processing === -- The <tt>Process</tt> procedure must be called either by a main task or by a dedicated -- task to send the DHCP requests and maintain the DHCP state machine. Each time this -- procedure is called, it looks whether some DHCP processing must be done and it computes -- a deadline that indicates the time for the next call. It is safe -- to call the <tt>Process</tt> procedure more often than required. The operation will -- perform different operations depending on the DHCP state: -- -- In the <tt>STATE_INIT</tt> state, it records the begining of the DHCP discovering state, -- switches to the <tt>STATE_SELECTING</tt> and sends the first DHCP discover packet. -- -- When the DHCP state machine is in the <tt>STATE_SELECTING</tt> state, it continues to -- send the DHCP discover packet taking into account the backoff timeout. -- -- In the <tt>STATE_REQUESTING</tt> state, it sends the DHCP request packet to the server. -- -- In the <tt>STATE_BOUND</tt> state, it configures the interface if it is not yet configured -- and it then waits for the DHCP lease renewal. If the DHCP lease must be renewed, it -- switches to the <tt>STATE_RENEWING</tt> state. -- -- [images/ada-net-dhcp.png] -- -- The DHCP client does not use any task to give you the freedom on how you want to integrate -- the DHCP client in your application. The <tt>Process</tt> procedure may be integrated in -- a loop similar to the loop below: -- -- declare -- Dhcp_Deadline : Ada.Real_Time.Time; -- begin -- loop -- C.Process (Dhcp_Deadline); -- delay until Dhcp_Deadline; -- end loop; -- end; -- -- This loop may be part of a dedicated task for the DHCP client but it may also be part -- of another task that could also handle other network house keeping (such as ARP management). -- -- === Interface Configuration === -- Once in the <tt>STATE_BOUND</tt>, the interface configuration is done by the <tt>Process</tt> -- procedure that calls the <tt>Bind</tt> procedure with the DHCP received options. -- This procedure configures the interface IP, netmask, gateway, MTU and DNS. It is possible -- to override this procedure in an application to be notified and extract other information -- from the received DHCP options. In that case, it is still important to call the overriden -- procedure so that the interface and network stack is correctly configured. -- package Net.DHCP is -- The <tt>State_Type</tt> defines the DHCP client finite state machine. type State_Type is (STATE_INIT, STATE_INIT_REBOOT, STATE_SELECTING, STATE_REQUESTING, STATE_DAD, STATE_BOUND, STATE_RENEWING, STATE_REBINDING, STATE_REBOOTING); -- Options extracted from the server response. type Options_Type is record Msg_Type : Net.Uint8; Hostname : String (1 .. 255); Hostname_Len : Natural := 0; Domain : String (1 .. 255); Domain_Len : Natural := 0; Ip : Net.Ip_Addr := (0, 0, 0, 0); Broadcast : Net.Ip_Addr := (255, 255, 255, 255); Router : Net.Ip_Addr := (0, 0, 0, 0); Netmask : Net.Ip_Addr := (255, 255, 255, 0); Server : Net.Ip_Addr := (0, 0, 0, 0); Ntp : Net.Ip_Addr := (0, 0, 0, 0); Www : Net.Ip_Addr := (0, 0, 0, 0); Dns1 : Net.Ip_Addr := (0, 0, 0, 0); Dns2 : Net.Ip_Addr := (0, 0, 0, 0); Lease_Time : Natural := 0; Renew_Time : Natural := 0; Rebind_Time : Natural := 0; Mtu : Ip_Length := 1500; end record; type Client is new Net.Sockets.Udp.Raw_Socket with private; -- Get the current DHCP client state. function Get_State (Request : in Client) return State_Type; -- Get the DHCP options that were configured during the bind process. function Get_Config (Request : in Client) return Options_Type; -- Initialize the DHCP request. procedure Initialize (Request : in out Client; Ifnet : access Net.Interfaces.Ifnet_Type'Class); -- Process the DHCP client. Depending on the DHCP state machine, proceed to the -- discover, request, renew, rebind operations. Return in <tt>Next_Call</tt> the -- deadline time before the next call. procedure Process (Request : in out Client; Next_Call : out Ada.Real_Time.Time); -- Send the DHCP discover packet to initiate the DHCP discovery process. procedure Discover (Request : in out Client) with Pre => Request.Get_State = STATE_SELECTING; -- Send the DHCP request packet after we received an offer. procedure Request (Request : in out Client) with Pre => Request.Get_State = STATE_REQUESTING; -- Check for duplicate address on the network. If we find someone else using -- the IP, send a DHCPDECLINE to the server. At the end of the DAD process, -- switch to the STATE_BOUND state. procedure Check_Address (Request : in out Client); -- Configure the IP stack and the interface after the DHCP ACK is received. -- The interface is configured to use the IP address, the ARP cache is flushed -- so that the duplicate address check can be made. procedure Configure (Request : in out Client; Ifnet : in out Net.Interfaces.Ifnet_Type'Class; Config : in Options_Type) with Pre => Request.Get_State in STATE_DAD | STATE_RENEWING | STATE_REBINDING, Post => Request.Get_State in STATE_DAD | STATE_RENEWING | STATE_REBINDING; -- Bind the interface with the DHCP configuration that was recieved by the DHCP ACK. -- This operation is called by the <tt>Process</tt> procedure when the BOUND state -- is entered. It can be overriden to perform specific actions. procedure Bind (Request : in out Client; Ifnet : in out Net.Interfaces.Ifnet_Type'Class; Config : in Options_Type) with Pre => Request.Get_State = STATE_BOUND; -- Send the DHCPDECLINE message to notify the DHCP server that we refuse the IP -- because the DAD discovered that the address is used. procedure Decline (Request : in out Client) with Pre => Request.Get_State = STATE_DAD, Post => Request.Get_State = STATE_INIT; -- Send the DHCPREQUEST in unicast to the DHCP server to renew the DHCP lease. procedure Renew (Request : in out Client) with Pre => Request.Get_State = STATE_RENEWING; -- Fill the DHCP options in the request. procedure Fill_Options (Request : in Client; Packet : in out Net.Buffers.Buffer_Type; Kind : in Net.Uint8; Mac : in Net.Ether_Addr); -- Receive the DHCP offer/ack/nak from the DHCP server and update the DHCP state machine. -- It only updates the DHCP state machine (the DHCP request are only sent by -- <tt>Process</tt>). overriding procedure Receive (Request : in out Client; From : in Net.Sockets.Sockaddr_In; Packet : in out Net.Buffers.Buffer_Type); -- Extract the DHCP options from the DHCP packet. procedure Extract_Options (Packet : in out Net.Buffers.Buffer_Type; Options : out Options_Type); -- Update the UDP header for the packet and send it. overriding procedure Send (Request : in out Client; Packet : in out Net.Buffers.Buffer_Type) with Pre => not Packet.Is_Null, Post => Packet.Is_Null; private -- Compute the next timeout according to the DHCP state. procedure Next_Timeout (Request : in out Client); type Retry_Type is new Net.Uint8 range 0 .. 5; type Backoff_Array is array (Retry_Type) of Integer; -- Timeout table used for the DHCP backoff algorithm during for DHCP DISCOVER. Backoff : constant Backoff_Array := (0, 4, 8, 16, 32, 64); -- Wait 30 seconds before starting again a DHCP discovery process after a NAK/DECLINE. DEFAULT_PAUSE_DELAY : constant Natural := 30; -- The DHCP state machine is accessed by the <tt>Process</tt> procedure to proceed to -- the DHCP discovery and re-new process. In parallel, the <tt>Receive</tt> procedure -- handles the DHCP packets received by the DHCP server and it changes the state according -- to the received packet. protected type Machine is -- Get the current state. function Get_State return State_Type; -- Set the new DHCP state. procedure Set_State (New_State : in State_Type); -- Set the DHCP options and the DHCP state to the STATE_BOUND. procedure Bind (Options : in Options_Type); -- Get the DHCP options that were configured during the bind process. function Get_Config return Options_Type; private State : State_Type := STATE_INIT; Config : Options_Type; end Machine; type Client is new Net.Sockets.Udp.Raw_Socket with record Ifnet : access Net.Interfaces.Ifnet_Type'Class; State : Machine; Current : State_Type := STATE_INIT; Mac : Net.Ether_Addr := (others => 0); Timeout : Ada.Real_Time.Time; Start_Time : Ada.Real_Time.Time; Renew_Time : Ada.Real_Time.Time; Rebind_Time : Ada.Real_Time.Time; Expire_Time : Ada.Real_Time.Time; Pause_Delay : Natural := DEFAULT_PAUSE_DELAY; Xid : Net.Uint32; Secs : Net.Uint16 := 0; Ip : Net.Ip_Addr := (others => 0); Server_Ip : Net.Ip_Addr := (others => 0); Retry : Retry_Type := 0; Configured : Boolean := False; end record; end Net.DHCP;
with NCurses; use NCurses; package body Board is procedure Set_Variables(Channel : Stream_Access) is begin Board_Type'Output(Channel, Our_Board); Player_Counter'Output(Channel, Turn); King_Status_Array'Output(Channel, King_Status); Cordinate_Type'Output(Channel, Last_Moved); end Set_Variables; procedure Get_Variables(Channel : Stream_Access) is begin Our_Board := Board_Type'Input(Channel); Turn := Player_Counter'Input(Channel); King_Status := King_Status_Array'Input(Channel); Last_Moved := Cordinate_Type'Input(Channel); end Get_Variables; procedure Reset_Board is begin -- Reset_Board for I of Our_Board loop I := (others=>Empty_Piece); end loop; for I of Our_Board(Position'First + 1) loop I := Player_1_Pawn; end loop; Our_Board(Position'First) := Starting_Backrow_Order(1); for I of Our_Board(Position'Last - 1) loop I := Player_2_Pawn; end loop; Our_Board(Position'Last) := Starting_Backrow_Order(2); King_Status(0) := (X=>3, Y=>0); King_Status(1) := (X=>3, Y=>7); Last_Moved := (0, 0); end Reset_Board; procedure Print_Board is Small_String : String(1..6); begin -- Print_Board Clear; Attribute_On(1); Pretty_Print_Line_Window(Owner_Type'Image(Owner_Type'Val(Turn))); for I in reverse Our_Board'Range loop Pretty_Print_Line_Window(" -------------------------------------------------------------------------"); Pretty_Print_Line_Window(" | | | | | | | | | "); Pretty_Print_Window(Integer'Image(Integer(I) + 1) & " | "); for J of Our_Board(I) loop if J /= Empty_Piece then if J.Owner = Player_1 then Attribute_On(2); end if; Put(To=>Small_String, Item=>J.Name); Pretty_Print_Window(Small_String); Attribute_On(1); else Pretty_Print_Window(" "); end if; Pretty_Print_Window(" | "); end loop; Pretty_Print_Line_Window(ASCII.lf & " | | | | | | | | | "); end loop; Pretty_Print_Line_Window(" -------------------------------------------------------------------------"); Pretty_Print_Line_Window(" A B C D E F G H "); Refresh; end Print_Board; procedure Move (From, To : in Cordinate_Type) is begin -- Move if Our_Board(From.Y)(From.X).Owner /= Owner_Type'Val(Turn) then -- check if it's their piece raise Not_Allowed; end if; case Our_Board(From.Y)(From.X).Name is -- check to see if move if possible when Pawn => --since the pawn move logic is so complex, it's best to do it all here declare Turn_Test : Integer; function "+" (Left: in Position; Right : in Integer) return Position is (Position(Integer(Left) + Right)); begin Turn_Test := (if Turn = 0 then -1 else 1); if Integer(From.X - To.X) = 0 then -- advance if Our_Board(To.Y)(To.X).Owner = None and -- can't attack forward then (Integer(From.Y - To.Y) = Turn_Test or (Integer(From.Y - To.Y) = Turn_Test*2 and Our_Board(From.Y)(From.X).Has_Moved = No and Our_Board(To.Y + Turn_Test)(To.X).Owner = None)) then --check if move is valid Take_Space(From, To); else raise Not_Allowed; end if; elsif Integer(From.X - To.X) in -1..1 then -- attack move if Integer(From.Y - To.Y) = Turn_Test then --check if move is valid if Our_Board(To.Y)(To.X).Owner /= None then Take_Space(From, To); elsif Our_Board(Last_Moved.Y)(Last_Moved.X).Name = Pawn and -- en passent then Last_Moved = (X=>To.X, Y=>To.Y + Turn_Test) then Our_Board(Last_Moved.Y)(Last_Moved.X) := Empty_Piece; Take_Space(From, To); else raise Not_Allowed; end if; else raise Not_Allowed; end if; else raise Not_Allowed; end if; end; when Knight => if abs(From.X - To.X) = 1 and then abs(From.Y - To.Y) = 2 then Take_Space(From, To); elsif abs(From.X - To.X) = 2 and then abs(From.Y - To.Y) = 1 then Take_Space(From, To); else raise Not_Allowed; end if; when Rook => if (From.X = To.X and From.Y /= To.Y) or else (From.Y = To.Y and From.X /= To.X) then Take_Space(From, To); else raise Not_Allowed; end if; when Bishop => if abs(From.X - To.X) = abs(From.Y - To.Y) then Take_Space(From, To); else raise Not_Allowed; end if; when Queen => if (From.X = To.X and From.Y /= To.Y) or else (From.Y = To.Y and From.X /= To.X) then Take_Space(From, To); elsif abs(From.X - To.X) = abs(From.Y - To.Y) then Take_Space(From, To); else raise Not_Allowed; end if; when King => if To.X - From.X in -1..1 and To.Y - From.Y in -1..1 then Take_Space(From, To); elsif abs(To.X - From.X) = 2 and To.Y = From.Y then Castle(From, To); else raise Not_Allowed; end if; when others => raise Empty_Zone; end case; end Move; procedure End_Turn is begin Turn := Turn + 1; end End_Turn; Procedure Castle (From, To : in Cordinate_Type) is Rook_Position : Position; Loop_Range_Start : Position; Loop_Range_End : Position; begin if From.X > To.X then Rook_Position := 0; Loop_Range_Start := 1; Loop_Range_End := 2; else Rook_Position := 7; Loop_Range_Start := 4; Loop_Range_End := 6; end if; if Our_Board(From.Y)(From.X).Has_Moved = No and then Our_Board(From.Y)(Rook_Position).Has_Moved = No then if (for all I of Our_Board(From.Y)(Loop_Range_Start..Loop_Range_End) => I.Name = Empty) then if Rook_Position = 0 then Take_Space((X=>Rook_Position, Y=>From.Y), (X=>Loop_Range_End, Y=>From.Y)); -- Move Rook; else Take_Space((X=>Rook_Position, Y=>From.Y), (X=>Loop_Range_Start, Y=>From.Y)); -- Move Rook; end if; Take_Space(From, To); -- Move King else raise Collision; end if; else raise Not_Allowed; end if; end Castle; function Is_Winner return Integer is begin if Our_Board(King_Status(0).Y)(King_Status(0).X).Name /= King and Our_Board(King_Status(0).Y)(King_Status(0).X).Owner /= Player_1 then return 2; elsif Our_Board(King_Status(1).Y)(King_Status(1).X).Name /= King and Our_Board(King_Status(1).Y)(King_Status(1).X).Owner /= Player_2 then return 1; else return 0; end if; end Is_Winner; --physically move, checks for collisions procedure Take_Space (From, To : in Cordinate_Type) is Old_Piece : constant Piece_Type := Our_Board(From.Y)(From.X); --From acts as old spot, since 'in' Temp_Position : Cordinate_Type := From; Step_Size : Unit_Position; begin if Our_Board(To.Y)(To.X).Owner = Owner_Type'Val(Turn) then raise Collision; end if; case Our_Board(From.Y)(From.X).Name is when Pawn..Knight => Our_Board(From.Y)(From.X) := Empty_Piece; Our_Board(To.Y)(To.X) := Old_Piece; when Bishop..Queen => Step_Size := To & From; while Temp_Position /= To loop -- walk the line Temp_Position := Temp_Position + Step_Size; exit when Our_Board(Temp_Position.Y)(Temp_Position.X) /= Empty_Piece; end loop; if Temp_Position = To then Our_Board(From.Y)(From.X) := Empty_Piece; Our_Board(To.Y)(To.X) := Old_Piece; else raise Collision; end if; when King => Our_Board(From.Y)(From.X) := Empty_Piece; Our_Board(To.Y)(To.X) := Old_Piece; King_Status(Integer(Turn)) := To; when Empty => raise Unknown; end case; Our_Board(To.Y)(To.X).Has_Moved := Yes; if Our_Board(To.Y)(To.X).Name = Pawn and then (To.Y = 7 or To.Y = 0) then Our_Board(To.Y)(To.X).Name := Queen; end if; Last_Moved := To; end Take_Space; function "&" (Left, Right : in Cordinate_Type) return Unit_Position is Local : Unit_Position := (0, 0); begin if Left.X - Right.X > 0 then Local.X := 1; elsif Left.X - Right.X < 0 then Local.X := -1; end if; if Left.Y - Right.Y > 0 then Local.Y := 1; elsif Left.Y - Right.Y < 0 then Local.Y := -1; end if; return Local; end "&"; end Board;
with ada.text_io, ada.Integer_text_IO, Ada.Text_IO.Text_Streams, Ada.Strings.Fixed, Interfaces.C; use ada.text_io, ada.Integer_text_IO, Ada.Strings, Ada.Strings.Fixed, Interfaces.C; procedure vigenere is type stringptr is access all char_array; procedure PString(s : stringptr) is begin String'Write (Text_Streams.Stream (Current_Output), To_Ada(s.all)); end; procedure PChar(c : in Character) is begin Character'Write (Text_Streams.Stream (Current_Output), c); end; procedure SkipSpaces is C : Character; Eol : Boolean; begin loop Look_Ahead(C, Eol); exit when Eol or C /= ' '; Get(C); end loop; end; function position_alphabet(c : in Character) return Integer is i : Integer; begin i := Character'Pos(c); if i <= Character'Pos('Z') and then i >= Character'Pos('A') then return i - Character'Pos('A'); else if i <= Character'Pos('z') and then i >= Character'Pos('a') then return i - Character'Pos('a'); else return (-1); end if; end if; end; function of_position_alphabet(c : in Integer) return Character is begin return Character'Val(c + Character'Pos('a')); end; type a is Array (Integer range <>) of Character; type a_PTR is access a; procedure crypte(taille_cle : in Integer; cle : in a_PTR; taille : in Integer; message : in a_PTR) is new0 : Integer; lettre : Integer; addon : Integer; begin for i in integer range 0..taille - 1 loop lettre := position_alphabet(message(i)); if lettre /= (-1) then addon := position_alphabet(cle(i rem taille_cle)); new0 := (addon + lettre) rem 26; message(i) := of_position_alphabet(new0); end if; end loop; end; taille_cle : Integer; taille : Integer; out2 : Character; out0 : Character; message : a_PTR; cle : a_PTR; begin Get(taille_cle); SkipSpaces; cle := new a (0..taille_cle - 1); for index in integer range 0..taille_cle - 1 loop Get(out0); cle(index) := out0; end loop; SkipSpaces; Get(taille); SkipSpaces; message := new a (0..taille - 1); for index2 in integer range 0..taille - 1 loop Get(out2); message(index2) := out2; end loop; crypte(taille_cle, cle, taille, message); for i in integer range 0..taille - 1 loop PChar(message(i)); end loop; PString(new char_array'( To_C("" & Character'Val(10)))); end;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2012, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- This file is generated, don't edit it. ------------------------------------------------------------------------------ with AMF.DG.Clip_Paths; with AMF.DG.Graphical_Elements.Collections; with AMF.DG.Groups; with AMF.DG.Styles.Collections; with AMF.Elements; with AMF.Internals.Element_Collections; with AMF.Internals.Helpers; with AMF.Internals.Tables.DD_Attributes; with AMF.Visitors.DG_Iterators; with AMF.Visitors.DG_Visitors; package body AMF.Internals.DG_Groups is ---------------- -- Get_Member -- ---------------- overriding function Get_Member (Self : not null access constant DG_Group_Proxy) return AMF.DG.Graphical_Elements.Collections.Ordered_Set_Of_DG_Graphical_Element is begin return AMF.DG.Graphical_Elements.Collections.Wrap (AMF.Internals.Element_Collections.Wrap (AMF.Internals.Tables.DD_Attributes.Internal_Get_Member (Self.Element))); end Get_Member; --------------- -- Get_Group -- --------------- overriding function Get_Group (Self : not null access constant DG_Group_Proxy) return AMF.DG.Groups.DG_Group_Access is begin return AMF.DG.Groups.DG_Group_Access (AMF.Internals.Helpers.To_Element (AMF.Internals.Tables.DD_Attributes.Internal_Get_Group (Self.Element))); end Get_Group; --------------- -- Set_Group -- --------------- overriding procedure Set_Group (Self : not null access DG_Group_Proxy; To : AMF.DG.Groups.DG_Group_Access) is begin AMF.Internals.Tables.DD_Attributes.Internal_Set_Group (Self.Element, AMF.Internals.Helpers.To_Element (AMF.Elements.Element_Access (To))); end Set_Group; --------------------- -- Get_Local_Style -- --------------------- overriding function Get_Local_Style (Self : not null access constant DG_Group_Proxy) return AMF.DG.Styles.Collections.Ordered_Set_Of_DG_Style is begin return AMF.DG.Styles.Collections.Wrap (AMF.Internals.Element_Collections.Wrap (AMF.Internals.Tables.DD_Attributes.Internal_Get_Local_Style (Self.Element))); end Get_Local_Style; ---------------------- -- Get_Shared_Style -- ---------------------- overriding function Get_Shared_Style (Self : not null access constant DG_Group_Proxy) return AMF.DG.Styles.Collections.Ordered_Set_Of_DG_Style is begin return AMF.DG.Styles.Collections.Wrap (AMF.Internals.Element_Collections.Wrap (AMF.Internals.Tables.DD_Attributes.Internal_Get_Shared_Style (Self.Element))); end Get_Shared_Style; ------------------- -- Get_Transform -- ------------------- overriding function Get_Transform (Self : not null access constant DG_Group_Proxy) return AMF.DG.Sequence_Of_DG_Transform is begin return AMF.Internals.Tables.DD_Attributes.Internal_Get_Transform (Self.Element); end Get_Transform; ------------------- -- Get_Clip_Path -- ------------------- overriding function Get_Clip_Path (Self : not null access constant DG_Group_Proxy) return AMF.DG.Clip_Paths.DG_Clip_Path_Access is begin return AMF.DG.Clip_Paths.DG_Clip_Path_Access (AMF.Internals.Helpers.To_Element (AMF.Internals.Tables.DD_Attributes.Internal_Get_Clip_Path (Self.Element))); end Get_Clip_Path; ------------------- -- Set_Clip_Path -- ------------------- overriding procedure Set_Clip_Path (Self : not null access DG_Group_Proxy; To : AMF.DG.Clip_Paths.DG_Clip_Path_Access) is begin AMF.Internals.Tables.DD_Attributes.Internal_Set_Clip_Path (Self.Element, AMF.Internals.Helpers.To_Element (AMF.Elements.Element_Access (To))); end Set_Clip_Path; ------------------- -- Enter_Element -- ------------------- overriding procedure Enter_Element (Self : not null access constant DG_Group_Proxy; Visitor : in out AMF.Visitors.Abstract_Visitor'Class; Control : in out AMF.Visitors.Traverse_Control) is begin if Visitor in AMF.Visitors.DG_Visitors.DG_Visitor'Class then AMF.Visitors.DG_Visitors.DG_Visitor'Class (Visitor).Enter_Group (AMF.DG.Groups.DG_Group_Access (Self), Control); end if; end Enter_Element; ------------------- -- Leave_Element -- ------------------- overriding procedure Leave_Element (Self : not null access constant DG_Group_Proxy; Visitor : in out AMF.Visitors.Abstract_Visitor'Class; Control : in out AMF.Visitors.Traverse_Control) is begin if Visitor in AMF.Visitors.DG_Visitors.DG_Visitor'Class then AMF.Visitors.DG_Visitors.DG_Visitor'Class (Visitor).Leave_Group (AMF.DG.Groups.DG_Group_Access (Self), Control); end if; end Leave_Element; ------------------- -- Visit_Element -- ------------------- overriding procedure Visit_Element (Self : not null access constant DG_Group_Proxy; Iterator : in out AMF.Visitors.Abstract_Iterator'Class; Visitor : in out AMF.Visitors.Abstract_Visitor'Class; Control : in out AMF.Visitors.Traverse_Control) is begin if Iterator in AMF.Visitors.DG_Iterators.DG_Iterator'Class then AMF.Visitors.DG_Iterators.DG_Iterator'Class (Iterator).Visit_Group (Visitor, AMF.DG.Groups.DG_Group_Access (Self), Control); end if; end Visit_Element; end AMF.Internals.DG_Groups;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- A D A . S T R I N G S . W I D E _ S U P E R B O U N D E D -- -- -- -- B o d y -- -- -- -- Copyright (C) 2003-2021, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Ada.Strings.Wide_Maps; use Ada.Strings.Wide_Maps; with Ada.Strings.Wide_Search; package body Ada.Strings.Wide_Superbounded is ------------ -- Concat -- ------------ function Concat (Left : Super_String; Right : Super_String) return Super_String is begin return Result : Super_String (Left.Max_Length) do declare Llen : constant Natural := Left.Current_Length; Rlen : constant Natural := Right.Current_Length; Nlen : constant Natural := Llen + Rlen; begin if Nlen > Left.Max_Length then raise Ada.Strings.Length_Error; else Result.Current_Length := Nlen; Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Llen + 1 .. Nlen) := Right.Data (1 .. Rlen); end if; end; end return; end Concat; function Concat (Left : Super_String; Right : Wide_String) return Super_String is begin return Result : Super_String (Left.Max_Length) do declare Llen : constant Natural := Left.Current_Length; Nlen : constant Natural := Llen + Right'Length; begin if Nlen > Left.Max_Length then raise Ada.Strings.Length_Error; else Result.Current_Length := Nlen; Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Llen + 1 .. Nlen) := Right; end if; end; end return; end Concat; function Concat (Left : Wide_String; Right : Super_String) return Super_String is begin return Result : Super_String (Right.Max_Length) do declare Llen : constant Natural := Left'Length; Rlen : constant Natural := Right.Current_Length; Nlen : constant Natural := Llen + Rlen; begin if Nlen > Right.Max_Length then raise Ada.Strings.Length_Error; else Result.Current_Length := Nlen; Result.Data (1 .. Llen) := Left; Result.Data (Llen + 1 .. Nlen) := Right.Data (1 .. Rlen); end if; end; end return; end Concat; function Concat (Left : Super_String; Right : Wide_Character) return Super_String is begin return Result : Super_String (Left.Max_Length) do declare Llen : constant Natural := Left.Current_Length; begin if Llen = Left.Max_Length then raise Ada.Strings.Length_Error; else Result.Current_Length := Llen + 1; Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Result.Current_Length) := Right; end if; end; end return; end Concat; function Concat (Left : Wide_Character; Right : Super_String) return Super_String is begin return Result : Super_String (Right.Max_Length) do declare Rlen : constant Natural := Right.Current_Length; begin if Rlen = Right.Max_Length then raise Ada.Strings.Length_Error; else Result.Current_Length := Rlen + 1; Result.Data (1) := Left; Result.Data (2 .. Result.Current_Length) := Right.Data (1 .. Rlen); end if; end; end return; end Concat; ----------- -- Equal -- ----------- function "=" (Left : Super_String; Right : Super_String) return Boolean is begin return Left.Current_Length = Right.Current_Length and then Left.Data (1 .. Left.Current_Length) = Right.Data (1 .. Right.Current_Length); end "="; function Equal (Left : Super_String; Right : Wide_String) return Boolean is begin return Left.Current_Length = Right'Length and then Left.Data (1 .. Left.Current_Length) = Right; end Equal; function Equal (Left : Wide_String; Right : Super_String) return Boolean is begin return Left'Length = Right.Current_Length and then Left = Right.Data (1 .. Right.Current_Length); end Equal; ------------- -- Greater -- ------------- function Greater (Left : Super_String; Right : Super_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) > Right.Data (1 .. Right.Current_Length); end Greater; function Greater (Left : Super_String; Right : Wide_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) > Right; end Greater; function Greater (Left : Wide_String; Right : Super_String) return Boolean is begin return Left > Right.Data (1 .. Right.Current_Length); end Greater; ---------------------- -- Greater_Or_Equal -- ---------------------- function Greater_Or_Equal (Left : Super_String; Right : Super_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) >= Right.Data (1 .. Right.Current_Length); end Greater_Or_Equal; function Greater_Or_Equal (Left : Super_String; Right : Wide_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) >= Right; end Greater_Or_Equal; function Greater_Or_Equal (Left : Wide_String; Right : Super_String) return Boolean is begin return Left >= Right.Data (1 .. Right.Current_Length); end Greater_Or_Equal; ---------- -- Less -- ---------- function Less (Left : Super_String; Right : Super_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) < Right.Data (1 .. Right.Current_Length); end Less; function Less (Left : Super_String; Right : Wide_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) < Right; end Less; function Less (Left : Wide_String; Right : Super_String) return Boolean is begin return Left < Right.Data (1 .. Right.Current_Length); end Less; ------------------- -- Less_Or_Equal -- ------------------- function Less_Or_Equal (Left : Super_String; Right : Super_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) <= Right.Data (1 .. Right.Current_Length); end Less_Or_Equal; function Less_Or_Equal (Left : Super_String; Right : Wide_String) return Boolean is begin return Left.Data (1 .. Left.Current_Length) <= Right; end Less_Or_Equal; function Less_Or_Equal (Left : Wide_String; Right : Super_String) return Boolean is begin return Left <= Right.Data (1 .. Right.Current_Length); end Less_Or_Equal; ---------------------- -- Set_Super_String -- ---------------------- procedure Set_Super_String (Target : out Super_String; Source : Wide_String; Drop : Truncation := Error) is Slen : constant Natural := Source'Length; Max_Length : constant Positive := Target.Max_Length; begin if Slen <= Max_Length then Target.Current_Length := Slen; Target.Data (1 .. Slen) := Source; else case Drop is when Strings.Right => Target.Current_Length := Max_Length; Target.Data (1 .. Max_Length) := Source (Source'First .. Source'First - 1 + Max_Length); when Strings.Left => Target.Current_Length := Max_Length; Target.Data (1 .. Max_Length) := Source (Source'Last - (Max_Length - 1) .. Source'Last); when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Set_Super_String; ------------------ -- Super_Append -- ------------------ -- Case of Super_String and Super_String function Super_Append (Left : Super_String; Right : Super_String; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Left.Max_Length; Result : Super_String (Max_Length); Llen : constant Natural := Left.Current_Length; Rlen : constant Natural := Right.Current_Length; Nlen : constant Natural := Llen + Rlen; begin if Nlen <= Max_Length then Result.Current_Length := Nlen; Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Llen + 1 .. Nlen) := Right.Data (1 .. Rlen); else Result.Current_Length := Max_Length; case Drop is when Strings.Right => if Llen >= Max_Length then -- only case is Llen = Max_Length Result.Data := Left.Data; else Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Llen + 1 .. Max_Length) := Right.Data (1 .. Max_Length - Llen); end if; when Strings.Left => if Rlen >= Max_Length then -- only case is Rlen = Max_Length Result.Data := Right.Data; else Result.Data (1 .. Max_Length - Rlen) := Left.Data (Llen - (Max_Length - Rlen - 1) .. Llen); Result.Data (Max_Length - Rlen + 1 .. Max_Length) := Right.Data (1 .. Rlen); end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end Super_Append; procedure Super_Append (Source : in out Super_String; New_Item : Super_String; Drop : Truncation := Error) is Max_Length : constant Positive := Source.Max_Length; Llen : constant Natural := Source.Current_Length; Rlen : constant Natural := New_Item.Current_Length; Nlen : constant Natural := Llen + Rlen; begin if Nlen <= Max_Length then Source.Current_Length := Nlen; Source.Data (Llen + 1 .. Nlen) := New_Item.Data (1 .. Rlen); else Source.Current_Length := Max_Length; case Drop is when Strings.Right => if Llen < Max_Length then Source.Data (Llen + 1 .. Max_Length) := New_Item.Data (1 .. Max_Length - Llen); end if; when Strings.Left => if Rlen >= Max_Length then -- only case is Rlen = Max_Length Source.Data := New_Item.Data; else Source.Data (1 .. Max_Length - Rlen) := Source.Data (Llen - (Max_Length - Rlen - 1) .. Llen); Source.Data (Max_Length - Rlen + 1 .. Max_Length) := New_Item.Data (1 .. Rlen); end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Append; -- Case of Super_String and Wide_String function Super_Append (Left : Super_String; Right : Wide_String; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Left.Max_Length; Result : Super_String (Max_Length); Llen : constant Natural := Left.Current_Length; Rlen : constant Natural := Right'Length; Nlen : constant Natural := Llen + Rlen; begin if Nlen <= Max_Length then Result.Current_Length := Nlen; Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Llen + 1 .. Nlen) := Right; else Result.Current_Length := Max_Length; case Drop is when Strings.Right => if Llen >= Max_Length then -- only case is Llen = Max_Length Result.Data := Left.Data; else Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Llen + 1 .. Max_Length) := Right (Right'First .. Right'First - 1 + Max_Length - Llen); end if; when Strings.Left => if Rlen >= Max_Length then Result.Data (1 .. Max_Length) := Right (Right'Last - (Max_Length - 1) .. Right'Last); else Result.Data (1 .. Max_Length - Rlen) := Left.Data (Llen - (Max_Length - Rlen - 1) .. Llen); Result.Data (Max_Length - Rlen + 1 .. Max_Length) := Right; end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end Super_Append; procedure Super_Append (Source : in out Super_String; New_Item : Wide_String; Drop : Truncation := Error) is Max_Length : constant Positive := Source.Max_Length; Llen : constant Natural := Source.Current_Length; Rlen : constant Natural := New_Item'Length; Nlen : constant Natural := Llen + Rlen; begin if Nlen <= Max_Length then Source.Current_Length := Nlen; Source.Data (Llen + 1 .. Nlen) := New_Item; else Source.Current_Length := Max_Length; case Drop is when Strings.Right => if Llen < Max_Length then Source.Data (Llen + 1 .. Max_Length) := New_Item (New_Item'First .. New_Item'First - 1 + Max_Length - Llen); end if; when Strings.Left => if Rlen >= Max_Length then Source.Data (1 .. Max_Length) := New_Item (New_Item'Last - (Max_Length - 1) .. New_Item'Last); else Source.Data (1 .. Max_Length - Rlen) := Source.Data (Llen - (Max_Length - Rlen - 1) .. Llen); Source.Data (Max_Length - Rlen + 1 .. Max_Length) := New_Item; end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Append; -- Case of Wide_String and Super_String function Super_Append (Left : Wide_String; Right : Super_String; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Right.Max_Length; Result : Super_String (Max_Length); Llen : constant Natural := Left'Length; Rlen : constant Natural := Right.Current_Length; Nlen : constant Natural := Llen + Rlen; begin if Nlen <= Max_Length then Result.Current_Length := Nlen; Result.Data (1 .. Llen) := Left; Result.Data (Llen + 1 .. Llen + Rlen) := Right.Data (1 .. Rlen); else Result.Current_Length := Max_Length; case Drop is when Strings.Right => if Llen >= Max_Length then Result.Data (1 .. Max_Length) := Left (Left'First .. Left'First + (Max_Length - 1)); else Result.Data (1 .. Llen) := Left; Result.Data (Llen + 1 .. Max_Length) := Right.Data (1 .. Max_Length - Llen); end if; when Strings.Left => if Rlen >= Max_Length then Result.Data (1 .. Max_Length) := Right.Data (Rlen - (Max_Length - 1) .. Rlen); else Result.Data (1 .. Max_Length - Rlen) := Left (Left'Last - (Max_Length - Rlen - 1) .. Left'Last); Result.Data (Max_Length - Rlen + 1 .. Max_Length) := Right.Data (1 .. Rlen); end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end Super_Append; -- Case of Super_String and Wide_Character function Super_Append (Left : Super_String; Right : Wide_Character; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Left.Max_Length; Result : Super_String (Max_Length); Llen : constant Natural := Left.Current_Length; begin if Llen < Max_Length then Result.Current_Length := Llen + 1; Result.Data (1 .. Llen) := Left.Data (1 .. Llen); Result.Data (Llen + 1) := Right; return Result; else case Drop is when Strings.Right => return Left; when Strings.Left => Result.Current_Length := Max_Length; Result.Data (1 .. Max_Length - 1) := Left.Data (2 .. Max_Length); Result.Data (Max_Length) := Right; return Result; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Append; procedure Super_Append (Source : in out Super_String; New_Item : Wide_Character; Drop : Truncation := Error) is Max_Length : constant Positive := Source.Max_Length; Llen : constant Natural := Source.Current_Length; begin if Llen < Max_Length then Source.Current_Length := Llen + 1; Source.Data (Llen + 1) := New_Item; else Source.Current_Length := Max_Length; case Drop is when Strings.Right => null; when Strings.Left => Source.Data (1 .. Max_Length - 1) := Source.Data (2 .. Max_Length); Source.Data (Max_Length) := New_Item; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Append; -- Case of Wide_Character and Super_String function Super_Append (Left : Wide_Character; Right : Super_String; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Right.Max_Length; Result : Super_String (Max_Length); Rlen : constant Natural := Right.Current_Length; begin if Rlen < Max_Length then Result.Current_Length := Rlen + 1; Result.Data (1) := Left; Result.Data (2 .. Rlen + 1) := Right.Data (1 .. Rlen); return Result; else case Drop is when Strings.Right => Result.Current_Length := Max_Length; Result.Data (1) := Left; Result.Data (2 .. Max_Length) := Right.Data (1 .. Max_Length - 1); return Result; when Strings.Left => return Right; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Append; ----------------- -- Super_Count -- ----------------- function Super_Count (Source : Super_String; Pattern : Wide_String; Mapping : Wide_Maps.Wide_Character_Mapping := Wide_Maps.Identity) return Natural is begin return Wide_Search.Count (Source.Data (1 .. Source.Current_Length), Pattern, Mapping); end Super_Count; function Super_Count (Source : Super_String; Pattern : Wide_String; Mapping : Wide_Maps.Wide_Character_Mapping_Function) return Natural is begin return Wide_Search.Count (Source.Data (1 .. Source.Current_Length), Pattern, Mapping); end Super_Count; function Super_Count (Source : Super_String; Set : Wide_Maps.Wide_Character_Set) return Natural is begin return Wide_Search.Count (Source.Data (1 .. Source.Current_Length), Set); end Super_Count; ------------------ -- Super_Delete -- ------------------ function Super_Delete (Source : Super_String; From : Positive; Through : Natural) return Super_String is Result : Super_String (Source.Max_Length); Slen : constant Natural := Source.Current_Length; Num_Delete : constant Integer := Through - From + 1; begin if Num_Delete <= 0 then return Source; elsif From > Slen + 1 then raise Ada.Strings.Index_Error; elsif Through >= Slen then Result.Current_Length := From - 1; Result.Data (1 .. From - 1) := Source.Data (1 .. From - 1); return Result; else Result.Current_Length := Slen - Num_Delete; Result.Data (1 .. From - 1) := Source.Data (1 .. From - 1); Result.Data (From .. Result.Current_Length) := Source.Data (Through + 1 .. Slen); return Result; end if; end Super_Delete; procedure Super_Delete (Source : in out Super_String; From : Positive; Through : Natural) is Slen : constant Natural := Source.Current_Length; Num_Delete : constant Integer := Through - From + 1; begin if Num_Delete <= 0 then return; elsif From > Slen + 1 then raise Ada.Strings.Index_Error; elsif Through >= Slen then Source.Current_Length := From - 1; else Source.Current_Length := Slen - Num_Delete; Source.Data (From .. Source.Current_Length) := Source.Data (Through + 1 .. Slen); end if; end Super_Delete; ------------------- -- Super_Element -- ------------------- function Super_Element (Source : Super_String; Index : Positive) return Wide_Character is begin if Index <= Source.Current_Length then return Source.Data (Index); else raise Strings.Index_Error; end if; end Super_Element; ---------------------- -- Super_Find_Token -- ---------------------- procedure Super_Find_Token (Source : Super_String; Set : Wide_Maps.Wide_Character_Set; From : Positive; Test : Strings.Membership; First : out Positive; Last : out Natural) is begin Wide_Search.Find_Token (Source.Data (From .. Source.Current_Length), Set, Test, First, Last); end Super_Find_Token; procedure Super_Find_Token (Source : Super_String; Set : Wide_Maps.Wide_Character_Set; Test : Strings.Membership; First : out Positive; Last : out Natural) is begin Wide_Search.Find_Token (Source.Data (1 .. Source.Current_Length), Set, Test, First, Last); end Super_Find_Token; ---------------- -- Super_Head -- ---------------- function Super_Head (Source : Super_String; Count : Natural; Pad : Wide_Character := Wide_Space; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Source.Max_Length; Result : Super_String (Max_Length); Slen : constant Natural := Source.Current_Length; Npad : constant Integer := Count - Slen; begin if Npad <= 0 then Result.Current_Length := Count; Result.Data (1 .. Count) := Source.Data (1 .. Count); elsif Count <= Max_Length then Result.Current_Length := Count; Result.Data (1 .. Slen) := Source.Data (1 .. Slen); Result.Data (Slen + 1 .. Count) := (others => Pad); else Result.Current_Length := Max_Length; case Drop is when Strings.Right => Result.Data (1 .. Slen) := Source.Data (1 .. Slen); Result.Data (Slen + 1 .. Max_Length) := (others => Pad); when Strings.Left => if Npad >= Max_Length then Result.Data := (others => Pad); else Result.Data (1 .. Max_Length - Npad) := Source.Data (Count - Max_Length + 1 .. Slen); Result.Data (Max_Length - Npad + 1 .. Max_Length) := (others => Pad); end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end Super_Head; procedure Super_Head (Source : in out Super_String; Count : Natural; Pad : Wide_Character := Wide_Space; Drop : Truncation := Error) is Max_Length : constant Positive := Source.Max_Length; Slen : constant Natural := Source.Current_Length; Npad : constant Integer := Count - Slen; Temp : Wide_String (1 .. Max_Length); begin if Npad <= 0 then Source.Current_Length := Count; elsif Count <= Max_Length then Source.Current_Length := Count; Source.Data (Slen + 1 .. Count) := (others => Pad); else Source.Current_Length := Max_Length; case Drop is when Strings.Right => Source.Data (Slen + 1 .. Max_Length) := (others => Pad); when Strings.Left => if Npad > Max_Length then Source.Data := (others => Pad); else Temp := Source.Data; Source.Data (1 .. Max_Length - Npad) := Temp (Count - Max_Length + 1 .. Slen); for J in Max_Length - Npad + 1 .. Max_Length loop Source.Data (J) := Pad; end loop; end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Head; ----------------- -- Super_Index -- ----------------- function Super_Index (Source : Super_String; Pattern : Wide_String; Going : Strings.Direction := Strings.Forward; Mapping : Wide_Maps.Wide_Character_Mapping := Wide_Maps.Identity) return Natural is begin return Wide_Search.Index (Source.Data (1 .. Source.Current_Length), Pattern, Going, Mapping); end Super_Index; function Super_Index (Source : Super_String; Pattern : Wide_String; Going : Direction := Forward; Mapping : Wide_Maps.Wide_Character_Mapping_Function) return Natural is begin return Wide_Search.Index (Source.Data (1 .. Source.Current_Length), Pattern, Going, Mapping); end Super_Index; function Super_Index (Source : Super_String; Set : Wide_Maps.Wide_Character_Set; Test : Strings.Membership := Strings.Inside; Going : Strings.Direction := Strings.Forward) return Natural is begin return Wide_Search.Index (Source.Data (1 .. Source.Current_Length), Set, Test, Going); end Super_Index; function Super_Index (Source : Super_String; Pattern : Wide_String; From : Positive; Going : Direction := Forward; Mapping : Wide_Maps.Wide_Character_Mapping := Wide_Maps.Identity) return Natural is begin return Wide_Search.Index (Source.Data (1 .. Source.Current_Length), Pattern, From, Going, Mapping); end Super_Index; function Super_Index (Source : Super_String; Pattern : Wide_String; From : Positive; Going : Direction := Forward; Mapping : Wide_Maps.Wide_Character_Mapping_Function) return Natural is begin return Wide_Search.Index (Source.Data (1 .. Source.Current_Length), Pattern, From, Going, Mapping); end Super_Index; function Super_Index (Source : Super_String; Set : Wide_Maps.Wide_Character_Set; From : Positive; Test : Membership := Inside; Going : Direction := Forward) return Natural is begin return Wide_Search.Index (Source.Data (1 .. Source.Current_Length), Set, From, Test, Going); end Super_Index; --------------------------- -- Super_Index_Non_Blank -- --------------------------- function Super_Index_Non_Blank (Source : Super_String; Going : Strings.Direction := Strings.Forward) return Natural is begin return Wide_Search.Index_Non_Blank (Source.Data (1 .. Source.Current_Length), Going); end Super_Index_Non_Blank; function Super_Index_Non_Blank (Source : Super_String; From : Positive; Going : Direction := Forward) return Natural is begin return Wide_Search.Index_Non_Blank (Source.Data (1 .. Source.Current_Length), From, Going); end Super_Index_Non_Blank; ------------------ -- Super_Insert -- ------------------ function Super_Insert (Source : Super_String; Before : Positive; New_Item : Wide_String; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Source.Max_Length; Result : Super_String (Max_Length); Slen : constant Natural := Source.Current_Length; Nlen : constant Natural := New_Item'Length; Tlen : constant Natural := Slen + Nlen; Blen : constant Natural := Before - 1; Alen : constant Integer := Slen - Blen; Droplen : constant Integer := Tlen - Max_Length; -- Tlen is the length of the total string before possible truncation. -- Blen, Alen are the lengths of the before and after pieces of the -- source string. begin if Alen < 0 then raise Ada.Strings.Index_Error; elsif Droplen <= 0 then Result.Current_Length := Tlen; Result.Data (1 .. Blen) := Source.Data (1 .. Blen); Result.Data (Before .. Before + Nlen - 1) := New_Item; Result.Data (Before + Nlen .. Tlen) := Source.Data (Before .. Slen); else Result.Current_Length := Max_Length; case Drop is when Strings.Right => Result.Data (1 .. Blen) := Source.Data (1 .. Blen); if Droplen > Alen then Result.Data (Before .. Max_Length) := New_Item (New_Item'First .. New_Item'First + Max_Length - Before); else Result.Data (Before .. Before + Nlen - 1) := New_Item; Result.Data (Before + Nlen .. Max_Length) := Source.Data (Before .. Slen - Droplen); end if; when Strings.Left => Result.Data (Max_Length - (Alen - 1) .. Max_Length) := Source.Data (Before .. Slen); if Droplen >= Blen then Result.Data (1 .. Max_Length - Alen) := New_Item (New_Item'Last - (Max_Length - Alen) + 1 .. New_Item'Last); else Result.Data (Blen - Droplen + 1 .. Max_Length - Alen) := New_Item; Result.Data (1 .. Blen - Droplen) := Source.Data (Droplen + 1 .. Blen); end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end Super_Insert; procedure Super_Insert (Source : in out Super_String; Before : Positive; New_Item : Wide_String; Drop : Strings.Truncation := Strings.Error) is begin -- We do a double copy here because this is one of the situations -- in which we move data to the right, and at least at the moment, -- GNAT is not handling such cases correctly ??? Source := Super_Insert (Source, Before, New_Item, Drop); end Super_Insert; ------------------ -- Super_Length -- ------------------ function Super_Length (Source : Super_String) return Natural is begin return Source.Current_Length; end Super_Length; --------------------- -- Super_Overwrite -- --------------------- function Super_Overwrite (Source : Super_String; Position : Positive; New_Item : Wide_String; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Source.Max_Length; Result : Super_String (Max_Length); Endpos : constant Natural := Position + New_Item'Length - 1; Slen : constant Natural := Source.Current_Length; Droplen : Natural; begin if Position > Slen + 1 then raise Ada.Strings.Index_Error; elsif New_Item'Length = 0 then return Source; elsif Endpos <= Slen then Result.Current_Length := Source.Current_Length; Result.Data (1 .. Slen) := Source.Data (1 .. Slen); Result.Data (Position .. Endpos) := New_Item; return Result; elsif Endpos <= Max_Length then Result.Current_Length := Endpos; Result.Data (1 .. Position - 1) := Source.Data (1 .. Position - 1); Result.Data (Position .. Endpos) := New_Item; return Result; else Result.Current_Length := Max_Length; Droplen := Endpos - Max_Length; case Drop is when Strings.Right => Result.Data (1 .. Position - 1) := Source.Data (1 .. Position - 1); Result.Data (Position .. Max_Length) := New_Item (New_Item'First .. New_Item'Last - Droplen); return Result; when Strings.Left => if New_Item'Length >= Max_Length then Result.Data (1 .. Max_Length) := New_Item (New_Item'Last - Max_Length + 1 .. New_Item'Last); return Result; else Result.Data (1 .. Max_Length - New_Item'Length) := Source.Data (Droplen + 1 .. Position - 1); Result.Data (Max_Length - New_Item'Length + 1 .. Max_Length) := New_Item; return Result; end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Overwrite; procedure Super_Overwrite (Source : in out Super_String; Position : Positive; New_Item : Wide_String; Drop : Strings.Truncation := Strings.Error) is Max_Length : constant Positive := Source.Max_Length; Endpos : constant Positive := Position + New_Item'Length - 1; Slen : constant Natural := Source.Current_Length; Droplen : Natural; begin if Position > Slen + 1 then raise Ada.Strings.Index_Error; elsif Endpos <= Slen then Source.Data (Position .. Endpos) := New_Item; elsif Endpos <= Max_Length then Source.Data (Position .. Endpos) := New_Item; Source.Current_Length := Endpos; else Source.Current_Length := Max_Length; Droplen := Endpos - Max_Length; case Drop is when Strings.Right => Source.Data (Position .. Max_Length) := New_Item (New_Item'First .. New_Item'Last - Droplen); when Strings.Left => if New_Item'Length > Max_Length then Source.Data (1 .. Max_Length) := New_Item (New_Item'Last - Max_Length + 1 .. New_Item'Last); else Source.Data (1 .. Max_Length - New_Item'Length) := Source.Data (Droplen + 1 .. Position - 1); Source.Data (Max_Length - New_Item'Length + 1 .. Max_Length) := New_Item; end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Overwrite; --------------------------- -- Super_Replace_Element -- --------------------------- procedure Super_Replace_Element (Source : in out Super_String; Index : Positive; By : Wide_Character) is begin if Index <= Source.Current_Length then Source.Data (Index) := By; else raise Ada.Strings.Index_Error; end if; end Super_Replace_Element; ------------------------- -- Super_Replace_Slice -- ------------------------- function Super_Replace_Slice (Source : Super_String; Low : Positive; High : Natural; By : Wide_String; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Source.Max_Length; Slen : constant Natural := Source.Current_Length; begin if Low > Slen + 1 then raise Strings.Index_Error; elsif High < Low then return Super_Insert (Source, Low, By, Drop); else declare Blen : constant Natural := Natural'Max (0, Low - 1); Alen : constant Natural := Natural'Max (0, Slen - High); Tlen : constant Natural := Blen + By'Length + Alen; Droplen : constant Integer := Tlen - Max_Length; Result : Super_String (Max_Length); -- Tlen is the total length of the result string before any -- truncation. Blen and Alen are the lengths of the pieces -- of the original string that end up in the result string -- before and after the replaced slice. begin if Droplen <= 0 then Result.Current_Length := Tlen; Result.Data (1 .. Blen) := Source.Data (1 .. Blen); Result.Data (Low .. Low + By'Length - 1) := By; Result.Data (Low + By'Length .. Tlen) := Source.Data (High + 1 .. Slen); else Result.Current_Length := Max_Length; case Drop is when Strings.Right => Result.Data (1 .. Blen) := Source.Data (1 .. Blen); if Droplen > Alen then Result.Data (Low .. Max_Length) := By (By'First .. By'First + Max_Length - Low); else Result.Data (Low .. Low + By'Length - 1) := By; Result.Data (Low + By'Length .. Max_Length) := Source.Data (High + 1 .. Slen - Droplen); end if; when Strings.Left => Result.Data (Max_Length - (Alen - 1) .. Max_Length) := Source.Data (High + 1 .. Slen); if Droplen >= Blen then Result.Data (1 .. Max_Length - Alen) := By (By'Last - (Max_Length - Alen) + 1 .. By'Last); else Result.Data (Blen - Droplen + 1 .. Max_Length - Alen) := By; Result.Data (1 .. Blen - Droplen) := Source.Data (Droplen + 1 .. Blen); end if; when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end; end if; end Super_Replace_Slice; procedure Super_Replace_Slice (Source : in out Super_String; Low : Positive; High : Natural; By : Wide_String; Drop : Strings.Truncation := Strings.Error) is begin -- We do a double copy here because this is one of the situations -- in which we move data to the right, and at least at the moment, -- GNAT is not handling such cases correctly ??? Source := Super_Replace_Slice (Source, Low, High, By, Drop); end Super_Replace_Slice; --------------------- -- Super_Replicate -- --------------------- function Super_Replicate (Count : Natural; Item : Wide_Character; Drop : Truncation := Error; Max_Length : Positive) return Super_String is Result : Super_String (Max_Length); begin if Count <= Max_Length then Result.Current_Length := Count; elsif Drop = Strings.Error then raise Ada.Strings.Length_Error; else Result.Current_Length := Max_Length; end if; Result.Data (1 .. Result.Current_Length) := (others => Item); return Result; end Super_Replicate; function Super_Replicate (Count : Natural; Item : Wide_String; Drop : Truncation := Error; Max_Length : Positive) return Super_String is Length : constant Integer := Count * Item'Length; Result : Super_String (Max_Length); Indx : Positive; begin if Length <= Max_Length then Result.Current_Length := Length; if Length > 0 then Indx := 1; for J in 1 .. Count loop Result.Data (Indx .. Indx + Item'Length - 1) := Item; Indx := Indx + Item'Length; end loop; end if; else Result.Current_Length := Max_Length; case Drop is when Strings.Right => Indx := 1; while Indx + Item'Length <= Max_Length + 1 loop Result.Data (Indx .. Indx + Item'Length - 1) := Item; Indx := Indx + Item'Length; end loop; Result.Data (Indx .. Max_Length) := Item (Item'First .. Item'First + Max_Length - Indx); when Strings.Left => Indx := Max_Length; while Indx - Item'Length >= 1 loop Result.Data (Indx - (Item'Length - 1) .. Indx) := Item; Indx := Indx - Item'Length; end loop; Result.Data (1 .. Indx) := Item (Item'Last - Indx + 1 .. Item'Last); when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end Super_Replicate; function Super_Replicate (Count : Natural; Item : Super_String; Drop : Strings.Truncation := Strings.Error) return Super_String is begin return Super_Replicate (Count, Item.Data (1 .. Item.Current_Length), Drop, Item.Max_Length); end Super_Replicate; ----------------- -- Super_Slice -- ----------------- function Super_Slice (Source : Super_String; Low : Positive; High : Natural) return Wide_String is begin -- Note: test of High > Length is in accordance with AI95-00128 return R : Wide_String (Low .. High) do if Low > Source.Current_Length + 1 or else High > Source.Current_Length then raise Index_Error; end if; R := Source.Data (Low .. High); end return; end Super_Slice; function Super_Slice (Source : Super_String; Low : Positive; High : Natural) return Super_String is begin return Result : Super_String (Source.Max_Length) do if Low > Source.Current_Length + 1 or else High > Source.Current_Length then raise Index_Error; end if; Result.Current_Length := High - Low + 1; Result.Data (1 .. Result.Current_Length) := Source.Data (Low .. High); end return; end Super_Slice; procedure Super_Slice (Source : Super_String; Target : out Super_String; Low : Positive; High : Natural) is begin if Low > Source.Current_Length + 1 or else High > Source.Current_Length then raise Index_Error; else Target.Current_Length := High - Low + 1; Target.Data (1 .. Target.Current_Length) := Source.Data (Low .. High); end if; end Super_Slice; ---------------- -- Super_Tail -- ---------------- function Super_Tail (Source : Super_String; Count : Natural; Pad : Wide_Character := Wide_Space; Drop : Strings.Truncation := Strings.Error) return Super_String is Max_Length : constant Positive := Source.Max_Length; Result : Super_String (Max_Length); Slen : constant Natural := Source.Current_Length; Npad : constant Integer := Count - Slen; begin if Npad <= 0 then Result.Current_Length := Count; Result.Data (1 .. Count) := Source.Data (Slen - (Count - 1) .. Slen); elsif Count <= Max_Length then Result.Current_Length := Count; Result.Data (1 .. Npad) := (others => Pad); Result.Data (Npad + 1 .. Count) := Source.Data (1 .. Slen); else Result.Current_Length := Max_Length; case Drop is when Strings.Right => if Npad >= Max_Length then Result.Data := (others => Pad); else Result.Data (1 .. Npad) := (others => Pad); Result.Data (Npad + 1 .. Max_Length) := Source.Data (1 .. Max_Length - Npad); end if; when Strings.Left => Result.Data (1 .. Max_Length - Slen) := (others => Pad); Result.Data (Max_Length - Slen + 1 .. Max_Length) := Source.Data (1 .. Slen); when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end Super_Tail; procedure Super_Tail (Source : in out Super_String; Count : Natural; Pad : Wide_Character := Wide_Space; Drop : Truncation := Error) is Max_Length : constant Positive := Source.Max_Length; Slen : constant Natural := Source.Current_Length; Npad : constant Integer := Count - Slen; Temp : constant Wide_String (1 .. Max_Length) := Source.Data; begin if Npad <= 0 then Source.Current_Length := Count; Source.Data (1 .. Count) := Temp (Slen - (Count - 1) .. Slen); elsif Count <= Max_Length then Source.Current_Length := Count; Source.Data (1 .. Npad) := (others => Pad); Source.Data (Npad + 1 .. Count) := Temp (1 .. Slen); else Source.Current_Length := Max_Length; case Drop is when Strings.Right => if Npad >= Max_Length then Source.Data := (others => Pad); else Source.Data (1 .. Npad) := (others => Pad); Source.Data (Npad + 1 .. Max_Length) := Temp (1 .. Max_Length - Npad); end if; when Strings.Left => for J in 1 .. Max_Length - Slen loop Source.Data (J) := Pad; end loop; Source.Data (Max_Length - Slen + 1 .. Max_Length) := Temp (1 .. Slen); when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; end Super_Tail; --------------------- -- Super_To_String -- --------------------- function Super_To_String (Source : Super_String) return Wide_String is begin return R : Wide_String (1 .. Source.Current_Length) do R := Source.Data (1 .. Source.Current_Length); end return; end Super_To_String; --------------------- -- Super_Translate -- --------------------- function Super_Translate (Source : Super_String; Mapping : Wide_Maps.Wide_Character_Mapping) return Super_String is Result : Super_String (Source.Max_Length); begin Result.Current_Length := Source.Current_Length; for J in 1 .. Source.Current_Length loop Result.Data (J) := Value (Mapping, Source.Data (J)); end loop; return Result; end Super_Translate; procedure Super_Translate (Source : in out Super_String; Mapping : Wide_Maps.Wide_Character_Mapping) is begin for J in 1 .. Source.Current_Length loop Source.Data (J) := Value (Mapping, Source.Data (J)); end loop; end Super_Translate; function Super_Translate (Source : Super_String; Mapping : Wide_Maps.Wide_Character_Mapping_Function) return Super_String is Result : Super_String (Source.Max_Length); begin Result.Current_Length := Source.Current_Length; for J in 1 .. Source.Current_Length loop Result.Data (J) := Mapping.all (Source.Data (J)); end loop; return Result; end Super_Translate; procedure Super_Translate (Source : in out Super_String; Mapping : Wide_Maps.Wide_Character_Mapping_Function) is begin for J in 1 .. Source.Current_Length loop Source.Data (J) := Mapping.all (Source.Data (J)); end loop; end Super_Translate; ---------------- -- Super_Trim -- ---------------- function Super_Trim (Source : Super_String; Side : Trim_End) return Super_String is Result : Super_String (Source.Max_Length); Last : Natural := Source.Current_Length; First : Positive := 1; begin if Side = Left or else Side = Both then while First <= Last and then Source.Data (First) = ' ' loop First := First + 1; end loop; end if; if Side = Right or else Side = Both then while Last >= First and then Source.Data (Last) = ' ' loop Last := Last - 1; end loop; end if; Result.Current_Length := Last - First + 1; Result.Data (1 .. Result.Current_Length) := Source.Data (First .. Last); return Result; end Super_Trim; procedure Super_Trim (Source : in out Super_String; Side : Trim_End) is Max_Length : constant Positive := Source.Max_Length; Last : Natural := Source.Current_Length; First : Positive := 1; Temp : Wide_String (1 .. Max_Length); begin Temp (1 .. Last) := Source.Data (1 .. Last); if Side = Left or else Side = Both then while First <= Last and then Temp (First) = ' ' loop First := First + 1; end loop; end if; if Side = Right or else Side = Both then while Last >= First and then Temp (Last) = ' ' loop Last := Last - 1; end loop; end if; Source.Data := (others => Wide_NUL); Source.Current_Length := Last - First + 1; Source.Data (1 .. Source.Current_Length) := Temp (First .. Last); end Super_Trim; function Super_Trim (Source : Super_String; Left : Wide_Maps.Wide_Character_Set; Right : Wide_Maps.Wide_Character_Set) return Super_String is Result : Super_String (Source.Max_Length); begin for First in 1 .. Source.Current_Length loop if not Is_In (Source.Data (First), Left) then for Last in reverse First .. Source.Current_Length loop if not Is_In (Source.Data (Last), Right) then Result.Current_Length := Last - First + 1; Result.Data (1 .. Result.Current_Length) := Source.Data (First .. Last); return Result; end if; end loop; end if; end loop; Result.Current_Length := 0; return Result; end Super_Trim; procedure Super_Trim (Source : in out Super_String; Left : Wide_Maps.Wide_Character_Set; Right : Wide_Maps.Wide_Character_Set) is begin for First in 1 .. Source.Current_Length loop if not Is_In (Source.Data (First), Left) then for Last in reverse First .. Source.Current_Length loop if not Is_In (Source.Data (Last), Right) then if First = 1 then Source.Current_Length := Last; return; else Source.Current_Length := Last - First + 1; Source.Data (1 .. Source.Current_Length) := Source.Data (First .. Last); for J in Source.Current_Length + 1 .. Source.Max_Length loop Source.Data (J) := Wide_NUL; end loop; return; end if; end if; end loop; Source.Current_Length := 0; return; end if; end loop; Source.Current_Length := 0; end Super_Trim; ----------- -- Times -- ----------- function Times (Left : Natural; Right : Wide_Character; Max_Length : Positive) return Super_String is Result : Super_String (Max_Length); begin if Left > Max_Length then raise Ada.Strings.Length_Error; else Result.Current_Length := Left; for J in 1 .. Left loop Result.Data (J) := Right; end loop; end if; return Result; end Times; function Times (Left : Natural; Right : Wide_String; Max_Length : Positive) return Super_String is Result : Super_String (Max_Length); Pos : Positive := 1; Rlen : constant Natural := Right'Length; Nlen : constant Natural := Left * Rlen; begin if Nlen > Max_Length then raise Ada.Strings.Index_Error; else Result.Current_Length := Nlen; if Nlen > 0 then for J in 1 .. Left loop Result.Data (Pos .. Pos + Rlen - 1) := Right; Pos := Pos + Rlen; end loop; end if; end if; return Result; end Times; function Times (Left : Natural; Right : Super_String) return Super_String is Result : Super_String (Right.Max_Length); Pos : Positive := 1; Rlen : constant Natural := Right.Current_Length; Nlen : constant Natural := Left * Rlen; begin if Nlen > Right.Max_Length then raise Ada.Strings.Length_Error; else Result.Current_Length := Nlen; if Nlen > 0 then for J in 1 .. Left loop Result.Data (Pos .. Pos + Rlen - 1) := Right.Data (1 .. Rlen); Pos := Pos + Rlen; end loop; end if; end if; return Result; end Times; --------------------- -- To_Super_String -- --------------------- function To_Super_String (Source : Wide_String; Max_Length : Natural; Drop : Truncation := Error) return Super_String is Result : Super_String (Max_Length); Slen : constant Natural := Source'Length; begin if Slen <= Max_Length then Result.Current_Length := Slen; Result.Data (1 .. Slen) := Source; else case Drop is when Strings.Right => Result.Current_Length := Max_Length; Result.Data (1 .. Max_Length) := Source (Source'First .. Source'First - 1 + Max_Length); when Strings.Left => Result.Current_Length := Max_Length; Result.Data (1 .. Max_Length) := Source (Source'Last - (Max_Length - 1) .. Source'Last); when Strings.Error => raise Ada.Strings.Length_Error; end case; end if; return Result; end To_Super_String; end Ada.Strings.Wide_Superbounded;
package formal_procedure_declaration is generic with procedure Put_Line; procedure SS_Info; end formal_procedure_declaration;
package Giza.Bitmap_Fonts.FreeSerifItalic24pt7b is Font : constant Giza.Font.Ref_Const; private FreeSerifItalic24pt7bBitmaps : aliased constant Font_Bitmap := ( 16#00#, 16#F0#, 16#0F#, 16#00#, 16#F0#, 16#0F#, 16#01#, 16#F0#, 16#1E#, 16#01#, 16#E0#, 16#1C#, 16#01#, 16#C0#, 16#3C#, 16#03#, 16#80#, 16#38#, 16#03#, 16#80#, 16#30#, 16#07#, 16#00#, 16#60#, 16#06#, 16#00#, 16#60#, 16#04#, 16#00#, 16#40#, 16#0C#, 16#00#, 16#80#, 16#08#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#07#, 16#00#, 16#F8#, 16#0F#, 16#80#, 16#F8#, 16#07#, 16#00#, 16#38#, 16#1D#, 16#E0#, 16#77#, 16#83#, 16#DC#, 16#0E#, 16#70#, 16#39#, 16#C1#, 16#EE#, 16#07#, 16#38#, 16#1C#, 16#C0#, 16#63#, 16#01#, 16#8C#, 16#06#, 16#20#, 16#10#, 16#00#, 16#06#, 16#03#, 16#00#, 16#07#, 16#03#, 16#80#, 16#03#, 16#81#, 16#C0#, 16#03#, 16#81#, 16#C0#, 16#01#, 16#C0#, 16#E0#, 16#00#, 16#E0#, 16#70#, 16#00#, 16#E0#, 16#70#, 16#00#, 16#70#, 16#38#, 16#00#, 16#30#, 16#18#, 16#00#, 16#38#, 16#1C#, 16#03#, 16#FF#, 16#FF#, 16#E1#, 16#FF#, 16#FF#, 16#F0#, 16#0E#, 16#07#, 16#00#, 16#06#, 16#03#, 16#00#, 16#07#, 16#03#, 16#80#, 16#03#, 16#81#, 16#C0#, 16#03#, 16#81#, 16#C0#, 16#01#, 16#C0#, 16#E0#, 16#00#, 16#E0#, 16#70#, 16#1F#, 16#FF#, 16#FF#, 16#8F#, 16#FF#, 16#FF#, 16#80#, 16#70#, 16#38#, 16#00#, 16#38#, 16#1C#, 16#00#, 16#18#, 16#0C#, 16#00#, 16#1C#, 16#0E#, 16#00#, 16#0E#, 16#07#, 16#00#, 16#0E#, 16#07#, 16#00#, 16#07#, 16#03#, 16#80#, 16#03#, 16#81#, 16#C0#, 16#03#, 16#81#, 16#C0#, 16#01#, 16#C0#, 16#E0#, 16#00#, 16#00#, 16#01#, 16#00#, 16#00#, 16#18#, 16#00#, 16#00#, 16#C0#, 16#00#, 16#FF#, 16#80#, 16#1C#, 16#2F#, 16#01#, 16#81#, 16#3C#, 16#1C#, 16#18#, 16#E1#, 16#C0#, 16#C3#, 16#0E#, 16#06#, 16#18#, 16#70#, 16#60#, 16#83#, 16#83#, 16#04#, 16#1E#, 16#18#, 16#00#, 16#F8#, 16#C0#, 16#03#, 16#EC#, 16#00#, 16#0F#, 16#E0#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#FC#, 16#00#, 16#03#, 16#F0#, 16#00#, 16#0F#, 16#C0#, 16#00#, 16#7F#, 16#00#, 16#03#, 16#7C#, 16#00#, 16#19#, 16#E0#, 16#01#, 16#87#, 16#80#, 16#0C#, 16#3C#, 16#00#, 16#60#, 16#E2#, 16#03#, 16#07#, 16#10#, 16#30#, 16#39#, 16#81#, 16#81#, 16#CE#, 16#0C#, 16#0C#, 16#70#, 16#60#, 16#E3#, 16#C6#, 16#06#, 16#0F#, 16#30#, 16#60#, 16#1F#, 16#9E#, 16#00#, 16#3F#, 16#80#, 16#00#, 16#C0#, 16#00#, 16#06#, 16#00#, 16#00#, 16#30#, 16#00#, 16#01#, 16#80#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#C0#, 16#03#, 16#FE#, 16#01#, 16#C0#, 16#03#, 16#C7#, 16#83#, 16#E0#, 16#03#, 16#C0#, 16#7F#, 16#60#, 16#03#, 16#C0#, 16#20#, 16#70#, 16#01#, 16#C0#, 16#10#, 16#30#, 16#01#, 16#E0#, 16#08#, 16#38#, 16#00#, 16#E0#, 16#04#, 16#18#, 16#00#, 16#F0#, 16#02#, 16#18#, 16#00#, 16#70#, 16#02#, 16#0C#, 16#00#, 16#38#, 16#01#, 16#0C#, 16#00#, 16#1C#, 16#01#, 16#8E#, 16#00#, 16#0E#, 16#00#, 16#86#, 16#00#, 16#07#, 16#00#, 16#87#, 16#03#, 16#E1#, 16#80#, 16#C3#, 16#07#, 16#FC#, 16#E1#, 16#C3#, 16#07#, 16#C6#, 16#3F#, 16#81#, 16#87#, 16#81#, 16#8F#, 16#81#, 16#87#, 16#80#, 16#40#, 16#00#, 16#C3#, 16#C0#, 16#20#, 16#00#, 16#C3#, 16#C0#, 16#10#, 16#00#, 16#61#, 16#C0#, 16#08#, 16#00#, 16#61#, 16#E0#, 16#04#, 16#00#, 16#70#, 16#F0#, 16#06#, 16#00#, 16#30#, 16#70#, 16#02#, 16#00#, 16#30#, 16#38#, 16#03#, 16#00#, 16#18#, 16#1C#, 16#01#, 16#00#, 16#18#, 16#0E#, 16#01#, 16#80#, 16#0C#, 16#07#, 16#01#, 16#80#, 16#0C#, 16#01#, 16#C3#, 16#80#, 16#06#, 16#00#, 16#7F#, 16#80#, 16#06#, 16#00#, 16#1F#, 16#00#, 16#06#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#00#, 16#71#, 16#C0#, 16#00#, 16#01#, 16#C3#, 16#80#, 16#00#, 16#0E#, 16#0E#, 16#00#, 16#00#, 16#38#, 16#38#, 16#00#, 16#01#, 16#E0#, 16#E0#, 16#00#, 16#07#, 16#87#, 16#00#, 16#00#, 16#1E#, 16#18#, 16#00#, 16#00#, 16#78#, 16#C0#, 16#00#, 16#01#, 16#E6#, 16#00#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#07#, 16#E0#, 16#00#, 16#00#, 16#7F#, 16#C1#, 16#FE#, 16#03#, 16#9F#, 16#03#, 16#E0#, 16#3C#, 16#3C#, 16#07#, 16#01#, 16#E0#, 16#F8#, 16#1C#, 16#0F#, 16#03#, 16#E0#, 16#E0#, 16#7C#, 16#07#, 16#83#, 16#01#, 16#E0#, 16#1F#, 16#1C#, 16#07#, 16#80#, 16#7C#, 16#60#, 16#3E#, 16#00#, 16#FB#, 16#00#, 16#F8#, 16#03#, 16#FC#, 16#03#, 16#E0#, 16#07#, 16#E0#, 16#0F#, 16#80#, 16#1F#, 16#00#, 16#3F#, 16#00#, 16#3E#, 16#00#, 16#7C#, 16#00#, 16#FC#, 16#01#, 16#F8#, 16#0F#, 16#F0#, 16#03#, 16#F0#, 16#F3#, 16#F0#, 16#87#, 16#FF#, 16#07#, 16#FC#, 16#07#, 16#F0#, 16#07#, 16#C0#, 16#39#, 16#DE#, 16#E7#, 16#3B#, 16#9C#, 16#C6#, 16#31#, 16#00#, 16#00#, 16#10#, 16#01#, 16#00#, 16#18#, 16#01#, 16#80#, 16#18#, 16#01#, 16#80#, 16#1C#, 16#00#, 16#C0#, 16#0E#, 16#00#, 16#E0#, 16#07#, 16#00#, 16#78#, 16#03#, 16#80#, 16#3C#, 16#01#, 16#E0#, 16#0E#, 16#00#, 16#70#, 16#07#, 16#80#, 16#3C#, 16#01#, 16#E0#, 16#0E#, 16#00#, 16#70#, 16#03#, 16#80#, 16#1C#, 16#00#, 16#E0#, 16#07#, 16#00#, 16#38#, 16#01#, 16#C0#, 16#0E#, 16#00#, 16#30#, 16#01#, 16#80#, 16#0C#, 16#00#, 16#60#, 16#01#, 16#80#, 16#0C#, 16#00#, 16#60#, 16#01#, 16#00#, 16#0C#, 16#00#, 16#20#, 16#00#, 16#00#, 16#80#, 16#06#, 16#00#, 16#10#, 16#00#, 16#80#, 16#06#, 16#00#, 16#30#, 16#00#, 16#C0#, 16#06#, 16#00#, 16#30#, 16#01#, 16#80#, 16#0C#, 16#00#, 16#70#, 16#03#, 16#80#, 16#1C#, 16#00#, 16#E0#, 16#07#, 16#00#, 16#38#, 16#01#, 16#C0#, 16#1E#, 16#00#, 16#F0#, 16#07#, 16#80#, 16#3C#, 16#01#, 16#C0#, 16#1E#, 16#00#, 16#F0#, 16#07#, 16#80#, 16#38#, 16#03#, 16#C0#, 16#1C#, 16#00#, 16#E0#, 16#0E#, 16#00#, 16#60#, 16#07#, 16#00#, 16#30#, 16#03#, 16#00#, 16#30#, 16#03#, 16#00#, 16#10#, 16#01#, 16#00#, 16#00#, 16#01#, 16#00#, 16#03#, 16#80#, 16#03#, 16#80#, 16#03#, 16#80#, 16#03#, 16#80#, 16#E1#, 16#07#, 16#E1#, 16#0F#, 16#F1#, 16#1F#, 16#19#, 16#30#, 16#07#, 16#C0#, 16#03#, 16#80#, 16#0D#, 16#60#, 16#79#, 16#3C#, 16#F1#, 16#1F#, 16#E1#, 16#0F#, 16#E1#, 16#07#, 16#03#, 16#80#, 16#03#, 16#80#, 16#03#, 16#80#, 16#03#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#70#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#03#, 16#80#, 16#00#, 16#07#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#70#, 16#03#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#E0#, 16#07#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#70#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#03#, 16#80#, 16#00#, 16#07#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#1C#, 16#7C#, 16#F9#, 16#F1#, 16#E1#, 16#C3#, 16#0C#, 16#10#, 16#C1#, 16#00#, 16#7F#, 16#FF#, 16#FF#, 16#FF#, 16#00#, 16#77#, 16#FF#, 16#F7#, 16#00#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#80#, 16#00#, 16#3C#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#80#, 16#00#, 16#3C#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#70#, 16#00#, 16#07#, 16#80#, 16#00#, 16#38#, 16#00#, 16#03#, 16#80#, 16#00#, 16#3C#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#70#, 16#00#, 16#07#, 16#80#, 16#00#, 16#38#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#1C#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#00#, 16#1F#, 16#80#, 16#03#, 16#86#, 16#00#, 16#30#, 16#18#, 16#03#, 16#00#, 16#C0#, 16#38#, 16#03#, 16#03#, 16#80#, 16#18#, 16#38#, 16#00#, 16#C1#, 16#C0#, 16#07#, 16#1C#, 16#00#, 16#38#, 16#E0#, 16#01#, 16#CF#, 16#00#, 16#0E#, 16#70#, 16#00#, 16#77#, 16#80#, 16#07#, 16#BC#, 16#00#, 16#3D#, 16#E0#, 16#01#, 16#EE#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#77#, 16#80#, 16#07#, 16#BC#, 16#00#, 16#3D#, 16#C0#, 16#01#, 16#CE#, 16#00#, 16#1E#, 16#70#, 16#00#, 16#F3#, 16#80#, 16#07#, 16#1C#, 16#00#, 16#78#, 16#E0#, 16#03#, 16#83#, 16#00#, 16#38#, 16#18#, 16#03#, 16#80#, 16#E0#, 16#18#, 16#03#, 16#01#, 16#80#, 16#0C#, 16#38#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#00#, 16#00#, 16#80#, 16#1F#, 16#C0#, 16#3F#, 16#E0#, 16#01#, 16#F0#, 16#00#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#3C#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#0F#, 16#00#, 16#07#, 16#00#, 16#03#, 16#80#, 16#03#, 16#C0#, 16#01#, 16#E0#, 16#00#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#38#, 16#00#, 16#1C#, 16#00#, 16#1E#, 16#00#, 16#0F#, 16#00#, 16#07#, 16#00#, 16#07#, 16#80#, 16#03#, 16#C0#, 16#01#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#3C#, 16#00#, 16#3C#, 16#00#, 16#3F#, 16#01#, 16#FF#, 16#F0#, 16#00#, 16#3F#, 16#00#, 16#07#, 16#FE#, 16#00#, 16#7F#, 16#F8#, 16#07#, 16#07#, 16#E0#, 16#60#, 16#1F#, 16#06#, 16#00#, 16#7C#, 16#20#, 16#01#, 16#E0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#1C#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#70#, 16#00#, 16#07#, 16#00#, 16#00#, 16#70#, 16#00#, 16#03#, 16#00#, 16#00#, 16#30#, 16#00#, 16#03#, 16#00#, 16#00#, 16#30#, 16#00#, 16#03#, 16#00#, 16#00#, 16#30#, 16#00#, 16#03#, 16#00#, 16#00#, 16#30#, 16#01#, 16#03#, 16#00#, 16#08#, 16#30#, 16#00#, 16#C3#, 16#FF#, 16#FC#, 16#3F#, 16#FF#, 16#E3#, 16#FF#, 16#FE#, 16#00#, 16#00#, 16#0F#, 16#C0#, 16#00#, 16#FF#, 16#C0#, 16#06#, 16#0F#, 16#80#, 16#30#, 16#1E#, 16#01#, 16#80#, 16#3C#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#78#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#0E#, 16#00#, 16#01#, 16#F8#, 16#00#, 16#3F#, 16#F8#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#78#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#07#, 16#80#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#70#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#C0#, 16#70#, 16#06#, 16#03#, 16#F8#, 16#70#, 16#07#, 16#FF#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#00#, 16#00#, 16#0C#, 16#00#, 16#00#, 16#30#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#17#, 16#80#, 16#00#, 16#DC#, 16#00#, 16#06#, 16#70#, 16#00#, 16#33#, 16#C0#, 16#01#, 16#8E#, 16#00#, 16#0C#, 16#38#, 16#00#, 16#60#, 16#E0#, 16#03#, 16#07#, 16#80#, 16#18#, 16#1C#, 16#00#, 16#C0#, 16#70#, 16#06#, 16#03#, 16#C0#, 16#30#, 16#0E#, 16#01#, 16#80#, 16#38#, 16#0C#, 16#00#, 16#E0#, 16#70#, 16#07#, 16#81#, 16#FF#, 16#FF#, 16#EF#, 16#FF#, 16#FF#, 16#BF#, 16#FF#, 16#FE#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#07#, 16#80#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#70#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#3F#, 16#FC#, 16#00#, 16#FF#, 16#F0#, 16#07#, 16#FF#, 16#80#, 16#10#, 16#00#, 16#00#, 16#40#, 16#00#, 16#02#, 16#00#, 16#00#, 16#08#, 16#00#, 16#00#, 16#70#, 16#00#, 16#01#, 16#F8#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#3F#, 16#F0#, 16#00#, 16#1F#, 16#E0#, 16#00#, 16#1F#, 16#80#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#78#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#03#, 16#80#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#03#, 16#80#, 16#00#, 16#0C#, 16#00#, 16#00#, 16#70#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#06#, 16#00#, 16#00#, 16#30#, 16#00#, 16#01#, 16#80#, 16#70#, 16#0E#, 16#03#, 16#F0#, 16#E0#, 16#07#, 16#FF#, 16#00#, 16#0F#, 16#E0#, 16#00#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#F9#, 16#F8#, 16#01#, 16#FF#, 16#FC#, 16#07#, 16#E0#, 16#7C#, 16#0F#, 16#80#, 16#7C#, 16#3E#, 16#00#, 16#78#, 16#78#, 16#00#, 16#78#, 16#F0#, 16#00#, 16#F3#, 16#C0#, 16#01#, 16#E7#, 16#80#, 16#03#, 16#CF#, 16#00#, 16#07#, 16#9C#, 16#00#, 16#0F#, 16#38#, 16#00#, 16#3E#, 16#70#, 16#00#, 16#78#, 16#E0#, 16#00#, 16#F1#, 16#C0#, 16#03#, 16#C1#, 16#80#, 16#07#, 16#83#, 16#00#, 16#1E#, 16#03#, 16#00#, 16#38#, 16#06#, 16#01#, 16#E0#, 16#03#, 16#07#, 16#00#, 16#01#, 16#F8#, 16#00#, 16#1F#, 16#FF#, 16#F9#, 16#FF#, 16#FF#, 16#CF#, 16#FF#, 16#FC#, 16#E0#, 16#00#, 16#CC#, 16#00#, 16#0E#, 16#40#, 16#00#, 16#60#, 16#00#, 16#07#, 16#00#, 16#00#, 16#70#, 16#00#, 16#03#, 16#80#, 16#00#, 16#38#, 16#00#, 16#01#, 16#80#, 16#00#, 16#1C#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#70#, 16#00#, 16#07#, 16#00#, 16#00#, 16#38#, 16#00#, 16#03#, 16#80#, 16#00#, 16#1C#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#70#, 16#00#, 16#07#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#80#, 16#00#, 16#38#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#00#, 16#3F#, 16#80#, 16#03#, 16#83#, 16#80#, 16#1C#, 16#03#, 16#00#, 16#E0#, 16#0E#, 16#07#, 16#00#, 16#1C#, 16#1C#, 16#00#, 16#70#, 16#70#, 16#01#, 16#C1#, 16#C0#, 16#07#, 16#07#, 16#80#, 16#1C#, 16#1E#, 16#00#, 16#E0#, 16#3C#, 16#07#, 16#80#, 16#FC#, 16#38#, 16#01#, 16#FB#, 16#C0#, 16#03#, 16#F8#, 16#00#, 16#0F#, 16#E0#, 16#00#, 16#7F#, 16#C0#, 16#07#, 16#1F#, 16#80#, 16#78#, 16#3F#, 16#03#, 16#80#, 16#7C#, 16#1E#, 16#00#, 16#F8#, 16#70#, 16#01#, 16#E3#, 16#80#, 16#03#, 16#CE#, 16#00#, 16#07#, 16#38#, 16#00#, 16#1C#, 16#E0#, 16#00#, 16#73#, 16#80#, 16#01#, 16#CE#, 16#00#, 16#06#, 16#1C#, 16#00#, 16#38#, 16#70#, 16#01#, 16#C0#, 16#E0#, 16#0E#, 16#01#, 16#E0#, 16#E0#, 16#01#, 16#FE#, 16#00#, 16#00#, 16#1F#, 16#80#, 16#03#, 16#C3#, 16#00#, 16#1C#, 16#02#, 16#00#, 16#E0#, 16#0C#, 16#07#, 16#00#, 16#18#, 16#3C#, 16#00#, 16#60#, 16#E0#, 16#01#, 16#C7#, 16#80#, 16#07#, 16#1E#, 16#00#, 16#1C#, 16#F0#, 16#00#, 16#73#, 16#C0#, 16#01#, 16#CF#, 16#00#, 16#07#, 16#3C#, 16#00#, 16#3C#, 16#F0#, 16#00#, 16#F3#, 16#C0#, 16#03#, 16#CF#, 16#00#, 16#1E#, 16#1E#, 16#00#, 16#78#, 16#7C#, 16#03#, 16#E0#, 16#F8#, 16#3F#, 16#01#, 16#FF#, 16#BC#, 16#03#, 16#F1#, 16#E0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#3C#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#7C#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#78#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#07#, 16#07#, 16#C3#, 16#E1#, 16#F0#, 16#70#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#38#, 16#3E#, 16#1F#, 16#0F#, 16#83#, 16#80#, 16#01#, 16#C0#, 16#7C#, 16#0F#, 16#81#, 16#F0#, 16#1C#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#18#, 16#07#, 16#80#, 16#F8#, 16#1F#, 16#01#, 16#E0#, 16#1C#, 16#03#, 16#00#, 16#C0#, 16#18#, 16#04#, 16#01#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#0C#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#3F#, 16#C0#, 16#01#, 16#FC#, 16#00#, 16#0F#, 16#E0#, 16#00#, 16#FF#, 16#00#, 16#07#, 16#F8#, 16#00#, 16#3F#, 16#C0#, 16#01#, 16#FC#, 16#00#, 16#07#, 16#E0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#1F#, 16#80#, 16#00#, 16#3F#, 16#C0#, 16#00#, 16#1F#, 16#E0#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#03#, 16#F8#, 16#00#, 16#01#, 16#FE#, 16#00#, 16#00#, 16#FF#, 16#00#, 16#00#, 16#7F#, 16#80#, 16#00#, 16#1F#, 16#C0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#07#, 16#00#, 16#00#, 16#02#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#80#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#FE#, 16#00#, 16#00#, 16#3F#, 16#80#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#03#, 16#FC#, 16#00#, 16#00#, 16#FF#, 16#00#, 16#00#, 16#1F#, 16#C0#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#01#, 16#FE#, 16#00#, 16#00#, 16#7F#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#FE#, 16#00#, 16#03#, 16#F8#, 16#00#, 16#1F#, 16#E0#, 16#00#, 16#7F#, 16#80#, 16#01#, 16#FC#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#3F#, 16#C0#, 16#00#, 16#FF#, 16#00#, 16#00#, 16#FC#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#80#, 16#00#, 16#00#, 16#03#, 16#F0#, 16#06#, 16#1C#, 16#0C#, 16#0E#, 16#1C#, 16#06#, 16#1C#, 16#07#, 16#1C#, 16#07#, 16#1C#, 16#07#, 16#00#, 16#07#, 16#00#, 16#0F#, 16#00#, 16#0E#, 16#00#, 16#1E#, 16#00#, 16#3C#, 16#00#, 16#38#, 16#00#, 16#70#, 16#00#, 16#E0#, 16#01#, 16#C0#, 16#03#, 16#80#, 16#03#, 16#00#, 16#06#, 16#00#, 16#04#, 16#00#, 16#08#, 16#00#, 16#08#, 16#00#, 16#08#, 16#00#, 16#10#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#70#, 16#00#, 16#F8#, 16#00#, 16#F8#, 16#00#, 16#F8#, 16#00#, 16#70#, 16#00#, 16#00#, 16#07#, 16#FC#, 16#00#, 16#00#, 16#1F#, 16#FF#, 16#80#, 16#00#, 16#3F#, 16#01#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#1E#, 16#00#, 16#7C#, 16#00#, 16#07#, 16#80#, 16#7C#, 16#00#, 16#00#, 16#E0#, 16#3C#, 16#00#, 16#00#, 16#38#, 16#3C#, 16#00#, 16#00#, 16#0C#, 16#3C#, 16#00#, 16#78#, 16#07#, 16#1E#, 16#00#, 16#FE#, 16#E1#, 16#9E#, 16#00#, 16#F1#, 16#F0#, 16#EF#, 16#00#, 16#E0#, 16#F0#, 16#37#, 16#80#, 16#E0#, 16#38#, 16#1F#, 16#80#, 16#70#, 16#1C#, 16#0F#, 16#C0#, 16#70#, 16#1E#, 16#07#, 16#E0#, 16#38#, 16#0E#, 16#03#, 16#F0#, 16#18#, 16#07#, 16#01#, 16#F8#, 16#1C#, 16#03#, 16#80#, 16#FC#, 16#0E#, 16#01#, 16#C0#, 16#DE#, 16#07#, 16#01#, 16#C0#, 16#6F#, 16#03#, 16#80#, 16#E0#, 16#73#, 16#C1#, 16#C0#, 16#F0#, 16#31#, 16#E0#, 16#F0#, 16#F8#, 16#30#, 16#F0#, 16#38#, 16#DC#, 16#30#, 16#3C#, 16#1F#, 16#C7#, 16#F0#, 16#0E#, 16#07#, 16#81#, 16#F0#, 16#07#, 16#80#, 16#00#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#01#, 16#00#, 16#03#, 16#F0#, 16#0F#, 16#80#, 16#00#, 16#7F#, 16#FF#, 16#00#, 16#00#, 16#07#, 16#FC#, 16#00#, 16#00#, 16#00#, 16#00#, 16#18#, 16#00#, 16#00#, 16#00#, 16#C0#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#00#, 16#7E#, 16#00#, 16#00#, 16#03#, 16#F0#, 16#00#, 16#00#, 16#37#, 16#80#, 16#00#, 16#01#, 16#3C#, 16#00#, 16#00#, 16#19#, 16#F0#, 16#00#, 16#01#, 16#8F#, 16#80#, 16#00#, 16#08#, 16#7C#, 16#00#, 16#00#, 16#C3#, 16#E0#, 16#00#, 16#04#, 16#0F#, 16#00#, 16#00#, 16#60#, 16#7C#, 16#00#, 16#06#, 16#03#, 16#E0#, 16#00#, 16#20#, 16#1F#, 16#00#, 16#03#, 16#00#, 16#F8#, 16#00#, 16#3F#, 16#FF#, 16#C0#, 16#01#, 16#FF#, 16#FE#, 16#00#, 16#18#, 16#00#, 16#F8#, 16#00#, 16#C0#, 16#07#, 16#C0#, 16#0C#, 16#00#, 16#3E#, 16#00#, 16#E0#, 16#01#, 16#F0#, 16#06#, 16#00#, 16#0F#, 16#80#, 16#70#, 16#00#, 16#3E#, 16#03#, 16#00#, 16#01#, 16#E0#, 16#38#, 16#00#, 16#0F#, 16#83#, 16#C0#, 16#00#, 16#7C#, 16#3E#, 16#00#, 16#07#, 16#F3#, 16#FC#, 16#01#, 16#FF#, 16#E0#, 16#03#, 16#FF#, 16#FE#, 16#00#, 16#07#, 16#FF#, 16#F8#, 16#00#, 16#3E#, 16#07#, 16#C0#, 16#03#, 16#E0#, 16#3E#, 16#00#, 16#3E#, 16#01#, 16#F0#, 16#03#, 16#C0#, 16#1F#, 16#00#, 16#3C#, 16#01#, 16#F0#, 16#07#, 16#C0#, 16#1F#, 16#00#, 16#78#, 16#01#, 16#F0#, 16#07#, 16#80#, 16#3E#, 16#00#, 16#78#, 16#03#, 16#E0#, 16#0F#, 16#80#, 16#7C#, 16#00#, 16#F0#, 16#3F#, 16#00#, 16#0F#, 16#FF#, 16#80#, 16#01#, 16#FF#, 16#FC#, 16#00#, 16#1F#, 16#07#, 16#E0#, 16#01#, 16#E0#, 16#1F#, 16#00#, 16#1E#, 16#00#, 16#F8#, 16#03#, 16#E0#, 16#07#, 16#C0#, 16#3C#, 16#00#, 16#7C#, 16#03#, 16#C0#, 16#07#, 16#C0#, 16#7C#, 16#00#, 16#7C#, 16#07#, 16#C0#, 16#07#, 16#C0#, 16#78#, 16#00#, 16#7C#, 16#0F#, 16#80#, 16#0F#, 16#80#, 16#F8#, 16#00#, 16#F8#, 16#0F#, 16#00#, 16#1F#, 16#00#, 16#F0#, 16#03#, 16#E0#, 16#1F#, 16#81#, 16#FC#, 16#03#, 16#FF#, 16#FF#, 16#80#, 16#FF#, 16#FF#, 16#C0#, 16#00#, 16#00#, 16#01#, 16#FE#, 16#04#, 16#00#, 16#3F#, 16#FF#, 16#E0#, 16#03#, 16#F0#, 16#1F#, 16#80#, 16#1F#, 16#00#, 16#3E#, 16#00#, 16#F0#, 16#00#, 16#78#, 16#0F#, 16#80#, 16#00#, 16#E0#, 16#3C#, 16#00#, 16#03#, 16#81#, 16#F0#, 16#00#, 16#04#, 16#0F#, 16#80#, 16#00#, 16#10#, 16#7C#, 16#00#, 16#00#, 16#41#, 16#F0#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#02#, 16#07#, 16#C0#, 16#00#, 16#18#, 16#0F#, 16#80#, 16#00#, 16#C0#, 16#3E#, 16#00#, 16#06#, 16#00#, 16#7C#, 16#00#, 16#70#, 16#00#, 16#FC#, 16#07#, 16#00#, 16#00#, 16#FF#, 16#F8#, 16#00#, 16#00#, 16#FF#, 16#00#, 16#00#, 16#03#, 16#FF#, 16#FF#, 16#00#, 16#00#, 16#3F#, 16#FF#, 16#E0#, 16#00#, 16#0F#, 16#C0#, 16#FC#, 16#00#, 16#07#, 16#C0#, 16#1F#, 16#00#, 16#03#, 16#E0#, 16#07#, 16#C0#, 16#01#, 16#E0#, 16#01#, 16#F0#, 16#00#, 16#F0#, 16#00#, 16#7C#, 16#00#, 16#F8#, 16#00#, 16#3E#, 16#00#, 16#7C#, 16#00#, 16#0F#, 16#00#, 16#3C#, 16#00#, 16#07#, 16#C0#, 16#1E#, 16#00#, 16#03#, 16#E0#, 16#1F#, 16#00#, 16#01#, 16#F0#, 16#0F#, 16#00#, 16#00#, 16#F8#, 16#07#, 16#80#, 16#00#, 16#7C#, 16#07#, 16#C0#, 16#00#, 16#3E#, 16#03#, 16#C0#, 16#00#, 16#1F#, 16#01#, 16#E0#, 16#00#, 16#1F#, 16#80#, 16#F0#, 16#00#, 16#0F#, 16#80#, 16#F8#, 16#00#, 16#07#, 16#C0#, 16#78#, 16#00#, 16#03#, 16#E0#, 16#3C#, 16#00#, 16#03#, 16#E0#, 16#3E#, 16#00#, 16#01#, 16#F0#, 16#1E#, 16#00#, 16#01#, 16#F0#, 16#0F#, 16#00#, 16#01#, 16#F0#, 16#0F#, 16#80#, 16#01#, 16#F8#, 16#07#, 16#C0#, 16#01#, 16#F0#, 16#03#, 16#E0#, 16#01#, 16#F0#, 16#01#, 16#E0#, 16#03#, 16#F0#, 16#01#, 16#F8#, 16#0F#, 16#E0#, 16#01#, 16#FF#, 16#FF#, 16#C0#, 16#03#, 16#FF#, 16#FE#, 16#00#, 16#00#, 16#03#, 16#FF#, 16#FF#, 16#F8#, 16#03#, 16#FF#, 16#FF#, 16#C0#, 16#0F#, 16#80#, 16#1E#, 16#00#, 16#7C#, 16#00#, 16#30#, 16#03#, 16#E0#, 16#01#, 16#00#, 16#1E#, 16#00#, 16#08#, 16#00#, 16#F0#, 16#00#, 16#40#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#10#, 16#00#, 16#1E#, 16#01#, 16#80#, 16#01#, 16#F0#, 16#08#, 16#00#, 16#0F#, 16#01#, 16#C0#, 16#00#, 16#7F#, 16#FE#, 16#00#, 16#07#, 16#FF#, 16#F0#, 16#00#, 16#3E#, 16#07#, 16#00#, 16#01#, 16#E0#, 16#18#, 16#00#, 16#0F#, 16#00#, 16#C0#, 16#00#, 16#F8#, 16#04#, 16#00#, 16#07#, 16#80#, 16#20#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#08#, 16#0F#, 16#80#, 16#00#, 16#C0#, 16#7C#, 16#00#, 16#0E#, 16#03#, 16#C0#, 16#00#, 16#E0#, 16#1E#, 16#00#, 16#0F#, 16#01#, 16#F8#, 16#03#, 16#F8#, 16#1F#, 16#FF#, 16#FF#, 16#83#, 16#FF#, 16#FF#, 16#FC#, 16#00#, 16#03#, 16#FF#, 16#FF#, 16#F8#, 16#03#, 16#FF#, 16#FF#, 16#C0#, 16#0F#, 16#80#, 16#1E#, 16#00#, 16#7C#, 16#00#, 16#30#, 16#03#, 16#E0#, 16#01#, 16#00#, 16#1E#, 16#00#, 16#08#, 16#00#, 16#F0#, 16#00#, 16#40#, 16#0F#, 16#80#, 16#02#, 16#00#, 16#78#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#80#, 16#01#, 16#F0#, 16#0C#, 16#00#, 16#0F#, 16#00#, 16#C0#, 16#00#, 16#78#, 16#0E#, 16#00#, 16#07#, 16#FF#, 16#F0#, 16#00#, 16#3F#, 16#FF#, 16#00#, 16#01#, 16#E0#, 16#18#, 16#00#, 16#0F#, 16#00#, 16#C0#, 16#00#, 16#F8#, 16#06#, 16#00#, 16#07#, 16#80#, 16#20#, 16#00#, 16#3C#, 16#01#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#00#, 16#1F#, 16#C0#, 16#00#, 16#03#, 16#FF#, 16#C0#, 16#00#, 16#00#, 16#00#, 16#01#, 16#FE#, 16#02#, 16#00#, 16#1F#, 16#FF#, 16#8C#, 16#00#, 16#FC#, 16#07#, 16#F8#, 16#03#, 16#E0#, 16#03#, 16#F0#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#3C#, 16#00#, 16#03#, 16#80#, 16#F0#, 16#00#, 16#07#, 16#03#, 16#C0#, 16#00#, 16#0E#, 16#0F#, 16#80#, 16#00#, 16#08#, 16#3E#, 16#00#, 16#00#, 16#10#, 16#7C#, 16#00#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#00#, 16#FC#, 16#00#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#3F#, 16#FF#, 16#E0#, 16#00#, 16#0F#, 16#E7#, 16#C0#, 16#00#, 16#0F#, 16#0F#, 16#80#, 16#00#, 16#1E#, 16#1F#, 16#00#, 16#00#, 16#7C#, 16#3E#, 16#00#, 16#00#, 16#F0#, 16#7C#, 16#00#, 16#01#, 16#E0#, 16#78#, 16#00#, 16#03#, 16#C0#, 16#F8#, 16#00#, 16#0F#, 16#01#, 16#F0#, 16#00#, 16#1E#, 16#01#, 16#F0#, 16#00#, 16#3C#, 16#01#, 16#E0#, 16#00#, 16#F8#, 16#01#, 16#F0#, 16#03#, 16#E0#, 16#01#, 16#F8#, 16#0F#, 16#80#, 16#00#, 16#FF#, 16#FC#, 16#00#, 16#00#, 16#7F#, 16#C0#, 16#00#, 16#03#, 16#FF#, 16#E0#, 16#7F#, 16#F0#, 16#07#, 16#F8#, 16#01#, 16#FC#, 16#00#, 16#3E#, 16#00#, 16#0F#, 16#80#, 16#03#, 16#E0#, 16#00#, 16#F8#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#07#, 16#C0#, 16#01#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#1E#, 16#00#, 16#07#, 16#80#, 16#01#, 16#E0#, 16#00#, 16#78#, 16#00#, 16#3E#, 16#00#, 16#0F#, 16#80#, 16#03#, 16#C0#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#01#, 16#FF#, 16#FF#, 16#FC#, 16#00#, 16#1F#, 16#FF#, 16#FF#, 16#80#, 16#01#, 16#E0#, 16#00#, 16#78#, 16#00#, 16#1E#, 16#00#, 16#07#, 16#80#, 16#03#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#F0#, 16#00#, 16#7C#, 16#00#, 16#1F#, 16#00#, 16#07#, 16#80#, 16#01#, 16#E0#, 16#00#, 16#78#, 16#00#, 16#1E#, 16#00#, 16#0F#, 16#80#, 16#03#, 16#E0#, 16#00#, 16#F8#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#1F#, 16#00#, 16#07#, 16#C0#, 16#03#, 16#F8#, 16#00#, 16#FE#, 16#00#, 16#FF#, 16#E0#, 16#7F#, 16#FC#, 16#00#, 16#01#, 16#FF#, 16#C0#, 16#1F#, 16#E0#, 16#03#, 16#E0#, 16#00#, 16#F8#, 16#00#, 16#3E#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#01#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#1E#, 16#00#, 16#07#, 16#80#, 16#03#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#1F#, 16#00#, 16#07#, 16#80#, 16#01#, 16#E0#, 16#00#, 16#78#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#01#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#1E#, 16#00#, 16#0F#, 16#80#, 16#03#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#1F#, 16#00#, 16#0F#, 16#E0#, 16#0F#, 16#FE#, 16#00#, 16#00#, 16#1F#, 16#FE#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#78#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#07#, 16#80#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#07#, 16#80#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#F0#, 16#01#, 16#C1#, 16#E0#, 16#07#, 16#C7#, 16#80#, 16#0F#, 16#8F#, 16#00#, 16#1F#, 16#3C#, 16#00#, 16#1F#, 16#F0#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#01#, 16#FF#, 16#E1#, 16#FF#, 16#80#, 16#3F#, 16#C0#, 16#1F#, 16#80#, 16#0F#, 16#80#, 16#0F#, 16#00#, 16#07#, 16#C0#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#0F#, 16#00#, 16#01#, 16#E0#, 16#0E#, 16#00#, 16#00#, 16#F0#, 16#0E#, 16#00#, 16#00#, 16#F8#, 16#0C#, 16#00#, 16#00#, 16#78#, 16#1C#, 16#00#, 16#00#, 16#3C#, 16#1C#, 16#00#, 16#00#, 16#1E#, 16#38#, 16#00#, 16#00#, 16#1E#, 16#38#, 16#00#, 16#00#, 16#0F#, 16#38#, 16#00#, 16#00#, 16#07#, 16#F8#, 16#00#, 16#00#, 16#07#, 16#FE#, 16#00#, 16#00#, 16#03#, 16#DF#, 16#00#, 16#00#, 16#01#, 16#E7#, 16#C0#, 16#00#, 16#00#, 16#F3#, 16#E0#, 16#00#, 16#00#, 16#F8#, 16#F8#, 16#00#, 16#00#, 16#78#, 16#3E#, 16#00#, 16#00#, 16#3C#, 16#1F#, 16#00#, 16#00#, 16#3E#, 16#07#, 16#C0#, 16#00#, 16#1F#, 16#03#, 16#E0#, 16#00#, 16#0F#, 16#00#, 16#F8#, 16#00#, 16#07#, 16#80#, 16#3E#, 16#00#, 16#07#, 16#C0#, 16#1F#, 16#00#, 16#03#, 16#C0#, 16#07#, 16#C0#, 16#01#, 16#E0#, 16#03#, 16#E0#, 16#01#, 16#F0#, 16#01#, 16#F8#, 16#01#, 16#FC#, 16#01#, 16#FE#, 16#03#, 16#FF#, 16#C3#, 16#FF#, 16#E0#, 16#03#, 16#FF#, 16#E0#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#00#, 16#FC#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#08#, 16#3C#, 16#00#, 16#03#, 16#0F#, 16#80#, 16#00#, 16#41#, 16#F0#, 16#00#, 16#18#, 16#3C#, 16#00#, 16#07#, 16#07#, 16#80#, 16#01#, 16#C1#, 16#F8#, 16#01#, 16#F8#, 16#7F#, 16#FF#, 16#FF#, 16#3F#, 16#FF#, 16#FF#, 16#C0#, 16#01#, 16#FF#, 16#00#, 16#00#, 16#3F#, 16#C0#, 16#0F#, 16#C0#, 16#00#, 16#1F#, 16#C0#, 16#01#, 16#F0#, 16#00#, 16#07#, 16#E0#, 16#00#, 16#FC#, 16#00#, 16#03#, 16#F0#, 16#00#, 16#3F#, 16#00#, 16#01#, 16#FC#, 16#00#, 16#0F#, 16#C0#, 16#00#, 16#7F#, 16#00#, 16#02#, 16#F0#, 16#00#, 16#37#, 16#80#, 16#01#, 16#BC#, 16#00#, 16#19#, 16#E0#, 16#00#, 16#6F#, 16#80#, 16#0E#, 16#78#, 16#00#, 16#1B#, 16#E0#, 16#03#, 16#3E#, 16#00#, 16#04#, 16#78#, 16#01#, 16#8F#, 16#00#, 16#03#, 16#1E#, 16#00#, 16#E3#, 16#C0#, 16#00#, 16#C7#, 16#80#, 16#31#, 16#F0#, 16#00#, 16#21#, 16#E0#, 16#18#, 16#78#, 16#00#, 16#18#, 16#78#, 16#0E#, 16#1E#, 16#00#, 16#06#, 16#1E#, 16#03#, 16#07#, 16#80#, 16#01#, 16#87#, 16#81#, 16#83#, 16#C0#, 16#00#, 16#41#, 16#F0#, 16#E0#, 16#F0#, 16#00#, 16#30#, 16#7C#, 16#30#, 16#3C#, 16#00#, 16#0C#, 16#0F#, 16#18#, 16#1F#, 16#00#, 16#03#, 16#03#, 16#CE#, 16#07#, 16#80#, 16#01#, 16#80#, 16#F3#, 16#01#, 16#E0#, 16#00#, 16#60#, 16#3D#, 16#80#, 16#F8#, 16#00#, 16#18#, 16#0F#, 16#E0#, 16#3C#, 16#00#, 16#0C#, 16#03#, 16#F0#, 16#0F#, 16#00#, 16#03#, 16#00#, 16#F8#, 16#03#, 16#C0#, 16#00#, 16#C0#, 16#3E#, 16#01#, 16#F0#, 16#00#, 16#70#, 16#0F#, 16#00#, 16#7C#, 16#00#, 16#1C#, 16#01#, 16#80#, 16#3F#, 16#00#, 16#0F#, 16#80#, 16#60#, 16#1F#, 16#C0#, 16#0F#, 16#F8#, 16#10#, 16#1F#, 16#FE#, 16#00#, 16#03#, 16#FC#, 16#00#, 16#3F#, 16#E0#, 16#1F#, 16#C0#, 16#01#, 16#F8#, 16#00#, 16#F8#, 16#00#, 16#1C#, 16#00#, 16#1F#, 16#00#, 16#03#, 16#80#, 16#03#, 16#F0#, 16#00#, 16#60#, 16#00#, 16#7E#, 16#00#, 16#0C#, 16#00#, 16#0B#, 16#E0#, 16#03#, 16#80#, 16#03#, 16#7C#, 16#00#, 16#60#, 16#00#, 16#6F#, 16#80#, 16#0C#, 16#00#, 16#0C#, 16#F8#, 16#03#, 16#80#, 16#03#, 16#1F#, 16#00#, 16#70#, 16#00#, 16#61#, 16#F0#, 16#0C#, 16#00#, 16#0C#, 16#3E#, 16#01#, 16#80#, 16#01#, 16#83#, 16#C0#, 16#70#, 16#00#, 16#60#, 16#7C#, 16#0C#, 16#00#, 16#0C#, 16#0F#, 16#81#, 16#80#, 16#01#, 16#80#, 16#F8#, 16#30#, 16#00#, 16#60#, 16#1F#, 16#0E#, 16#00#, 16#0C#, 16#01#, 16#E1#, 16#80#, 16#01#, 16#80#, 16#3E#, 16#30#, 16#00#, 16#30#, 16#03#, 16#CE#, 16#00#, 16#0C#, 16#00#, 16#7D#, 16#80#, 16#01#, 16#80#, 16#0F#, 16#B0#, 16#00#, 16#30#, 16#00#, 16#F6#, 16#00#, 16#0E#, 16#00#, 16#1F#, 16#C0#, 16#01#, 16#80#, 16#01#, 16#F0#, 16#00#, 16#30#, 16#00#, 16#3E#, 16#00#, 16#0E#, 16#00#, 16#03#, 16#C0#, 16#01#, 16#C0#, 16#00#, 16#70#, 16#00#, 16#7C#, 16#00#, 16#06#, 16#00#, 16#3F#, 16#E0#, 16#00#, 16#C0#, 16#00#, 16#00#, 16#00#, 16#18#, 16#00#, 16#00#, 16#00#, 16#FE#, 16#00#, 16#00#, 16#1F#, 16#FE#, 16#00#, 16#01#, 16#F0#, 16#7C#, 16#00#, 16#0F#, 16#00#, 16#78#, 16#00#, 16#78#, 16#00#, 16#F0#, 16#07#, 16#C0#, 16#03#, 16#E0#, 16#3E#, 16#00#, 16#07#, 16#81#, 16#F0#, 16#00#, 16#1E#, 16#07#, 16#C0#, 16#00#, 16#7C#, 16#3E#, 16#00#, 16#01#, 16#F1#, 16#F0#, 16#00#, 16#07#, 16#C7#, 16#C0#, 16#00#, 16#1F#, 16#3F#, 16#00#, 16#00#, 16#7C#, 16#F8#, 16#00#, 16#01#, 16#F7#, 16#E0#, 16#00#, 16#0F#, 16#DF#, 16#00#, 16#00#, 16#3F#, 16#7C#, 16#00#, 16#00#, 16#FB#, 16#F0#, 16#00#, 16#07#, 16#EF#, 16#C0#, 16#00#, 16#1F#, 16#BE#, 16#00#, 16#00#, 16#7C#, 16#F8#, 16#00#, 16#03#, 16#F3#, 16#E0#, 16#00#, 16#0F#, 16#8F#, 16#80#, 16#00#, 16#3E#, 16#3E#, 16#00#, 16#01#, 16#F0#, 16#F8#, 16#00#, 16#0F#, 16#81#, 16#E0#, 16#00#, 16#3E#, 16#07#, 16#80#, 16#01#, 16#F0#, 16#1F#, 16#00#, 16#0F#, 16#80#, 16#3C#, 16#00#, 16#7C#, 16#00#, 16#78#, 16#03#, 16#C0#, 16#00#, 16#F8#, 16#3E#, 16#00#, 16#01#, 16#FF#, 16#E0#, 16#00#, 16#01#, 16#FC#, 16#00#, 16#00#, 16#03#, 16#FF#, 16#FE#, 16#00#, 16#03#, 16#FF#, 16#FE#, 16#00#, 16#0F#, 16#81#, 16#F8#, 16#00#, 16#7C#, 16#03#, 16#E0#, 16#03#, 16#E0#, 16#1F#, 16#00#, 16#1E#, 16#00#, 16#7C#, 16#01#, 16#F0#, 16#03#, 16#E0#, 16#0F#, 16#80#, 16#1F#, 16#00#, 16#78#, 16#00#, 16#F8#, 16#03#, 16#C0#, 16#07#, 16#C0#, 16#1E#, 16#00#, 16#3C#, 16#01#, 16#E0#, 16#03#, 16#E0#, 16#0F#, 16#00#, 16#3E#, 16#00#, 16#78#, 16#03#, 16#F0#, 16#07#, 16#C0#, 16#7E#, 16#00#, 16#3F#, 16#FF#, 16#E0#, 16#01#, 16#EF#, 16#F8#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#07#, 16#80#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#00#, 16#1F#, 16#C0#, 16#00#, 16#03#, 16#FF#, 16#80#, 16#00#, 16#00#, 16#00#, 16#00#, 16#FE#, 16#00#, 16#00#, 16#1F#, 16#FE#, 16#00#, 16#00#, 16#F0#, 16#7C#, 16#00#, 16#0F#, 16#00#, 16#78#, 16#00#, 16#78#, 16#00#, 16#F0#, 16#03#, 16#C0#, 16#03#, 16#E0#, 16#1E#, 16#00#, 16#07#, 16#80#, 16#F0#, 16#00#, 16#1E#, 16#07#, 16#C0#, 16#00#, 16#7C#, 16#3E#, 16#00#, 16#01#, 16#F1#, 16#F8#, 16#00#, 16#07#, 16#C7#, 16#C0#, 16#00#, 16#1F#, 16#3F#, 16#00#, 16#00#, 16#7C#, 16#F8#, 16#00#, 16#01#, 16#F7#, 16#E0#, 16#00#, 16#0F#, 16#DF#, 16#80#, 16#00#, 16#3F#, 16#7C#, 16#00#, 16#00#, 16#FB#, 16#F0#, 16#00#, 16#03#, 16#EF#, 16#C0#, 16#00#, 16#1F#, 16#BE#, 16#00#, 16#00#, 16#7C#, 16#F8#, 16#00#, 16#01#, 16#F3#, 16#E0#, 16#00#, 16#0F#, 16#8F#, 16#80#, 16#00#, 16#3E#, 16#3E#, 16#00#, 16#01#, 16#F0#, 16#F8#, 16#00#, 16#07#, 16#C3#, 16#E0#, 16#00#, 16#3E#, 16#07#, 16#80#, 16#01#, 16#F0#, 16#1F#, 16#00#, 16#07#, 16#80#, 16#3C#, 16#00#, 16#3C#, 16#00#, 16#F8#, 16#01#, 16#E0#, 16#01#, 16#E0#, 16#1E#, 16#00#, 16#01#, 16#F3#, 16#E0#, 16#00#, 16#01#, 16#FE#, 16#00#, 16#00#, 16#03#, 16#00#, 16#00#, 16#00#, 16#18#, 16#00#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#04#, 16#0F#, 16#F0#, 16#00#, 16#60#, 16#7F#, 16#FC#, 16#07#, 16#03#, 16#FF#, 16#FF#, 16#F8#, 16#38#, 16#1F#, 16#FF#, 16#80#, 16#00#, 16#07#, 16#F8#, 16#00#, 16#03#, 16#FF#, 16#FE#, 16#00#, 16#07#, 16#FF#, 16#F8#, 16#00#, 16#3E#, 16#0F#, 16#C0#, 16#03#, 16#E0#, 16#3E#, 16#00#, 16#3E#, 16#01#, 16#F0#, 16#03#, 16#C0#, 16#1F#, 16#00#, 16#3C#, 16#01#, 16#F0#, 16#07#, 16#C0#, 16#1F#, 16#00#, 16#78#, 16#01#, 16#F0#, 16#07#, 16#80#, 16#3E#, 16#00#, 16#78#, 16#03#, 16#E0#, 16#0F#, 16#80#, 16#7C#, 16#00#, 16#F0#, 16#1F#, 16#80#, 16#0F#, 16#FF#, 16#E0#, 16#01#, 16#FF#, 16#F0#, 16#00#, 16#1E#, 16#3E#, 16#00#, 16#01#, 16#E1#, 16#E0#, 16#00#, 16#1E#, 16#1F#, 16#00#, 16#03#, 16#E0#, 16#F0#, 16#00#, 16#3C#, 16#0F#, 16#80#, 16#03#, 16#C0#, 16#F8#, 16#00#, 16#7C#, 16#07#, 16#80#, 16#07#, 16#80#, 16#7C#, 16#00#, 16#78#, 16#07#, 16#C0#, 16#0F#, 16#80#, 16#3C#, 16#00#, 16#F8#, 16#03#, 16#E0#, 16#0F#, 16#00#, 16#1E#, 16#00#, 16#F0#, 16#01#, 16#E0#, 16#1F#, 16#00#, 16#1F#, 16#03#, 16#F8#, 16#00#, 16#F8#, 16#FF#, 16#E0#, 16#0F#, 16#E0#, 16#00#, 16#3F#, 16#06#, 16#01#, 16#FF#, 16#DC#, 16#07#, 16#C1#, 16#F0#, 16#1E#, 16#01#, 16#E0#, 16#3C#, 16#01#, 16#C0#, 16#F0#, 16#03#, 16#81#, 16#E0#, 16#03#, 16#03#, 16#C0#, 16#04#, 16#07#, 16#80#, 16#08#, 16#0F#, 16#80#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#7E#, 16#00#, 16#00#, 16#7C#, 16#08#, 16#00#, 16#78#, 16#10#, 16#00#, 16#F0#, 16#20#, 16#01#, 16#E0#, 16#C0#, 16#03#, 16#C1#, 16#80#, 16#07#, 16#83#, 16#80#, 16#1E#, 16#07#, 16#00#, 16#3C#, 16#0F#, 16#00#, 16#F0#, 16#1F#, 16#87#, 16#C0#, 16#23#, 16#FF#, 16#00#, 16#81#, 16#F8#, 16#00#, 16#3F#, 16#FF#, 16#FF#, 16#E7#, 16#FF#, 16#FF#, 16#FD#, 16#F0#, 16#3E#, 16#07#, 16#B8#, 16#07#, 16#C0#, 16#76#, 16#00#, 16#F0#, 16#04#, 16#80#, 16#3E#, 16#00#, 16#B0#, 16#07#, 16#C0#, 16#14#, 16#00#, 16#F8#, 16#02#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#3F#, 16#C0#, 16#00#, 16#3F#, 16#FF#, 16#00#, 16#00#, 16#7F#, 16#FE#, 16#03#, 16#FE#, 16#1F#, 16#E0#, 16#01#, 16#F8#, 16#1F#, 16#80#, 16#01#, 16#C0#, 16#3E#, 16#00#, 16#03#, 16#80#, 16#7C#, 16#00#, 16#07#, 16#00#, 16#F8#, 16#00#, 16#0C#, 16#01#, 16#E0#, 16#00#, 16#18#, 16#07#, 16#C0#, 16#00#, 16#70#, 16#0F#, 16#80#, 16#00#, 16#C0#, 16#1F#, 16#00#, 16#01#, 16#80#, 16#7C#, 16#00#, 16#03#, 16#00#, 16#F8#, 16#00#, 16#0C#, 16#01#, 16#F0#, 16#00#, 16#18#, 16#07#, 16#C0#, 16#00#, 16#30#, 16#0F#, 16#80#, 16#00#, 16#60#, 16#1F#, 16#00#, 16#01#, 16#80#, 16#3E#, 16#00#, 16#03#, 16#00#, 16#F8#, 16#00#, 16#06#, 16#01#, 16#F0#, 16#00#, 16#18#, 16#03#, 16#E0#, 16#00#, 16#30#, 16#07#, 16#C0#, 16#00#, 16#60#, 16#1F#, 16#00#, 16#00#, 16#C0#, 16#3E#, 16#00#, 16#03#, 16#00#, 16#7C#, 16#00#, 16#06#, 16#00#, 16#F8#, 16#00#, 16#18#, 16#01#, 16#F0#, 16#00#, 16#30#, 16#03#, 16#E0#, 16#00#, 16#C0#, 16#03#, 16#E0#, 16#03#, 16#80#, 16#03#, 16#E0#, 16#0E#, 16#00#, 16#03#, 16#F0#, 16#78#, 16#00#, 16#03#, 16#FF#, 16#C0#, 16#00#, 16#01#, 16#FE#, 16#00#, 16#00#, 16#FF#, 16#E0#, 16#0F#, 16#F9#, 16#FC#, 16#00#, 16#1F#, 16#07#, 16#C0#, 16#00#, 16#78#, 16#3E#, 16#00#, 16#03#, 16#81#, 16#F0#, 16#00#, 16#18#, 16#0F#, 16#80#, 16#01#, 16#C0#, 16#7C#, 16#00#, 16#0C#, 16#01#, 16#E0#, 16#00#, 16#C0#, 16#0F#, 16#80#, 16#06#, 16#00#, 16#7C#, 16#00#, 16#60#, 16#03#, 16#E0#, 16#07#, 16#00#, 16#1F#, 16#00#, 16#30#, 16#00#, 16#F8#, 16#03#, 16#00#, 16#03#, 16#C0#, 16#18#, 16#00#, 16#1F#, 16#01#, 16#80#, 16#00#, 16#F8#, 16#18#, 16#00#, 16#07#, 16#C0#, 16#C0#, 16#00#, 16#3E#, 16#0C#, 16#00#, 16#01#, 16#F0#, 16#60#, 16#00#, 16#07#, 16#86#, 16#00#, 16#00#, 16#3E#, 16#20#, 16#00#, 16#01#, 16#F3#, 16#00#, 16#00#, 16#0F#, 16#B0#, 16#00#, 16#00#, 16#7D#, 16#00#, 16#00#, 16#03#, 16#F8#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#06#, 16#00#, 16#00#, 16#00#, 16#20#, 16#00#, 16#00#, 16#FF#, 16#E3#, 16#FF#, 16#81#, 16#FE#, 16#7F#, 16#01#, 16#FC#, 16#00#, 16#F8#, 16#7C#, 16#01#, 16#F0#, 16#00#, 16#E0#, 16#F8#, 16#03#, 16#E0#, 16#01#, 16#81#, 16#F0#, 16#03#, 16#C0#, 16#07#, 16#03#, 16#E0#, 16#07#, 16#80#, 16#0C#, 16#03#, 16#C0#, 16#0F#, 16#00#, 16#18#, 16#07#, 16#80#, 16#1E#, 16#00#, 16#60#, 16#1F#, 16#00#, 16#7E#, 16#00#, 16#C0#, 16#1F#, 16#00#, 16#FC#, 16#03#, 16#00#, 16#3E#, 16#03#, 16#F8#, 16#06#, 16#00#, 16#7C#, 16#05#, 16#F0#, 16#18#, 16#00#, 16#F8#, 16#1B#, 16#E0#, 16#30#, 16#01#, 16#F0#, 16#33#, 16#C0#, 16#C0#, 16#03#, 16#E0#, 16#C7#, 16#83#, 16#80#, 16#07#, 16#C1#, 16#8F#, 16#06#, 16#00#, 16#07#, 16#86#, 16#1E#, 16#1C#, 16#00#, 16#0F#, 16#8C#, 16#3C#, 16#30#, 16#00#, 16#1F#, 16#30#, 16#7C#, 16#E0#, 16#00#, 16#3E#, 16#60#, 16#F9#, 16#80#, 16#00#, 16#7D#, 16#81#, 16#F7#, 16#00#, 16#00#, 16#FB#, 16#03#, 16#EC#, 16#00#, 16#01#, 16#FC#, 16#03#, 16#F8#, 16#00#, 16#03#, 16#F8#, 16#07#, 16#E0#, 16#00#, 16#03#, 16#E0#, 16#0F#, 16#80#, 16#00#, 16#07#, 16#C0#, 16#1F#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#78#, 16#00#, 16#00#, 16#38#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#70#, 16#01#, 16#C0#, 16#00#, 16#00#, 16#C0#, 16#03#, 16#00#, 16#00#, 16#00#, 16#80#, 16#06#, 16#00#, 16#00#, 16#07#, 16#FF#, 16#83#, 16#FF#, 16#01#, 16#FE#, 16#00#, 16#FE#, 16#00#, 16#7C#, 16#00#, 16#78#, 16#00#, 16#7C#, 16#00#, 16#70#, 16#00#, 16#7C#, 16#00#, 16#E0#, 16#00#, 16#3E#, 16#00#, 16#C0#, 16#00#, 16#3E#, 16#01#, 16#80#, 16#00#, 16#1F#, 16#03#, 16#00#, 16#00#, 16#1F#, 16#07#, 16#00#, 16#00#, 16#1F#, 16#0E#, 16#00#, 16#00#, 16#0F#, 16#9C#, 16#00#, 16#00#, 16#0F#, 16#B8#, 16#00#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#00#, 16#07#, 16#E0#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#00#, 16#1C#, 16#F0#, 16#00#, 16#00#, 16#38#, 16#F8#, 16#00#, 16#00#, 16#30#, 16#F8#, 16#00#, 16#00#, 16#60#, 16#7C#, 16#00#, 16#00#, 16#C0#, 16#7C#, 16#00#, 16#01#, 16#80#, 16#3C#, 16#00#, 16#03#, 16#80#, 16#3E#, 16#00#, 16#07#, 16#00#, 16#3E#, 16#00#, 16#0E#, 16#00#, 16#1F#, 16#00#, 16#1E#, 16#00#, 16#1F#, 16#00#, 16#7F#, 16#00#, 16#3F#, 16#C0#, 16#FF#, 16#C1#, 16#FF#, 16#F0#, 16#7F#, 16#F0#, 16#7F#, 16#C7#, 16#F0#, 16#03#, 16#E0#, 16#F8#, 16#00#, 16#70#, 16#3E#, 16#00#, 16#38#, 16#07#, 16#80#, 16#0C#, 16#01#, 16#E0#, 16#07#, 16#00#, 16#7C#, 16#03#, 16#80#, 16#1F#, 16#00#, 16#C0#, 16#03#, 16#C0#, 16#60#, 16#00#, 16#F0#, 16#30#, 16#00#, 16#3E#, 16#18#, 16#00#, 16#07#, 16#8E#, 16#00#, 16#01#, 16#E3#, 16#00#, 16#00#, 16#7D#, 16#80#, 16#00#, 16#1F#, 16#C0#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#3E#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#0F#, 16#C0#, 16#00#, 16#07#, 16#F0#, 16#00#, 16#0F#, 16#FF#, 16#C0#, 16#00#, 16#03#, 16#FF#, 16#FF#, 16#F8#, 16#1F#, 16#FF#, 16#FF#, 16#81#, 16#F0#, 16#00#, 16#FC#, 16#0E#, 16#00#, 16#0F#, 16#C0#, 16#60#, 16#00#, 16#FC#, 16#06#, 16#00#, 16#0F#, 16#C0#, 16#20#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#07#, 16#E0#, 16#00#, 16#00#, 16#7E#, 16#00#, 16#00#, 16#07#, 16#E0#, 16#00#, 16#00#, 16#7E#, 16#00#, 16#00#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#03#, 16#F0#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#00#, 16#03#, 16#F0#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#00#, 16#01#, 16#F8#, 16#00#, 16#00#, 16#1F#, 16#80#, 16#00#, 16#01#, 16#F8#, 16#00#, 16#00#, 16#1F#, 16#80#, 16#00#, 16#00#, 16#F8#, 16#00#, 16#00#, 16#0F#, 16#C0#, 16#00#, 16#00#, 16#FC#, 16#00#, 16#08#, 16#0F#, 16#C0#, 16#00#, 16#80#, 16#FC#, 16#00#, 16#0C#, 16#07#, 16#C0#, 16#00#, 16#60#, 16#7E#, 16#00#, 16#07#, 16#07#, 16#E0#, 16#01#, 16#F0#, 16#7F#, 16#FF#, 16#FF#, 16#83#, 16#FF#, 16#FF#, 16#FC#, 16#00#, 16#00#, 16#3F#, 16#80#, 16#3C#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#07#, 16#00#, 16#03#, 16#80#, 16#01#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#E0#, 16#00#, 16#70#, 16#00#, 16#38#, 16#00#, 16#1C#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#80#, 16#03#, 16#80#, 16#01#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#70#, 16#00#, 16#70#, 16#00#, 16#38#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#80#, 16#01#, 16#C0#, 16#01#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#70#, 16#00#, 16#38#, 16#00#, 16#38#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#07#, 16#80#, 16#03#, 16#FC#, 16#00#, 16#F0#, 16#00#, 16#38#, 16#00#, 16#1E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#80#, 16#01#, 16#E0#, 16#00#, 16#70#, 16#00#, 16#3C#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#78#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#03#, 16#80#, 16#01#, 16#C0#, 16#00#, 16#F0#, 16#00#, 16#38#, 16#00#, 16#1E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#80#, 16#01#, 16#E0#, 16#00#, 16#70#, 16#00#, 16#3C#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#78#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#80#, 16#00#, 16#FF#, 16#80#, 16#07#, 16#80#, 16#01#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#70#, 16#00#, 16#30#, 16#00#, 16#38#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#06#, 16#00#, 16#03#, 16#00#, 16#03#, 16#80#, 16#01#, 16#C0#, 16#00#, 16#C0#, 16#00#, 16#60#, 16#00#, 16#70#, 16#00#, 16#38#, 16#00#, 16#18#, 16#00#, 16#0C#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#00#, 16#01#, 16#80#, 16#01#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#60#, 16#00#, 16#30#, 16#00#, 16#38#, 16#00#, 16#1C#, 16#00#, 16#0C#, 16#00#, 16#06#, 16#00#, 16#07#, 16#00#, 16#03#, 16#80#, 16#01#, 16#80#, 16#00#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#70#, 16#00#, 16#30#, 16#03#, 16#F8#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#0F#, 16#00#, 16#01#, 16#F8#, 16#00#, 16#1F#, 16#80#, 16#03#, 16#BC#, 16#00#, 16#39#, 16#C0#, 16#07#, 16#1E#, 16#00#, 16#70#, 16#E0#, 16#0E#, 16#0F#, 16#00#, 16#E0#, 16#70#, 16#1C#, 16#07#, 16#81#, 16#C0#, 16#38#, 16#38#, 16#03#, 16#C3#, 16#80#, 16#1C#, 16#70#, 16#01#, 16#E7#, 16#00#, 16#0E#, 16#E0#, 16#00#, 16#F0#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#60#, 16#F0#, 16#F8#, 16#78#, 16#3C#, 16#1E#, 16#0E#, 16#07#, 16#00#, 16#1E#, 16#70#, 16#03#, 16#0B#, 16#80#, 16#70#, 16#3C#, 16#07#, 16#01#, 16#E0#, 16#70#, 16#0E#, 16#07#, 16#00#, 16#70#, 16#78#, 16#03#, 16#83#, 16#80#, 16#38#, 16#3C#, 16#01#, 16#C1#, 16#C0#, 16#0E#, 16#1E#, 16#00#, 16#F0#, 16#F0#, 16#07#, 16#0F#, 16#00#, 16#78#, 16#78#, 16#03#, 16#C3#, 16#C0#, 16#3E#, 16#1E#, 16#01#, 16#70#, 16#F0#, 16#17#, 16#0F#, 16#81#, 16#38#, 16#BE#, 16#11#, 16#C8#, 16#FF#, 16#0F#, 16#83#, 16#F0#, 16#70#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#7F#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#80#, 16#00#, 16#1C#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#0E#, 16#0F#, 16#80#, 16#71#, 16#FE#, 16#03#, 16#98#, 16#F8#, 16#3D#, 16#03#, 16#E1#, 16#C8#, 16#0F#, 16#0E#, 16#80#, 16#78#, 16#78#, 16#03#, 16#C7#, 16#C0#, 16#1E#, 16#3C#, 16#00#, 16#F1#, 16#E0#, 16#0F#, 16#1E#, 16#00#, 16#78#, 16#F0#, 16#03#, 16#C7#, 16#80#, 16#3C#, 16#38#, 16#01#, 16#E3#, 16#C0#, 16#1E#, 16#1E#, 16#00#, 16#E0#, 16#E0#, 16#0E#, 16#07#, 16#00#, 16#F0#, 16#78#, 16#07#, 16#03#, 16#C0#, 16#E0#, 16#0F#, 16#0E#, 16#00#, 16#1F#, 16#80#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#38#, 16#60#, 16#38#, 16#1C#, 16#1C#, 16#0F#, 16#0E#, 16#03#, 16#87#, 16#80#, 16#03#, 16#C0#, 16#00#, 16#E0#, 16#00#, 16#78#, 16#00#, 16#1E#, 16#00#, 16#07#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#F0#, 16#02#, 16#3E#, 16#01#, 16#87#, 16#80#, 16#C1#, 16#F0#, 16#60#, 16#3F#, 16#F0#, 16#03#, 16#F0#, 16#00#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#FE#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#78#, 16#00#, 16#1E#, 16#78#, 16#00#, 16#71#, 16#70#, 16#00#, 16#C1#, 16#70#, 16#03#, 16#80#, 16#F0#, 16#07#, 16#80#, 16#E0#, 16#07#, 16#01#, 16#E0#, 16#0E#, 16#01#, 16#E0#, 16#1E#, 16#01#, 16#E0#, 16#3C#, 16#01#, 16#C0#, 16#3C#, 16#01#, 16#C0#, 16#78#, 16#03#, 16#C0#, 16#78#, 16#03#, 16#C0#, 16#78#, 16#03#, 16#80#, 16#F0#, 16#07#, 16#80#, 16#F0#, 16#07#, 16#80#, 16#F0#, 16#0F#, 16#80#, 16#F0#, 16#0F#, 16#00#, 16#F0#, 16#17#, 16#08#, 16#F0#, 16#27#, 16#10#, 16#78#, 16#47#, 16#20#, 16#7F#, 16#87#, 16#C0#, 16#1E#, 16#07#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#1C#, 16#F0#, 16#1C#, 16#1C#, 16#0E#, 16#07#, 16#07#, 16#01#, 16#C3#, 16#C0#, 16#F1#, 16#E0#, 16#38#, 16#70#, 16#1C#, 16#3C#, 16#0E#, 16#1F#, 16#0F#, 16#07#, 16#8F#, 16#01#, 16#FE#, 16#00#, 16#F0#, 16#00#, 16#3C#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#F0#, 16#01#, 16#3C#, 16#00#, 16#C7#, 16#80#, 16#61#, 16#F0#, 16#60#, 16#3F#, 16#F0#, 16#03#, 16#E0#, 16#00#, 16#00#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#03#, 16#1C#, 16#00#, 16#00#, 16#C3#, 16#80#, 16#00#, 16#38#, 16#70#, 16#00#, 16#06#, 16#00#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#00#, 16#30#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#07#, 16#FF#, 16#C0#, 16#00#, 16#FF#, 16#F8#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#07#, 16#00#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#3C#, 16#00#, 16#00#, 16#07#, 16#80#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#07#, 16#80#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#03#, 16#80#, 16#00#, 16#00#, 16#70#, 16#00#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#03#, 16#80#, 16#00#, 16#00#, 16#70#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#70#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#00#, 16#70#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#01#, 16#80#, 16#00#, 16#38#, 16#60#, 16#00#, 16#07#, 16#0C#, 16#00#, 16#00#, 16#E3#, 16#00#, 16#00#, 16#0F#, 16#80#, 16#00#, 16#00#, 16#00#, 16#3F#, 16#00#, 16#07#, 16#0E#, 16#00#, 16#70#, 16#3E#, 16#07#, 16#01#, 16#F0#, 16#70#, 16#0E#, 16#07#, 16#80#, 16#70#, 16#3C#, 16#03#, 16#81#, 16#C0#, 16#1C#, 16#0E#, 16#01#, 16#E0#, 16#70#, 16#0E#, 16#03#, 16#80#, 16#F0#, 16#0E#, 16#0F#, 16#00#, 16#30#, 16#E0#, 16#00#, 16#FE#, 16#00#, 16#0C#, 16#00#, 16#00#, 16#C0#, 16#00#, 16#0E#, 16#00#, 16#00#, 16#7E#, 16#00#, 16#03#, 16#FE#, 16#00#, 16#0F#, 16#FC#, 16#00#, 16#8F#, 16#F0#, 16#18#, 16#0F#, 16#C1#, 16#80#, 16#1F#, 16#18#, 16#00#, 16#78#, 16#C0#, 16#01#, 16#C6#, 16#00#, 16#0E#, 16#30#, 16#00#, 16#61#, 16#C0#, 16#07#, 16#06#, 16#00#, 16#70#, 16#1C#, 16#0E#, 16#00#, 16#3F#, 16#C0#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#7F#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#80#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#07#, 16#03#, 16#80#, 16#70#, 16#7E#, 16#03#, 16#86#, 16#70#, 16#1C#, 16#43#, 16#81#, 16#E4#, 16#1C#, 16#0E#, 16#40#, 16#E0#, 16#74#, 16#0E#, 16#03#, 16#A0#, 16#70#, 16#3A#, 16#03#, 16#81#, 16#E0#, 16#1C#, 16#0F#, 16#00#, 16#E0#, 16#70#, 16#0E#, 16#07#, 16#80#, 16#70#, 16#38#, 16#03#, 16#81#, 16#C0#, 16#1C#, 16#1E#, 16#00#, 16#C2#, 16#F0#, 16#0E#, 16#27#, 16#00#, 16#73#, 16#38#, 16#03#, 16#93#, 16#C0#, 16#1F#, 16#1E#, 16#00#, 16#E0#, 16#03#, 16#81#, 16#F0#, 16#7C#, 16#1F#, 16#03#, 16#80#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#71#, 16#FC#, 16#1F#, 16#07#, 16#81#, 16#E0#, 16#78#, 16#1C#, 16#07#, 16#03#, 16#C0#, 16#F0#, 16#38#, 16#0E#, 16#07#, 16#81#, 16#E0#, 16#70#, 16#1C#, 16#0F#, 16#03#, 16#84#, 16#E2#, 16#39#, 16#0F#, 16#81#, 16#C0#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#7C#, 16#00#, 16#0F#, 16#80#, 16#01#, 16#F0#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#0E#, 16#00#, 16#3F#, 16#C0#, 16#00#, 16#F0#, 16#00#, 16#1E#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#78#, 16#00#, 16#0E#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#78#, 16#00#, 16#0F#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#38#, 16#00#, 16#0F#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#38#, 16#00#, 16#07#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#38#, 16#00#, 16#07#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#3C#, 16#00#, 16#07#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#1C#, 16#00#, 16#07#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#1C#, 16#01#, 16#C7#, 16#00#, 16#38#, 16#C0#, 16#07#, 16#30#, 16#00#, 16#7C#, 16#00#, 16#00#, 16#00#, 16#F0#, 16#00#, 16#7F#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#80#, 16#00#, 16#1C#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#70#, 16#FF#, 16#83#, 16#80#, 16#F0#, 16#1C#, 16#06#, 16#01#, 16#C0#, 16#60#, 16#0E#, 16#06#, 16#00#, 16#70#, 16#E0#, 16#03#, 16#8C#, 16#00#, 16#38#, 16#C0#, 16#01#, 16#CC#, 16#00#, 16#0F#, 16#F0#, 16#00#, 16#FF#, 16#80#, 16#07#, 16#9E#, 16#00#, 16#38#, 16#F0#, 16#01#, 16#C3#, 16#80#, 16#1E#, 16#1E#, 16#00#, 16#F0#, 16#70#, 16#07#, 16#03#, 16#C2#, 16#38#, 16#0E#, 16#13#, 16#C0#, 16#79#, 16#1C#, 16#01#, 16#F0#, 16#00#, 16#07#, 16#00#, 16#00#, 16#E1#, 16#FC#, 16#0F#, 16#80#, 16#E0#, 16#1C#, 16#03#, 16#80#, 16#F0#, 16#1C#, 16#03#, 16#80#, 16#F0#, 16#1C#, 16#03#, 16#80#, 16#70#, 16#1E#, 16#03#, 16#80#, 16#70#, 16#0E#, 16#03#, 16#C0#, 16#70#, 16#0E#, 16#03#, 16#C0#, 16#70#, 16#0E#, 16#01#, 16#C0#, 16#78#, 16#0E#, 16#01#, 16#C0#, 16#38#, 16#4E#, 16#11#, 16#C4#, 16#39#, 16#07#, 16#C0#, 16#70#, 16#00#, 16#07#, 16#81#, 16#C0#, 16#78#, 16#FE#, 16#0F#, 16#C1#, 16#F8#, 16#3C#, 16#33#, 16#84#, 16#70#, 16#78#, 16#87#, 16#10#, 16#E0#, 16#F2#, 16#0E#, 16#41#, 16#C1#, 16#C8#, 16#39#, 16#07#, 16#87#, 16#A0#, 16#74#, 16#0F#, 16#0F#, 16#40#, 16#E8#, 16#1E#, 16#1F#, 16#01#, 16#E0#, 16#38#, 16#3C#, 16#07#, 16#C0#, 16#F0#, 16#F8#, 16#0F#, 16#01#, 16#E1#, 16#E0#, 16#1E#, 16#03#, 16#C3#, 16#C0#, 16#38#, 16#07#, 16#07#, 16#00#, 16#F0#, 16#1E#, 16#1E#, 16#01#, 16#E0#, 16#3C#, 16#3C#, 16#03#, 16#80#, 16#79#, 16#70#, 16#07#, 16#00#, 16#E2#, 16#E0#, 16#1E#, 16#03#, 16#8B#, 16#C0#, 16#3C#, 16#07#, 16#27#, 16#80#, 16#70#, 16#0F#, 16#8E#, 16#00#, 16#E0#, 16#1E#, 16#00#, 16#07#, 16#81#, 16#E3#, 16#FC#, 16#3F#, 16#83#, 16#C2#, 16#3C#, 16#1E#, 16#21#, 16#E0#, 16#F2#, 16#0F#, 16#07#, 16#20#, 16#70#, 16#39#, 16#07#, 16#81#, 16#D0#, 16#3C#, 16#1D#, 16#01#, 16#C0#, 16#E8#, 16#0E#, 16#07#, 16#80#, 16#F0#, 16#78#, 16#07#, 16#83#, 16#C0#, 16#38#, 16#1C#, 16#01#, 16#C1#, 16#E0#, 16#1E#, 16#0F#, 16#00#, 16#F1#, 16#70#, 16#07#, 16#0B#, 16#80#, 16#38#, 16#BC#, 16#01#, 16#C9#, 16#E0#, 16#0F#, 16#8E#, 16#00#, 16#38#, 16#00#, 16#00#, 16#1F#, 16#80#, 16#07#, 16#8F#, 16#00#, 16#70#, 16#3C#, 16#07#, 16#00#, 16#E0#, 16#70#, 16#07#, 16#87#, 16#80#, 16#3C#, 16#78#, 16#01#, 16#E7#, 16#80#, 16#0F#, 16#3C#, 16#00#, 16#7B#, 16#C0#, 16#03#, 16#DE#, 16#00#, 16#3D#, 16#F0#, 16#01#, 16#EF#, 16#80#, 16#0F#, 16#78#, 16#00#, 16#F3#, 16#C0#, 16#07#, 16#9E#, 16#00#, 16#78#, 16#F0#, 16#03#, 16#87#, 16#80#, 16#38#, 16#1C#, 16#03#, 16#80#, 16#F0#, 16#38#, 16#03#, 16#C3#, 16#00#, 16#07#, 16#E0#, 16#00#, 16#00#, 16#3C#, 16#3F#, 16#00#, 16#7F#, 16#8F#, 16#F0#, 16#01#, 16#F7#, 16#3F#, 16#00#, 16#1D#, 16#83#, 16#F0#, 16#07#, 16#A0#, 16#3E#, 16#00#, 16#F8#, 16#07#, 16#C0#, 16#1E#, 16#00#, 16#F8#, 16#03#, 16#C0#, 16#1F#, 16#00#, 16#F0#, 16#03#, 16#E0#, 16#1E#, 16#00#, 16#7C#, 16#03#, 16#C0#, 16#1F#, 16#00#, 16#70#, 16#03#, 16#E0#, 16#1E#, 16#00#, 16#78#, 16#03#, 16#C0#, 16#1F#, 16#00#, 16#70#, 16#03#, 16#C0#, 16#0E#, 16#00#, 16#F8#, 16#03#, 16#C0#, 16#1E#, 16#00#, 16#78#, 16#07#, 16#80#, 16#0F#, 16#01#, 16#E0#, 16#01#, 16#E0#, 16#70#, 16#00#, 16#7C#, 16#3C#, 16#00#, 16#0F#, 16#7C#, 16#00#, 16#01#, 16#C0#, 16#00#, 16#00#, 16#78#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#01#, 16#E0#, 16#00#, 16#00#, 16#7E#, 16#00#, 16#00#, 16#3F#, 16#F0#, 16#00#, 16#00#, 16#00#, 16#1F#, 16#00#, 16#03#, 16#8D#, 16#C0#, 16#38#, 16#2E#, 16#07#, 16#80#, 16#F0#, 16#78#, 16#07#, 16#03#, 16#80#, 16#38#, 16#38#, 16#03#, 16#C3#, 16#C0#, 16#1E#, 16#3C#, 16#00#, 16#E1#, 16#E0#, 16#07#, 16#1E#, 16#00#, 16#78#, 16#F0#, 16#03#, 16#87#, 16#80#, 16#3C#, 16#78#, 16#01#, 16#E3#, 16#C0#, 16#1F#, 16#1E#, 16#01#, 16#70#, 16#F0#, 16#13#, 16#87#, 16#80#, 16#BC#, 16#3C#, 16#09#, 16#C0#, 16#F1#, 16#8E#, 16#07#, 16#F8#, 16#F0#, 16#1F#, 16#07#, 16#80#, 16#00#, 16#38#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#78#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#3E#, 16#00#, 16#0F#, 16#FE#, 16#00#, 16#07#, 16#87#, 16#3F#, 16#87#, 16#C3#, 16#C7#, 16#E1#, 16#E6#, 16#F0#, 16#F6#, 16#00#, 16#72#, 16#00#, 16#3A#, 16#00#, 16#1D#, 16#00#, 16#0F#, 16#00#, 16#0E#, 16#80#, 16#07#, 16#80#, 16#03#, 16#C0#, 16#03#, 16#C0#, 16#01#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#3C#, 16#00#, 16#1C#, 16#00#, 16#1E#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#01#, 16#F8#, 16#81#, 16#87#, 16#C1#, 16#80#, 16#E1#, 16#C0#, 16#60#, 16#E0#, 16#10#, 16#70#, 16#08#, 16#3C#, 16#04#, 16#1F#, 16#00#, 16#07#, 16#C0#, 16#03#, 16#E0#, 16#00#, 16#F8#, 16#00#, 16#3E#, 16#00#, 16#0F#, 16#00#, 16#03#, 16#C1#, 16#01#, 16#E0#, 16#80#, 16#70#, 16#40#, 16#38#, 16#30#, 16#1C#, 16#18#, 16#0C#, 16#1C#, 16#0E#, 16#0F#, 16#0E#, 16#04#, 16#7C#, 16#00#, 16#00#, 16#C0#, 16#18#, 16#03#, 16#80#, 16#78#, 16#1F#, 16#03#, 16#FF#, 16#7F#, 16#F0#, 16#F0#, 16#0E#, 16#00#, 16#E0#, 16#1E#, 16#01#, 16#E0#, 16#1C#, 16#01#, 16#C0#, 16#3C#, 16#03#, 16#80#, 16#38#, 16#03#, 16#80#, 16#78#, 16#07#, 16#00#, 16#70#, 16#8F#, 16#10#, 16#F1#, 16#0F#, 16#20#, 16#FC#, 16#07#, 16#80#, 16#00#, 16#00#, 16#00#, 16#F0#, 16#0E#, 16#7F#, 16#00#, 16#E0#, 16#F0#, 16#1E#, 16#0E#, 16#01#, 16#E1#, 16#E0#, 16#3C#, 16#1E#, 16#03#, 16#C1#, 16#E0#, 16#3C#, 16#1C#, 16#07#, 16#C3#, 16#C0#, 16#78#, 16#3C#, 16#0F#, 16#83#, 16#C0#, 16#B8#, 16#38#, 16#1F#, 16#87#, 16#83#, 16#70#, 16#78#, 16#27#, 16#07#, 16#86#, 16#70#, 16#70#, 16#C7#, 16#1F#, 16#08#, 16#E1#, 16#E1#, 16#0E#, 16#2E#, 16#60#, 16#E4#, 16#FC#, 16#0F#, 16#87#, 16#00#, 16#70#, 16#1C#, 16#03#, 16#BF#, 16#00#, 16#F1#, 16#E0#, 16#3C#, 16#78#, 16#07#, 16#1E#, 16#00#, 16#C3#, 16#80#, 16#30#, 16#E0#, 16#08#, 16#38#, 16#06#, 16#0E#, 16#01#, 16#03#, 16#80#, 16#C0#, 16#F0#, 16#20#, 16#3C#, 16#10#, 16#07#, 16#04#, 16#01#, 16#C2#, 16#00#, 16#71#, 16#00#, 16#1C#, 16#C0#, 16#07#, 16#60#, 16#01#, 16#F0#, 16#00#, 16#78#, 16#00#, 16#1C#, 16#00#, 16#06#, 16#00#, 16#01#, 16#00#, 16#00#, 16#0C#, 16#00#, 16#40#, 16#3B#, 16#F8#, 16#01#, 16#00#, 16#F1#, 16#E0#, 16#0C#, 16#03#, 16#C3#, 16#80#, 16#38#, 16#07#, 16#0E#, 16#01#, 16#E0#, 16#0C#, 16#38#, 16#0F#, 16#80#, 16#20#, 16#E0#, 16#2E#, 16#00#, 16#83#, 16#81#, 16#38#, 16#04#, 16#0F#, 16#0C#, 16#E0#, 16#10#, 16#1C#, 16#23#, 16#80#, 16#80#, 16#71#, 16#8E#, 16#06#, 16#01#, 16#CC#, 16#38#, 16#10#, 16#07#, 16#20#, 16#F0#, 16#80#, 16#1D#, 16#83#, 16#C6#, 16#00#, 16#7C#, 16#0F#, 16#30#, 16#01#, 16#F0#, 16#1C#, 16#80#, 16#07#, 16#80#, 16#74#, 16#00#, 16#1E#, 16#01#, 16#F0#, 16#00#, 16#70#, 16#07#, 16#80#, 16#01#, 16#C0#, 16#1C#, 16#00#, 16#06#, 16#00#, 16#60#, 16#00#, 16#10#, 16#01#, 16#00#, 16#00#, 16#00#, 16#E0#, 16#38#, 16#1F#, 16#81#, 16#F0#, 16#8F#, 16#09#, 16#80#, 16#3C#, 16#40#, 16#00#, 16#72#, 16#00#, 16#01#, 16#D0#, 16#00#, 16#07#, 16#C0#, 16#00#, 16#1E#, 16#00#, 16#00#, 16#38#, 16#00#, 16#00#, 16#E0#, 16#00#, 16#03#, 16#80#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#7C#, 16#00#, 16#01#, 16#70#, 16#00#, 16#09#, 16#C0#, 16#00#, 16#67#, 16#00#, 16#01#, 16#1E#, 16#10#, 16#08#, 16#38#, 16#40#, 16#40#, 16#E2#, 16#39#, 16#03#, 16#D0#, 16#F8#, 16#0F#, 16#83#, 16#C0#, 16#1C#, 16#00#, 16#07#, 16#80#, 16#33#, 16#FC#, 16#03#, 16#C1#, 16#E0#, 16#1E#, 16#07#, 16#80#, 16#70#, 16#3C#, 16#01#, 16#80#, 16#E0#, 16#0C#, 16#07#, 16#80#, 16#40#, 16#3C#, 16#02#, 16#00#, 16#E0#, 16#20#, 16#07#, 16#81#, 16#00#, 16#3C#, 16#18#, 16#01#, 16#E0#, 16#80#, 16#07#, 16#0C#, 16#00#, 16#38#, 16#40#, 16#01#, 16#E4#, 16#00#, 16#0F#, 16#60#, 16#00#, 16#3A#, 16#00#, 16#01#, 16#F0#, 16#00#, 16#0F#, 16#00#, 16#00#, 16#70#, 16#00#, 16#03#, 16#80#, 16#00#, 16#18#, 16#00#, 16#00#, 16#80#, 16#00#, 16#0C#, 16#00#, 16#00#, 16#40#, 16#00#, 16#04#, 16#00#, 16#00#, 16#40#, 16#00#, 16#04#, 16#00#, 16#0E#, 16#40#, 16#00#, 16#7C#, 16#00#, 16#03#, 16#C0#, 16#00#, 16#00#, 16#0F#, 16#FF#, 16#87#, 16#FF#, 16#82#, 16#00#, 16#83#, 16#00#, 16#C1#, 16#00#, 16#C0#, 16#00#, 16#C0#, 16#00#, 16#40#, 16#00#, 16#60#, 16#00#, 16#60#, 16#00#, 16#60#, 16#00#, 16#20#, 16#00#, 16#20#, 16#00#, 16#30#, 16#00#, 16#30#, 16#00#, 16#30#, 16#00#, 16#10#, 16#00#, 16#18#, 16#00#, 16#1E#, 16#00#, 16#1F#, 16#C0#, 16#1F#, 16#F0#, 16#E8#, 16#FC#, 16#70#, 16#1E#, 16#38#, 16#03#, 16#88#, 16#00#, 16#78#, 16#00#, 16#0F#, 16#00#, 16#1E#, 16#00#, 16#1E#, 16#00#, 16#0E#, 16#00#, 16#0F#, 16#00#, 16#07#, 16#80#, 16#03#, 16#80#, 16#01#, 16#C0#, 16#01#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#70#, 16#00#, 16#78#, 16#00#, 16#3C#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#0F#, 16#00#, 16#07#, 16#80#, 16#07#, 16#80#, 16#03#, 16#C0#, 16#07#, 16#C0#, 16#07#, 16#C0#, 16#00#, 16#80#, 16#00#, 16#60#, 16#00#, 16#38#, 16#00#, 16#1C#, 16#00#, 16#0E#, 16#00#, 16#0F#, 16#00#, 16#07#, 16#80#, 16#03#, 16#80#, 16#01#, 16#C0#, 16#01#, 16#E0#, 16#00#, 16#F0#, 16#00#, 16#70#, 16#00#, 16#38#, 16#00#, 16#3C#, 16#00#, 16#1E#, 16#00#, 16#0E#, 16#00#, 16#07#, 16#00#, 16#01#, 16#80#, 16#00#, 16#70#, 16#00#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#FF#, 16#E0#, 16#00#, 16#18#, 16#00#, 16#0E#, 16#00#, 16#06#, 16#00#, 16#07#, 16#00#, 16#07#, 16#00#, 16#07#, 16#00#, 16#07#, 16#00#, 16#0F#, 16#00#, 16#0F#, 16#00#, 16#0E#, 16#00#, 16#0E#, 16#00#, 16#1E#, 16#00#, 16#1E#, 16#00#, 16#1C#, 16#00#, 16#1C#, 16#00#, 16#3C#, 16#00#, 16#3C#, 16#00#, 16#38#, 16#00#, 16#38#, 16#00#, 16#18#, 16#00#, 16#08#, 16#00#, 16#1C#, 16#00#, 16#7E#, 16#00#, 16#78#, 16#00#, 16#F0#, 16#00#, 16#E0#, 16#01#, 16#E0#, 16#01#, 16#E0#, 16#01#, 16#C0#, 16#01#, 16#C0#, 16#03#, 16#C0#, 16#03#, 16#80#, 16#03#, 16#80#, 16#07#, 16#80#, 16#07#, 16#80#, 16#07#, 16#00#, 16#07#, 16#00#, 16#0F#, 16#00#, 16#0E#, 16#00#, 16#1C#, 16#00#, 16#F8#, 16#00#, 16#1F#, 16#80#, 16#00#, 16#FF#, 16#80#, 16#C7#, 16#FF#, 16#87#, 16#BC#, 16#3F#, 16#FE#, 16#60#, 16#3F#, 16#F0#, 16#00#, 16#1F#, 16#00#); FreeSerifItalic24pt7bGlyphs : aliased constant Glyph_Array := ( (0, 0, 0, 12, 0, 1), -- 0x20 ' ' (0, 12, 32, 16, 2, -30), -- 0x21 '!' (48, 14, 12, 16, 6, -31), -- 0x22 '"' (69, 25, 31, 23, 0, -30), -- 0x23 '#' (166, 21, 38, 24, 2, -33), -- 0x24 '$' (266, 33, 32, 39, 4, -30), -- 0x25 '%' (398, 30, 33, 37, 4, -31), -- 0x26 '&' (522, 5, 12, 9, 6, -31), -- 0x27 ''' (530, 13, 39, 16, 2, -30), -- 0x28 '(' (594, 13, 39, 16, 0, -30), -- 0x29 ')' (658, 16, 20, 23, 7, -31), -- 0x2A '*' (698, 23, 23, 32, 4, -22), -- 0x2B '+' (765, 7, 11, 12, -1, -4), -- 0x2C ',' (775, 11, 3, 16, 2, -11), -- 0x2D '-' (780, 5, 5, 12, 1, -3), -- 0x2E '.' (784, 21, 33, 14, 0, -31), -- 0x2F '/' (871, 21, 31, 23, 2, -30), -- 0x30 '0' (953, 17, 32, 23, 2, -31), -- 0x31 '1' (1021, 21, 31, 24, 0, -30), -- 0x32 '2' (1103, 22, 32, 23, 0, -31), -- 0x33 '3' (1191, 22, 32, 23, 0, -31), -- 0x34 '4' (1279, 22, 32, 24, 0, -31), -- 0x35 '5' (1367, 23, 32, 23, 1, -31), -- 0x36 '6' (1459, 21, 32, 23, 4, -31), -- 0x37 '7' (1543, 22, 32, 23, 1, -31), -- 0x38 '8' (1631, 22, 33, 23, 1, -31), -- 0x39 '9' (1722, 9, 22, 12, 2, -20), -- 0x3A ':' (1747, 11, 27, 12, 1, -20), -- 0x3B ';' (1785, 23, 25, 27, 3, -24), -- 0x3C '<' (1857, 24, 12, 31, 4, -17), -- 0x3D '=' (1893, 24, 25, 27, 3, -24), -- 0x3E '>' (1968, 16, 33, 21, 6, -31), -- 0x3F '?' (2034, 33, 33, 37, 3, -31), -- 0x40 '@' (2171, 29, 31, 31, 0, -30), -- 0x41 'A' (2284, 28, 31, 28, 0, -30), -- 0x42 'B' (2393, 30, 33, 29, 2, -31), -- 0x43 'C' (2517, 33, 31, 33, 0, -30), -- 0x44 'D' (2645, 29, 31, 27, 0, -30), -- 0x45 'E' (2758, 29, 31, 27, 0, -30), -- 0x46 'F' (2871, 31, 33, 32, 2, -31), -- 0x47 'G' (2999, 36, 31, 33, 0, -30), -- 0x48 'H' (3139, 18, 31, 15, 0, -30), -- 0x49 'I' (3209, 23, 32, 20, 0, -30), -- 0x4A 'J' (3301, 33, 31, 30, 0, -30), -- 0x4B 'K' (3429, 27, 31, 27, 0, -30), -- 0x4C 'L' (3534, 42, 31, 39, 0, -30), -- 0x4D 'M' (3697, 35, 32, 32, 0, -30), -- 0x4E 'N' (3837, 30, 33, 31, 2, -31), -- 0x4F 'O' (3961, 29, 31, 27, 0, -30), -- 0x50 'P' (4074, 30, 41, 31, 2, -31), -- 0x51 'Q' (4228, 28, 31, 29, 0, -30), -- 0x52 'R' (4337, 23, 33, 21, 0, -31), -- 0x53 'S' (4432, 27, 31, 28, 4, -30), -- 0x54 'T' (4537, 31, 32, 33, 5, -30), -- 0x55 'U' (4661, 29, 32, 31, 6, -30), -- 0x56 'V' (4777, 39, 32, 42, 6, -30), -- 0x57 'W' (4933, 32, 31, 31, 0, -30), -- 0x58 'X' (5057, 26, 31, 28, 5, -30), -- 0x59 'Y' (5158, 29, 31, 26, 0, -30), -- 0x5A 'Z' (5271, 17, 39, 18, 1, -31), -- 0x5B '[' (5354, 17, 33, 23, 5, -31), -- 0x5C '\' (5425, 17, 39, 18, 1, -31), -- 0x5D ']' (5508, 20, 17, 20, 0, -31), -- 0x5E '^' (5551, 24, 2, 23, 0, 5), -- 0x5F '_' (5557, 8, 8, 12, 6, -31), -- 0x60 '`' (5565, 21, 21, 23, 1, -20), -- 0x61 'a' (5621, 21, 33, 22, 1, -31), -- 0x62 'b' (5708, 18, 22, 19, 1, -20), -- 0x63 'c' (5758, 24, 33, 23, 1, -31), -- 0x64 'd' (5857, 18, 22, 19, 1, -20), -- 0x65 'e' (5907, 27, 42, 20, -4, -31), -- 0x66 'f' (6049, 21, 31, 21, -1, -20), -- 0x67 'g' (6131, 21, 32, 23, 1, -31), -- 0x68 'h' (6215, 10, 32, 12, 2, -30), -- 0x69 'i' (6255, 19, 41, 13, -3, -30), -- 0x6A 'j' (6353, 21, 33, 21, 1, -31), -- 0x6B 'k' (6440, 11, 33, 12, 2, -31), -- 0x6C 'l' (6486, 31, 21, 34, 1, -20), -- 0x6D 'm' (6568, 21, 21, 23, 1, -20), -- 0x6E 'n' (6624, 21, 22, 22, 1, -20), -- 0x6F 'o' (6682, 27, 31, 22, -4, -20), -- 0x70 'p' (6787, 21, 31, 23, 1, -20), -- 0x71 'q' (6869, 17, 21, 17, 1, -20), -- 0x72 'r' (6914, 17, 22, 16, 0, -20), -- 0x73 's' (6961, 12, 26, 11, 1, -24), -- 0x74 't' (7000, 20, 22, 23, 1, -20), -- 0x75 'u' (7055, 18, 22, 21, 3, -20), -- 0x76 'v' (7105, 30, 22, 32, 2, -20), -- 0x77 'w' (7188, 22, 22, 20, -1, -20), -- 0x78 'x' (7249, 21, 31, 22, 1, -20), -- 0x79 'y' (7331, 17, 24, 18, 0, -19), -- 0x7A 'z' (7382, 17, 40, 19, 2, -31), -- 0x7B '{' (7467, 3, 33, 13, 5, -31), -- 0x7C '|' (7480, 16, 41, 19, 0, -32), -- 0x7D '}' (7562, 22, 6, 25, 2, -14)); -- 0x7E '~' Font_D : aliased constant Bitmap_Font := (FreeSerifItalic24pt7bBitmaps'Access, FreeSerifItalic24pt7bGlyphs'Access, 56); Font : constant Giza.Font.Ref_Const := Font_D'Access; end Giza.Bitmap_Fonts.FreeSerifItalic24pt7b;
with Ada.Exceptions; use Ada.Exceptions; package Noreturn2 is procedure Raise_From (X : Exception_Occurrence); pragma No_Return (Raise_From); end Noreturn2;
----------------------------------------------------------------------- -- css-core-groups -- CSS rule to represent a group of CSS rules -- Copyright (C) 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- package body CSS.Core.Groups is -- ------------------------------ -- Get the type that identifies the rule. -- ------------------------------ overriding function Get_Type (Rule : in CSSGroupingRule) return CSSRule_Type is pragma Unreferenced (Rule); begin return STYLE_RULE; end Get_Type; end CSS.Core.Groups;
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <!DOCTYPE boost_serialization> <boost_serialization signature="serialization::archive" version="15"> <syndb class_id="0" tracking_level="0" version="0"> <userIPLatency>-1</userIPLatency> <userIPName></userIPName> <cdfg class_id="1" tracking_level="1" version="0" object_id="_0"> <name>honeybee</name> <ret_bitwidth>64</ret_bitwidth> <ports class_id="2" tracking_level="0" version="0"> <count>6</count> <item_version>0</item_version> <item class_id="3" tracking_level="1" version="0" object_id="_1"> <Value class_id="4" tracking_level="0" version="0"> <Obj class_id="5" tracking_level="0" version="0"> <type>1</type> <id>1</id> <name>edge_p1_x</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo class_id="6" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>edge_y.p1.x</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs class_id="7" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_2"> <Value> <Obj> <type>1</type> <id>2</id> <name>edge_p1_y</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>edge_y.p1.z</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_3"> <Value> <Obj> <type>1</type> <id>3</id> <name>edge_p1_z</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>edge_y.p1.y</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_4"> <Value> <Obj> <type>1</type> <id>4</id> <name>edge_p2_x</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>edge_y.p2.x</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_5"> <Value> <Obj> <type>1</type> <id>5</id> <name>edge_p2_y</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>edge_y.p2.z</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_6"> <Value> <Obj> <type>1</type> <id>6</id> <name>edge_p2_z</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>edge_y.p2.y</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> </ports> <nodes class_id="8" tracking_level="0" version="0"> <count>12</count> <item_version>0</item_version> <item class_id="9" tracking_level="1" version="0" object_id="_7"> <Value> <Obj> <type>0</type> <id>15</id> <name>edge_p2_z_read</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>159</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item class_id="10" tracking_level="0" version="0"> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second class_id="11" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="12" tracking_level="0" version="0"> <first class_id="13" tracking_level="0" version="0"> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>159</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>29</item> <item>30</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>1</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_8"> <Value> <Obj> <type>0</type> <id>16</id> <name>edge_p2_y_read</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>159</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>159</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>31</item> <item>32</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>2</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_9"> <Value> <Obj> <type>0</type> <id>17</id> <name>edge_p2_x_read</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>159</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>159</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>33</item> <item>34</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>3</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_10"> <Value> <Obj> <type>0</type> <id>18</id> <name>edge_p1_z_read</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>159</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>159</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>35</item> <item>36</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>4</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_11"> <Value> <Obj> <type>0</type> <id>19</id> <name>edge_p1_y_read</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>159</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>159</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>37</item> <item>38</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>5</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_12"> <Value> <Obj> <type>0</type> <id>20</id> <name>edge_p1_x_read</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>159</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>159</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>39</item> <item>40</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>6</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_13"> <Value> <Obj> <type>0</type> <id>21</id> <name>collisions_z</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>166</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>166</second> </item> </second> </item> </inlineStackInfo> <originalName>collisions_z</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>7</count> <item_version>0</item_version> <item>42</item> <item>43</item> <item>44</item> <item>45</item> <item>46</item> <item>47</item> <item>48</item> </oprand_edges> <opcode>call</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>8.58</m_delay> <m_topoIndex>7</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_14"> <Value> <Obj> <type>0</type> <id>22</id> <name>collisions_y</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>167</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>167</second> </item> </second> </item> </inlineStackInfo> <originalName>collisions_y</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>7</count> <item_version>0</item_version> <item>50</item> <item>51</item> <item>52</item> <item>53</item> <item>54</item> <item>55</item> <item>56</item> </oprand_edges> <opcode>call</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>8.58</m_delay> <m_topoIndex>8</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_15"> <Value> <Obj> <type>0</type> <id>23</id> <name>collisions_x</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>168</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>168</second> </item> </second> </item> </inlineStackInfo> <originalName>collisions_x</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>7</count> <item_version>0</item_version> <item>58</item> <item>59</item> <item>60</item> <item>61</item> <item>62</item> <item>63</item> <item>64</item> </oprand_edges> <opcode>call</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>8.58</m_delay> <m_topoIndex>9</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_16"> <Value> <Obj> <type>0</type> <id>24</id> <name>or_ln170</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>170</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>170</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>65</item> <item>66</item> </oprand_edges> <opcode>or</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>10</m_topoIndex> <m_clusterGroupNumber>1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_17"> <Value> <Obj> <type>0</type> <id>25</id> <name>collisions</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>170</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>170</second> </item> </second> </item> </inlineStackInfo> <originalName>collisions</originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>67</item> <item>68</item> </oprand_edges> <opcode>or</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.80</m_delay> <m_topoIndex>11</m_topoIndex> <m_clusterGroupNumber>1</m_clusterGroupNumber> </item> <item class_id_reference="9" object_id="_18"> <Value> <Obj> <type>0</type> <id>26</id> <name>_ln171</name> <fileName>src/honeybee.c</fileName> <fileDirectory>/mnt/hgfs/Thesis/HoneyBee</fileDirectory> <lineNumber>171</lineNumber> <contextFuncName>honeybee</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/mnt/hgfs/Thesis/HoneyBee</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>src/honeybee.c</first> <second>honeybee</second> </first> <second>171</second> </item> </second> </item> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>69</item> </oprand_edges> <opcode>ret</opcode> <m_Display>0</m_Display> <m_isOnCriticalPath>0</m_isOnCriticalPath> <m_isLCDNode>0</m_isLCDNode> <m_isStartOfPath>0</m_isStartOfPath> <m_delay>0.00</m_delay> <m_topoIndex>12</m_topoIndex> <m_clusterGroupNumber>-1</m_clusterGroupNumber> </item> </nodes> <consts class_id="15" tracking_level="0" version="0"> <count>3</count> <item_version>0</item_version> <item class_id="16" tracking_level="1" version="0" object_id="_19"> <Value> <Obj> <type>2</type> <id>41</id> <name>checkAxis_2</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <const_type>6</const_type> <content>&lt;constant:checkAxis.2&gt;</content> </item> <item class_id_reference="16" object_id="_20"> <Value> <Obj> <type>2</type> <id>49</id> <name>checkAxis_0</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <const_type>6</const_type> <content>&lt;constant:checkAxis.0&gt;</content> </item> <item class_id_reference="16" object_id="_21"> <Value> <Obj> <type>2</type> <id>57</id> <name>checkAxis_1</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <bitwidth>64</bitwidth> </Value> <const_type>6</const_type> <content>&lt;constant:checkAxis.1&gt;</content> </item> </consts> <blocks class_id="17" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="18" tracking_level="1" version="0" object_id="_22"> <Obj> <type>3</type> <id>27</id> <name>honeybee</name> <fileName></fileName> <fileDirectory></fileDirectory> <lineNumber>0</lineNumber> <contextFuncName></contextFuncName> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName></originalName> <rtlName></rtlName> <coreName></coreName> </Obj> <node_objs> <count>12</count> <item_version>0</item_version> <item>15</item> <item>16</item> <item>17</item> <item>18</item> <item>19</item> <item>20</item> <item>21</item> <item>22</item> <item>23</item> <item>24</item> <item>25</item> <item>26</item> </node_objs> </item> </blocks> <edges class_id="19" tracking_level="0" version="0"> <count>32</count> <item_version>0</item_version> <item class_id="20" tracking_level="1" version="0" object_id="_23"> <id>30</id> <edge_type>1</edge_type> <source_obj>6</source_obj> <sink_obj>15</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_24"> <id>32</id> <edge_type>1</edge_type> <source_obj>5</source_obj> <sink_obj>16</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_25"> <id>34</id> <edge_type>1</edge_type> <source_obj>4</source_obj> <sink_obj>17</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_26"> <id>36</id> <edge_type>1</edge_type> <source_obj>3</source_obj> <sink_obj>18</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_27"> <id>38</id> <edge_type>1</edge_type> <source_obj>2</source_obj> <sink_obj>19</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_28"> <id>40</id> <edge_type>1</edge_type> <source_obj>1</source_obj> <sink_obj>20</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_29"> <id>42</id> <edge_type>1</edge_type> <source_obj>41</source_obj> <sink_obj>21</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_30"> <id>43</id> <edge_type>1</edge_type> <source_obj>20</source_obj> <sink_obj>21</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_31"> <id>44</id> <edge_type>1</edge_type> <source_obj>19</source_obj> <sink_obj>21</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_32"> <id>45</id> <edge_type>1</edge_type> <source_obj>18</source_obj> <sink_obj>21</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_33"> <id>46</id> <edge_type>1</edge_type> <source_obj>17</source_obj> <sink_obj>21</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_34"> <id>47</id> <edge_type>1</edge_type> <source_obj>16</source_obj> <sink_obj>21</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_35"> <id>48</id> <edge_type>1</edge_type> <source_obj>15</source_obj> <sink_obj>21</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_36"> <id>50</id> <edge_type>1</edge_type> <source_obj>49</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_37"> <id>51</id> <edge_type>1</edge_type> <source_obj>20</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_38"> <id>52</id> <edge_type>1</edge_type> <source_obj>18</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_39"> <id>53</id> <edge_type>1</edge_type> <source_obj>19</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_40"> <id>54</id> <edge_type>1</edge_type> <source_obj>17</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_41"> <id>55</id> <edge_type>1</edge_type> <source_obj>15</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_42"> <id>56</id> <edge_type>1</edge_type> <source_obj>16</source_obj> <sink_obj>22</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_43"> <id>58</id> <edge_type>1</edge_type> <source_obj>57</source_obj> <sink_obj>23</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_44"> <id>59</id> <edge_type>1</edge_type> <source_obj>18</source_obj> <sink_obj>23</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_45"> <id>60</id> <edge_type>1</edge_type> <source_obj>19</source_obj> <sink_obj>23</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_46"> <id>61</id> <edge_type>1</edge_type> <source_obj>20</source_obj> <sink_obj>23</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_47"> <id>62</id> <edge_type>1</edge_type> <source_obj>15</source_obj> <sink_obj>23</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_48"> <id>63</id> <edge_type>1</edge_type> <source_obj>16</source_obj> <sink_obj>23</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_49"> <id>64</id> <edge_type>1</edge_type> <source_obj>17</source_obj> <sink_obj>23</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_50"> <id>65</id> <edge_type>1</edge_type> <source_obj>21</source_obj> <sink_obj>24</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_51"> <id>66</id> <edge_type>1</edge_type> <source_obj>23</source_obj> <sink_obj>24</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_52"> <id>67</id> <edge_type>1</edge_type> <source_obj>24</source_obj> <sink_obj>25</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_53"> <id>68</id> <edge_type>1</edge_type> <source_obj>22</source_obj> <sink_obj>25</sink_obj> <is_back_edge>0</is_back_edge> </item> <item class_id_reference="20" object_id="_54"> <id>69</id> <edge_type>1</edge_type> <source_obj>25</source_obj> <sink_obj>26</sink_obj> <is_back_edge>0</is_back_edge> </item> </edges> </cdfg> <cdfg_regions class_id="21" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="22" tracking_level="1" version="0" object_id="_55"> <mId>1</mId> <mTag>honeybee</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>27</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>53</mMinLatency> <mMaxLatency>53</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"></mDfPipe> </item> </cdfg_regions> <fsm class_id="24" tracking_level="1" version="0" object_id="_56"> <states class_id="25" tracking_level="0" version="0"> <count>54</count> <item_version>0</item_version> <item class_id="26" tracking_level="1" version="0" object_id="_57"> <id>1</id> <operations class_id="27" tracking_level="0" version="0"> <count>9</count> <item_version>0</item_version> <item class_id="28" tracking_level="1" version="0" object_id="_58"> <id>15</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_59"> <id>16</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_60"> <id>17</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_61"> <id>18</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_62"> <id>19</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_63"> <id>20</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_64"> <id>21</id> <stage>53</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_65"> <id>22</id> <stage>53</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_66"> <id>23</id> <stage>53</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_67"> <id>2</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_68"> <id>21</id> <stage>52</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_69"> <id>22</id> <stage>52</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_70"> <id>23</id> <stage>52</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_71"> <id>3</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_72"> <id>21</id> <stage>51</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_73"> <id>22</id> <stage>51</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_74"> <id>23</id> <stage>51</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_75"> <id>4</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_76"> <id>21</id> <stage>50</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_77"> <id>22</id> <stage>50</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_78"> <id>23</id> <stage>50</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_79"> <id>5</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_80"> <id>21</id> <stage>49</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_81"> <id>22</id> <stage>49</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_82"> <id>23</id> <stage>49</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_83"> <id>6</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_84"> <id>21</id> <stage>48</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_85"> <id>22</id> <stage>48</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_86"> <id>23</id> <stage>48</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_87"> <id>7</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_88"> <id>21</id> <stage>47</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_89"> <id>22</id> <stage>47</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_90"> <id>23</id> <stage>47</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_91"> <id>8</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_92"> <id>21</id> <stage>46</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_93"> <id>22</id> <stage>46</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_94"> <id>23</id> <stage>46</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_95"> <id>9</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_96"> <id>21</id> <stage>45</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_97"> <id>22</id> <stage>45</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_98"> <id>23</id> <stage>45</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_99"> <id>10</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_100"> <id>21</id> <stage>44</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_101"> <id>22</id> <stage>44</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_102"> <id>23</id> <stage>44</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_103"> <id>11</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_104"> <id>21</id> <stage>43</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_105"> <id>22</id> <stage>43</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_106"> <id>23</id> <stage>43</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_107"> <id>12</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_108"> <id>21</id> <stage>42</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_109"> <id>22</id> <stage>42</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_110"> <id>23</id> <stage>42</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_111"> <id>13</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_112"> <id>21</id> <stage>41</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_113"> <id>22</id> <stage>41</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_114"> <id>23</id> <stage>41</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_115"> <id>14</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_116"> <id>21</id> <stage>40</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_117"> <id>22</id> <stage>40</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_118"> <id>23</id> <stage>40</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_119"> <id>15</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_120"> <id>21</id> <stage>39</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_121"> <id>22</id> <stage>39</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_122"> <id>23</id> <stage>39</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_123"> <id>16</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_124"> <id>21</id> <stage>38</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_125"> <id>22</id> <stage>38</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_126"> <id>23</id> <stage>38</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_127"> <id>17</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_128"> <id>21</id> <stage>37</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_129"> <id>22</id> <stage>37</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_130"> <id>23</id> <stage>37</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_131"> <id>18</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_132"> <id>21</id> <stage>36</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_133"> <id>22</id> <stage>36</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_134"> <id>23</id> <stage>36</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_135"> <id>19</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_136"> <id>21</id> <stage>35</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_137"> <id>22</id> <stage>35</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_138"> <id>23</id> <stage>35</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_139"> <id>20</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_140"> <id>21</id> <stage>34</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_141"> <id>22</id> <stage>34</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_142"> <id>23</id> <stage>34</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_143"> <id>21</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_144"> <id>21</id> <stage>33</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_145"> <id>22</id> <stage>33</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_146"> <id>23</id> <stage>33</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_147"> <id>22</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_148"> <id>21</id> <stage>32</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_149"> <id>22</id> <stage>32</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_150"> <id>23</id> <stage>32</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_151"> <id>23</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_152"> <id>21</id> <stage>31</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_153"> <id>22</id> <stage>31</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_154"> <id>23</id> <stage>31</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_155"> <id>24</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_156"> <id>21</id> <stage>30</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_157"> <id>22</id> <stage>30</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_158"> <id>23</id> <stage>30</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_159"> <id>25</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_160"> <id>21</id> <stage>29</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_161"> <id>22</id> <stage>29</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_162"> <id>23</id> <stage>29</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_163"> <id>26</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_164"> <id>21</id> <stage>28</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_165"> <id>22</id> <stage>28</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_166"> <id>23</id> <stage>28</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_167"> <id>27</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_168"> <id>21</id> <stage>27</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_169"> <id>22</id> <stage>27</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_170"> <id>23</id> <stage>27</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_171"> <id>28</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_172"> <id>21</id> <stage>26</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_173"> <id>22</id> <stage>26</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_174"> <id>23</id> <stage>26</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_175"> <id>29</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_176"> <id>21</id> <stage>25</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_177"> <id>22</id> <stage>25</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_178"> <id>23</id> <stage>25</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_179"> <id>30</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_180"> <id>21</id> <stage>24</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_181"> <id>22</id> <stage>24</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_182"> <id>23</id> <stage>24</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_183"> <id>31</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_184"> <id>21</id> <stage>23</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_185"> <id>22</id> <stage>23</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_186"> <id>23</id> <stage>23</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_187"> <id>32</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_188"> <id>21</id> <stage>22</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_189"> <id>22</id> <stage>22</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_190"> <id>23</id> <stage>22</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_191"> <id>33</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_192"> <id>21</id> <stage>21</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_193"> <id>22</id> <stage>21</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_194"> <id>23</id> <stage>21</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_195"> <id>34</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_196"> <id>21</id> <stage>20</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_197"> <id>22</id> <stage>20</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_198"> <id>23</id> <stage>20</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_199"> <id>35</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_200"> <id>21</id> <stage>19</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_201"> <id>22</id> <stage>19</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_202"> <id>23</id> <stage>19</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_203"> <id>36</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_204"> <id>21</id> <stage>18</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_205"> <id>22</id> <stage>18</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_206"> <id>23</id> <stage>18</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_207"> <id>37</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_208"> <id>21</id> <stage>17</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_209"> <id>22</id> <stage>17</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_210"> <id>23</id> <stage>17</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_211"> <id>38</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_212"> <id>21</id> <stage>16</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_213"> <id>22</id> <stage>16</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_214"> <id>23</id> <stage>16</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_215"> <id>39</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_216"> <id>21</id> <stage>15</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_217"> <id>22</id> <stage>15</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_218"> <id>23</id> <stage>15</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_219"> <id>40</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_220"> <id>21</id> <stage>14</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_221"> <id>22</id> <stage>14</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_222"> <id>23</id> <stage>14</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_223"> <id>41</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_224"> <id>21</id> <stage>13</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_225"> <id>22</id> <stage>13</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_226"> <id>23</id> <stage>13</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_227"> <id>42</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_228"> <id>21</id> <stage>12</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_229"> <id>22</id> <stage>12</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_230"> <id>23</id> <stage>12</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_231"> <id>43</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_232"> <id>21</id> <stage>11</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_233"> <id>22</id> <stage>11</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_234"> <id>23</id> <stage>11</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_235"> <id>44</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_236"> <id>21</id> <stage>10</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_237"> <id>22</id> <stage>10</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_238"> <id>23</id> <stage>10</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_239"> <id>45</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_240"> <id>21</id> <stage>9</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_241"> <id>22</id> <stage>9</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_242"> <id>23</id> <stage>9</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_243"> <id>46</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_244"> <id>21</id> <stage>8</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_245"> <id>22</id> <stage>8</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_246"> <id>23</id> <stage>8</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_247"> <id>47</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_248"> <id>21</id> <stage>7</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_249"> <id>22</id> <stage>7</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_250"> <id>23</id> <stage>7</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_251"> <id>48</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_252"> <id>21</id> <stage>6</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_253"> <id>22</id> <stage>6</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_254"> <id>23</id> <stage>6</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_255"> <id>49</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_256"> <id>21</id> <stage>5</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_257"> <id>22</id> <stage>5</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_258"> <id>23</id> <stage>5</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_259"> <id>50</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_260"> <id>21</id> <stage>4</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_261"> <id>22</id> <stage>4</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_262"> <id>23</id> <stage>4</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_263"> <id>51</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_264"> <id>21</id> <stage>3</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_265"> <id>22</id> <stage>3</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_266"> <id>23</id> <stage>3</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_267"> <id>52</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_268"> <id>21</id> <stage>2</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_269"> <id>22</id> <stage>2</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_270"> <id>23</id> <stage>2</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_271"> <id>53</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_272"> <id>21</id> <stage>1</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_273"> <id>22</id> <stage>1</stage> <latency>53</latency> </item> <item class_id_reference="28" object_id="_274"> <id>23</id> <stage>1</stage> <latency>53</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_275"> <id>54</id> <operations> <count>11</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_276"> <id>7</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_277"> <id>8</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_278"> <id>9</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_279"> <id>10</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_280"> <id>11</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_281"> <id>12</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_282"> <id>13</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_283"> <id>14</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_284"> <id>24</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_285"> <id>25</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_286"> <id>26</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> </states> <transitions class_id="29" tracking_level="0" version="0"> <count>53</count> <item_version>0</item_version> <item class_id="30" tracking_level="1" version="0" object_id="_287"> <inState>1</inState> <outState>2</outState> <condition class_id="31" tracking_level="0" version="0"> <id>-1</id> <sop class_id="32" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="33" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_288"> <inState>2</inState> <outState>3</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_289"> <inState>3</inState> <outState>4</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_290"> <inState>4</inState> <outState>5</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_291"> <inState>5</inState> <outState>6</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_292"> <inState>6</inState> <outState>7</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_293"> <inState>7</inState> <outState>8</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_294"> <inState>8</inState> <outState>9</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_295"> <inState>9</inState> <outState>10</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_296"> <inState>10</inState> <outState>11</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_297"> <inState>11</inState> <outState>12</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_298"> <inState>12</inState> <outState>13</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_299"> <inState>13</inState> <outState>14</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_300"> <inState>14</inState> <outState>15</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_301"> <inState>15</inState> <outState>16</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_302"> <inState>16</inState> <outState>17</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_303"> <inState>17</inState> <outState>18</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_304"> <inState>18</inState> <outState>19</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_305"> <inState>19</inState> <outState>20</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_306"> <inState>20</inState> <outState>21</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_307"> <inState>21</inState> <outState>22</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_308"> <inState>22</inState> <outState>23</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_309"> <inState>23</inState> <outState>24</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_310"> <inState>24</inState> <outState>25</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_311"> <inState>25</inState> <outState>26</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_312"> <inState>26</inState> <outState>27</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_313"> <inState>27</inState> <outState>28</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_314"> <inState>28</inState> <outState>29</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_315"> <inState>29</inState> <outState>30</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_316"> <inState>30</inState> <outState>31</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_317"> <inState>31</inState> <outState>32</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_318"> <inState>32</inState> <outState>33</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_319"> <inState>33</inState> <outState>34</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_320"> <inState>34</inState> <outState>35</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_321"> <inState>35</inState> <outState>36</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_322"> <inState>36</inState> <outState>37</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_323"> <inState>37</inState> <outState>38</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_324"> <inState>38</inState> <outState>39</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_325"> <inState>39</inState> <outState>40</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_326"> <inState>40</inState> <outState>41</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_327"> <inState>41</inState> <outState>42</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_328"> <inState>42</inState> <outState>43</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_329"> <inState>43</inState> <outState>44</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_330"> <inState>44</inState> <outState>45</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_331"> <inState>45</inState> <outState>46</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_332"> <inState>46</inState> <outState>47</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_333"> <inState>47</inState> <outState>48</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_334"> <inState>48</inState> <outState>49</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_335"> <inState>49</inState> <outState>50</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_336"> <inState>50</inState> <outState>51</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_337"> <inState>51</inState> <outState>52</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_338"> <inState>52</inState> <outState>53</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_339"> <inState>53</inState> <outState>54</outState> <condition> <id>-1</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> </transitions> </fsm> <res class_id="-1"></res> <node_label_latency class_id="35" tracking_level="0" version="0"> <count>12</count> <item_version>0</item_version> <item class_id="36" tracking_level="0" version="0"> <first>15</first> <second class_id="37" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>16</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>17</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>18</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>19</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>20</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>21</first> <second> <first>0</first> <second>52</second> </second> </item> <item> <first>22</first> <second> <first>0</first> <second>52</second> </second> </item> <item> <first>23</first> <second> <first>0</first> <second>52</second> </second> </item> <item> <first>24</first> <second> <first>53</first> <second>0</second> </second> </item> <item> <first>25</first> <second> <first>53</first> <second>0</second> </second> </item> <item> <first>26</first> <second> <first>53</first> <second>0</second> </second> </item> </node_label_latency> <bblk_ent_exit class_id="38" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="39" tracking_level="0" version="0"> <first>27</first> <second class_id="40" tracking_level="0" version="0"> <first>0</first> <second>53</second> </second> </item> </bblk_ent_exit> <regions class_id="41" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </regions> <dp_fu_nodes class_id="42" tracking_level="0" version="0"> <count>11</count> <item_version>0</item_version> <item class_id="43" tracking_level="0" version="0"> <first>28</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>34</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>40</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> <item> <first>46</first> <second> <count>1</count> <item_version>0</item_version> <item>18</item> </second> </item> <item> <first>52</first> <second> <count>1</count> <item_version>0</item_version> <item>19</item> </second> </item> <item> <first>58</first> <second> <count>1</count> <item_version>0</item_version> <item>20</item> </second> </item> <item> <first>64</first> <second> <count>53</count> <item_version>0</item_version> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> </second> </item> <item> <first>80</first> <second> <count>53</count> <item_version>0</item_version> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> </second> </item> <item> <first>96</first> <second> <count>53</count> <item_version>0</item_version> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> </second> </item> <item> <first>112</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> <item> <first>116</first> <second> <count>1</count> <item_version>0</item_version> <item>25</item> </second> </item> </dp_fu_nodes> <dp_fu_nodes_expression class_id="45" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="46" tracking_level="0" version="0"> <first>collisions_fu_116</first> <second> <count>1</count> <item_version>0</item_version> <item>25</item> </second> </item> <item> <first>or_ln170_fu_112</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> </dp_fu_nodes_expression> <dp_fu_nodes_module> <count>3</count> <item_version>0</item_version> <item> <first>grp_checkAxis_0_fu_96</first> <second> <count>53</count> <item_version>0</item_version> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> <item>22</item> </second> </item> <item> <first>grp_checkAxis_1_fu_80</first> <second> <count>53</count> <item_version>0</item_version> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> <item>23</item> </second> </item> <item> <first>grp_checkAxis_2_fu_64</first> <second> <count>53</count> <item_version>0</item_version> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> <item>21</item> </second> </item> </dp_fu_nodes_module> <dp_fu_nodes_io> <count>6</count> <item_version>0</item_version> <item> <first>edge_p1_x_read_read_fu_58</first> <second> <count>1</count> <item_version>0</item_version> <item>20</item> </second> </item> <item> <first>edge_p1_y_read_read_fu_52</first> <second> <count>1</count> <item_version>0</item_version> <item>19</item> </second> </item> <item> <first>edge_p1_z_read_read_fu_46</first> <second> <count>1</count> <item_version>0</item_version> <item>18</item> </second> </item> <item> <first>edge_p2_x_read_read_fu_40</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> <item> <first>edge_p2_y_read_read_fu_34</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>edge_p2_z_read_read_fu_28</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> </dp_fu_nodes_io> <return_ports> <count>0</count> <item_version>0</item_version> </return_ports> <dp_mem_port_nodes class_id="47" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_mem_port_nodes> <dp_reg_nodes> <count>9</count> <item_version>0</item_version> <item> <first>121</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> <item> <first>128</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>135</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> <item> <first>142</first> <second> <count>1</count> <item_version>0</item_version> <item>18</item> </second> </item> <item> <first>149</first> <second> <count>1</count> <item_version>0</item_version> <item>19</item> </second> </item> <item> <first>156</first> <second> <count>1</count> <item_version>0</item_version> <item>20</item> </second> </item> <item> <first>163</first> <second> <count>1</count> <item_version>0</item_version> <item>21</item> </second> </item> <item> <first>168</first> <second> <count>1</count> <item_version>0</item_version> <item>22</item> </second> </item> <item> <first>173</first> <second> <count>1</count> <item_version>0</item_version> <item>23</item> </second> </item> </dp_reg_nodes> <dp_regname_nodes> <count>9</count> <item_version>0</item_version> <item> <first>collisions_x_reg_173</first> <second> <count>1</count> <item_version>0</item_version> <item>23</item> </second> </item> <item> <first>collisions_y_reg_168</first> <second> <count>1</count> <item_version>0</item_version> <item>22</item> </second> </item> <item> <first>collisions_z_reg_163</first> <second> <count>1</count> <item_version>0</item_version> <item>21</item> </second> </item> <item> <first>edge_p1_x_read_reg_156</first> <second> <count>1</count> <item_version>0</item_version> <item>20</item> </second> </item> <item> <first>edge_p1_y_read_reg_149</first> <second> <count>1</count> <item_version>0</item_version> <item>19</item> </second> </item> <item> <first>edge_p1_z_read_reg_142</first> <second> <count>1</count> <item_version>0</item_version> <item>18</item> </second> </item> <item> <first>edge_p2_x_read_reg_135</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> <item> <first>edge_p2_y_read_reg_128</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> <item> <first>edge_p2_z_read_reg_121</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> </dp_regname_nodes> <dp_reg_phi> <count>0</count> <item_version>0</item_version> </dp_reg_phi> <dp_regname_phi> <count>0</count> <item_version>0</item_version> </dp_regname_phi> <dp_port_io_nodes class_id="48" tracking_level="0" version="0"> <count>6</count> <item_version>0</item_version> <item class_id="49" tracking_level="0" version="0"> <first>edge_p1_x</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>20</item> </second> </item> </second> </item> <item> <first>edge_p1_y</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>19</item> </second> </item> </second> </item> <item> <first>edge_p1_z</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>18</item> </second> </item> </second> </item> <item> <first>edge_p2_x</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>17</item> </second> </item> </second> </item> <item> <first>edge_p2_y</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>16</item> </second> </item> </second> </item> <item> <first>edge_p2_z</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>15</item> </second> </item> </second> </item> </dp_port_io_nodes> <port2core class_id="50" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </port2core> <node2core> <count>0</count> <item_version>0</item_version> </node2core> </syndb> </boost_serialization>
with Interfaces.C, System; use type System.Address; package body FLTK.Images.Bitmaps.XBM is function new_fl_xbm_image (F : in Interfaces.C.char_array) return System.Address; pragma Import (C, new_fl_xbm_image, "new_fl_xbm_image"); pragma Inline (new_fl_xbm_image); procedure free_fl_xbm_image (P : in System.Address); pragma Import (C, free_fl_xbm_image, "free_fl_xbm_image"); pragma Inline (free_fl_xbm_image); overriding procedure Finalize (This : in out XBM_Image) is begin if This.Void_Ptr /= System.Null_Address and then This in XBM_Image'Class then free_fl_xbm_image (This.Void_Ptr); This.Void_Ptr := System.Null_Address; end if; Finalize (Bitmap (This)); end Finalize; package body Forge is function Create (Filename : in String) return XBM_Image is begin return This : XBM_Image do This.Void_Ptr := new_fl_xbm_image (Interfaces.C.To_C (Filename)); case fl_image_fail (This.Void_Ptr) is when 1 => raise No_Image_Error; when 2 => raise File_Access_Error; when 3 => raise Format_Error; when others => null; end case; end return; end Create; end Forge; end FLTK.Images.Bitmaps.XBM;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- A D A . R E A L _ T I M E -- -- -- -- B o d y -- -- -- -- Copyright (C) 2001-2014, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNARL was developed by the GNARL team at Florida State University. -- -- Extensive contributions were provided by Ada Core Technologies, Inc. -- -- -- ------------------------------------------------------------------------------ -- This is the Ravenscar version of this package for generic bare board -- targets. Note that the operations here assume that Time is a 64-bit -- unsigned integer and Time_Span is a 64-bit signed integer. with System.Tasking; with System.Task_Primitives.Operations; with Ada.Unchecked_Conversion; package body Ada.Real_Time is pragma Suppress (Overflow_Check); -- This package has careful manual overflow checks, and unsupresses them -- where appropriate. This default enables compilation with checks enabled -- on Ravenscar SFP, where 64-bit multiplication with overflow checking is -- not available. package OSI renames System.OS_Interface; subtype LLI is Long_Long_Integer; ------------------------------------------------------------ -- Handling of Conversions Between Duration and Time_Span -- ------------------------------------------------------------ -- For the To_Duration and To_Time_Span conversion functions, we use the -- intermediate Integer representation of Duration (64-bit) to allow for -- simple Integer operations instead of Float. We take advantage of the -- fact that Duration is represented as an Integer with units of Small. -- Within these conversions we perform the range checks required by -- AI-00432 manually. -- Note that in the past, within To_Duration and To_Time_Span, we were -- first computing the conversion factor between Duration and Time_Span -- (10 ** 9 / Clock_Frecuency) and then we multiplied or divided by it. The -- advantage of this approach was that the operations were simple, and we -- limited a lot the number of occurrences of overflows, but the accuracy -- loss could be significant depending on the clock frequency. For example, -- with a clock frequency of 600 MHz the factor was 1.66, which was rounded -- to 1 (Integer), and hence with a 67% difference. -- We tried also to have a better trade off (Contraint_Error being raised -- when transforming very big values, but limiting a lot the loss of -- accuracy) using Clock_Frequency in MHz instead of Hz. Therefore, we -- multiplied first by 10 ** 3 (or Clock_Frequency / 10 ** 6 which is -- typically smaller than 1000), and hence overflow could occur only with -- really big values). The problem of this approach was that some processor -- frequencies may not be expressed in multiples of MHz (for example, -- 33.3333 MHz). The approach finally followed is to do the operations -- "by hand" on the upper and the lower part of the 64-bit value. This is -- slightly heavier, but we can preserve the best accuracy and the lowest -- occurrence of overflows. ----------------------- -- Local definitions -- ----------------------- type Uint_64 is mod 2 ** 64; -- Type used to represent intermediate results of arithmetic operations Max_Pos_Time_Span : constant := Uint_64 (Time_Span_Last); Max_Neg_Time_Span : constant := Uint_64 (2 ** 63); -- Absolute value of Time_Span_Last and Time_Span_First. Used in overflow -- checks. Note that we avoid using abs on Time_Span_First everywhere. ----------------------- -- Local subprograms -- ----------------------- function To_Duration is new Ada.Unchecked_Conversion (LLI, Duration); function To_Integer is new Ada.Unchecked_Conversion (Duration, LLI); function Mul_Div (V : Uint_64; M : Natural; D : Natural) return Uint_64; -- Compute V * M / D. Constraint_Error is raised in case of overflow, -- results above (2 ** 63) - 1 are considered as overflow. Therefore, -- the result can safely be converted to a signed 64-bit value. --------- -- "*" -- --------- function "*" (Left : Time_Span; Right : Integer) return Time_Span is Is_Negative : constant Boolean := (Left > 0 and then Right < 0) or else (Left < 0 and then Right > 0); -- Sign of the result Max_Value : constant Uint_64 := (if Is_Negative then Max_Neg_Time_Span else Max_Pos_Time_Span); -- Maximum absolute value that can be returned by the multiplication -- taking into account the sign of the operators. Abs_Left : constant Uint_64 := (if Left = Time_Span_First then Max_Neg_Time_Span else Uint_64 (abs (Left))); -- Remove sign of left operator Abs_Right : constant Uint_64 := Uint_64 (abs (LLI (Right))); -- Remove sign of right operator begin -- Overflow check is performed by hand assuming that Time_Span is a -- 64-bit signed integer. Otherwise these checks would need an -- intermediate type with more than 64-bit. The sign of the operators -- is removed to simplify the intermediate computation of the overflow -- check. if Abs_Right /= 0 and then Max_Value / Abs_Right < Abs_Left then raise Constraint_Error; else return Left * Time_Span (Right); end if; end "*"; function "*" (Left : Integer; Right : Time_Span) return Time_Span is begin return Right * Left; end "*"; --------- -- "+" -- --------- function "+" (Left : Time; Right : Time_Span) return Time is begin -- Overflow checks are be performed by hand assuming that Time and -- Time_Span are 64-bit unsigned and signed integers respectively. -- Otherwise these checks would need an intermediate type with more -- than 64 bits. if Right >= 0 and then Uint_64 (Time_Last) - Uint_64 (Left) >= Uint_64 (Right) then return Time (Uint_64 (Left) + Uint_64 (Right)); elsif Right = Time_Span'First and then Left >= Max_Neg_Time_Span then return Time (Uint_64 (Left) - Max_Neg_Time_Span); elsif Right < 0 and then Left >= Time (abs (Right)) then return Time (Uint_64 (Left) - Uint_64 (abs (Right))); else raise Constraint_Error; end if; end "+"; function "+" (Left, Right : Time_Span) return Time_Span is pragma Unsuppress (Overflow_Check); begin return Time_Span (LLI (Left) + LLI (Right)); end "+"; --------- -- "-" -- --------- function "-" (Left : Time; Right : Time_Span) return Time is begin -- Overflow checks must be performed by hand assuming that Time and -- Time_Span are 64-bit unsigned and signed integers respectively. -- Otherwise these checks would need an intermediate type with more -- than 64-bit. if Right >= 0 and then Left >= Time (Right) then return Time (Uint_64 (Left) - Uint_64 (Right)); elsif Right = Time_Span'First and then Uint_64 (Time_Last) - Uint_64 (Left) >= Max_Neg_Time_Span then return Left + Time (Max_Neg_Time_Span); elsif Right < 0 and then Uint_64 (Time_Last) - Uint_64 (Left) >= Uint_64 (abs (Right)) then return Left + Time (abs (Right)); else raise Constraint_Error; end if; end "-"; function "-" (Left, Right : Time) return Time_Span is begin -- Overflow checks must be performed by hand assuming that Time and -- Time_Span are 64-bit unsigned and signed integers respectively. -- Otherwise these checks would need an intermediate type with more -- than 64-bit. if Left >= Right and then Uint_64 (Left) - Uint_64 (Right) <= Uint_64 (Time_Span_Last) then return Time_Span (Uint_64 (Left) - Uint_64 (Right)); elsif Left < Right and then Uint_64 (Right) - Uint_64 (Left) <= Max_Neg_Time_Span then return Time_Span (-(Uint_64 (Right) - Uint_64 (Left))); else raise Constraint_Error; end if; end "-"; function "-" (Left, Right : Time_Span) return Time_Span is pragma Unsuppress (Overflow_Check); begin return Time_Span (LLI (Left) - LLI (Right)); end "-"; function "-" (Right : Time_Span) return Time_Span is pragma Unsuppress (Overflow_Check); begin return Time_Span (-LLI (Right)); end "-"; --------- -- "/" -- --------- function "/" (Left, Right : Time_Span) return Integer is pragma Unsuppress (Overflow_Check); begin return Integer (LLI (Left) / LLI (Right)); end "/"; function "/" (Left : Time_Span; Right : Integer) return Time_Span is pragma Unsuppress (Overflow_Check); begin return Left / Time_Span (Right); end "/"; ----------- -- Clock -- ----------- function Clock return Time is begin return Time (System.Task_Primitives.Operations.Monotonic_Clock); end Clock; ------------------ -- Microseconds -- ------------------ function Microseconds (US : Integer) return Time_Span is begin -- Overflow can't happen (Ticks_Per_Second is Natural) return Time_Span (LLI (US) * LLI (OSI.Ticks_Per_Second)) / Time_Span (10#1#E6); end Microseconds; ------------------ -- Milliseconds -- ------------------ function Milliseconds (MS : Integer) return Time_Span is begin -- Overflow can't happen (Ticks_Per_Second is Natural) return Time_Span (LLI (MS) * LLI (OSI.Ticks_Per_Second)) / Time_Span (10#1#E3); end Milliseconds; ------------- -- Minutes -- ------------- function Minutes (M : Integer) return Time_Span is Min_M : constant LLI := LLI'First / LLI (OSI.Ticks_Per_Second); Max_M : constant LLI := LLI'Last / LLI (OSI.Ticks_Per_Second); -- Bounds for Sec_M. Note that we can't use unsupress overflow checks, -- as this would require the use of arit64 Sec_M : constant LLI := LLI (M) * 60; -- M converted to seconds begin if Sec_M < Min_M or else Sec_M > Max_M then raise Constraint_Error; else return Time_Span (Sec_M * LLI (OSI.Ticks_Per_Second)); end if; end Minutes; ----------------- -- Nanoseconds -- ----------------- function Nanoseconds (NS : Integer) return Time_Span is begin -- Overflow can't happen (Ticks_Per_Second is Natural) return Time_Span (LLI (NS) * LLI (OSI.Ticks_Per_Second)) / Time_Span (10#1#E9); end Nanoseconds; ------------- -- Seconds -- ------------- function Seconds (S : Integer) return Time_Span is begin -- Overflow can't happen (Ticks_Per_Second is Natural) return Time_Span (LLI (S) * LLI (OSI.Ticks_Per_Second)); end Seconds; ----------- -- Split -- ----------- procedure Split (T : Time; SC : out Seconds_Count; TS : out Time_Span) is Res : constant Time := Time (OSI.Ticks_Per_Second); begin SC := Seconds_Count (T / Res); TS := T - Time (SC) * Res; end Split; ------------- -- Time_Of -- ------------- function Time_Of (SC : Seconds_Count; TS : Time_Span) return Time is Res : constant Time := Time (OSI.Ticks_Per_Second); begin if Time_Last / Res < Time (SC) then raise Constraint_Error; else return Time (SC) * Res + TS; end if; end Time_Of; ------------- -- Mul_Div -- ------------- function Mul_Div (V : Uint_64; M : Natural; D : Natural) return Uint_64 is -- Upper case letters represent one word (32-bit words in our case). -- If we can compute, PQ = AB / D, then we can compute ABC / D using -- the following method (pencil and paper algorithm): -- MN := AB / D (first quotient) -- R := AB - MN * D (remainder on one word, as R < D) -- OP := RC / D (second quotient) -- res := MN0 + OP -- We check absence of overflow in the final result by checking that -- M is 0, and that there is no carry when adding N0 and OP. -- Initially, A = 0, BC = V V_Hi : Uint_64 := V / 2 ** 32; -- AB V_Lo : Uint_64 := V rem 2 ** 32; -- C Result_Hi : Uint_64; -- High part of the result Result_Lo : Uint_64; -- Low part of the result Remainder : Uint_64; -- Remainder of the first division (denoted R above) begin -- Multiply V by M V_Hi := V_Hi * Uint_64 (M); V_Lo := V_Lo * Uint_64 (M); V_Hi := V_Hi + V_Lo / 2 ** 32; V_Lo := V_Lo rem 2 ** 32; -- First quotient Result_Hi := V_Hi / Uint_64 (D); if Result_Hi > (2 ** 31 - 1) then -- The final result conversion would overflow: Result_Hi will be -- the high 32 bit part of the result. raise Constraint_Error; end if; Remainder := V_Hi - Result_Hi * Uint_64 (D); Result_Hi := Result_Hi * 2 ** 32; -- Second quotient. To improve rounding, D / 2 is added Result_Lo := (V_Lo + Remainder * 2 ** 32 + Uint_64 (D / 2)) / Uint_64 (D); if Result_Lo > (2 ** 63 - 1) - Result_Hi then -- The final conversion for the result (just below) would overflow raise Constraint_Error; end if; return Result_Hi + Result_Lo; end Mul_Div; ----------------- -- To_Duration -- ----------------- function To_Duration (TS : Time_Span) return Duration is Duration_Units : constant Natural := Natural (1.0 / Duration'Small); -- Number of units of Duration in one second. The result is correct -- (not rounded) as Duration'Small is 10.0**(-9) Result : LLI; -- Contains the temporary result Is_Negative : constant Boolean := TS < 0; -- Remove the sign to simplify the intermediate computations TPS : constant Natural := OSI.Ticks_Per_Second; -- Capture ticks per second value begin -- See comment at the beginning of this file about this implementation -- We need to accurately compute TS * Duration_Units / Ticks_Per_Second -- TS being a 64-bit integer, both Duration_Units and Ticks_Per_Second -- are 32-bit integers. Result := (if TS = Time_Span'First then LLI (Mul_Div (Max_Neg_Time_Span, Duration_Units, TPS)) else LLI (Mul_Div (Uint_64 (abs TS), Duration_Units, TPS))); -- Handle the sign of the result if Is_Negative then Result := -Result; end if; return To_Duration (Result); end To_Duration; ------------------ -- To_Time_Span -- ------------------ function To_Time_Span (D : Duration) return Time_Span is Duration_Units : constant Natural := Natural (1.0 / Duration'Small); -- Number of units of Duration in one second Result : LLI; -- Contains the temporary results Is_Negative : constant Boolean := D < 0.0; -- Remove the sign to simplify the intermediate computations begin -- See comment at the beginning of this file about this implementation Result := LLI (Mul_Div (Uint_64 (abs To_Integer (D)), OSI.Ticks_Per_Second, Duration_Units)); -- Handle the sign of the result if Is_Negative then Result := -Result; end if; return Time_Span (Result); end To_Time_Span; begin -- Ensure that the tasking run time is initialized when using clock and/or -- delay operations. The initialization routine has the required machinery -- to prevent multiple calls to Initialize. System.Tasking.Initialize; end Ada.Real_Time;
------------------------------------------------------------------------------- -- package body Fourier8, a fast fourier transform -- Copyright (C) 1995-2018 Jonathan S. Parker -- -- Permission to use, copy, modify, and/or distribute this software for any -- purpose with or without fee is hereby granted, provided that the above -- copyright notice and this permission notice appear in all copies. -- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ------------------------------------------------------------------------------- with Ada.Numerics.Generic_Elementary_Functions; package body Fourier8 is package math is new Ada.Numerics.Generic_Elementary_Functions (Real); use math; subtype Exponent_Of_Two_Type is Natural range 0 .. Log_Of_Max_Data_Length; -------------------- -- Make_Exp_Table -- -------------------- -- Make_Exp_Table calculates points on the unit circle -- starting at Theta = 0 and ending near Theta = -Pi. The -- points are separated by Theta = 2*Pi/N. In other words, the -- bottom half of the unit circle is divided into N/2 equally spaced -- points. These points are then stored in the array Exp_Table. -- For efficiency, only the 1st eighth of the unit circle -- is calculated. The other points are inferred from that. Exp_Table -- is defined Exp (-i * Two_Pi_Over_N * Data_Index) where Data_Index -- is in the range 0 .. N/2 - 1 and N is the Data length, the power of -- 2 that appears in Two_Pi_Over_N. procedure Make_Exp_Table (Padded_Data_Index_Last : in Data_Index; Exp_Table : in out Exp_Storage) is Pii : constant Real := 3.14159_26535_89793_23846_26433_83279_50288; Sqrt_Half : constant Real := 0.70710_67811_86547_52440_08443_62104_84904; Two_Pi_Over_N : constant Real := 2.0 * Pii / (Real (Padded_Data_Index_Last) + 1.0); C, S : Real; Theta : Real; -- Divide the unit circle into 2**M = Padded_Data_Index_Last+1 points. -- Divide the unit circle into eighths and quadrants: StartOf1stQuadrant : constant Data_Index := 0; StartOf2ndEighth : constant Data_Index := Padded_Data_Index_Last / 8 + 1; StartOf2ndQuadrant : constant Data_Index := Padded_Data_Index_Last / 4 + 1; StartOf3rdQuadrant : constant Data_Index := Padded_Data_Index_Last / 2 + 1; StartOf4rthEighth : constant Data_Index := StartOf2ndEighth * 3; begin if Padded_Data_Index_Last = 0 then -- 1 data point null; elsif Padded_Data_Index_Last = 1 then -- 2 data points Exp_Table.Re(StartOf1stQuadrant) := 1.0; Exp_Table.Im(StartOf1stQuadrant) := 0.0; elsif Padded_Data_Index_Last = 3 then -- 4 data points Exp_Table.Re(StartOf1stQuadrant) := 1.0; Exp_Table.Im(StartOf1stQuadrant) := 0.0; Exp_Table.Re(StartOf2ndQuadrant) := 0.0; Exp_Table.Im(StartOf2ndQuadrant) := -1.0; elsif Padded_Data_Index_Last >= 7 then -- 8 data points and higher: Exp_Table.Re(StartOf1stQuadrant) := 1.0; Exp_Table.Im(StartOf1stQuadrant) := 0.0; Exp_Table.Re(StartOf2ndEighth) := Sqrt_Half; Exp_Table.Im(StartOf2ndEighth) := -Sqrt_Half; Exp_Table.Re(StartOf2ndQuadrant) := 0.0; Exp_Table.Im(StartOf2ndQuadrant) := -1.0; Exp_Table.Re(StartOf4rthEighth) := -Sqrt_Half; Exp_Table.Im(StartOf4rthEighth) := -Sqrt_Half; for Mode in Exp_Mode_Index range 1..StartOf2ndEighth-1 loop Theta := Two_Pi_Over_N * Real(Mode); C := Cos (Theta); S := Sin (Theta); Exp_Table.Re(StartOf1stQuadrant + Mode) := C; Exp_Table.Im(StartOf1stQuadrant + Mode) := -S; Exp_Table.Re(StartOf2ndQuadrant + Mode) := -S; Exp_Table.Im(StartOf2ndQuadrant + Mode) := -C; Exp_Table.Re(StartOf2ndQuadrant - Mode) := S; Exp_Table.Im(StartOf2ndQuadrant - Mode) := -C; Exp_Table.Re(StartOf3rdQuadrant - Mode) := -C; Exp_Table.Im(StartOf3rdQuadrant - Mode) := -S; end loop; end if; Exp_Table.Current_Size_Of_Exp_Table := Padded_Data_Index_Last; -- This global variable is initalized to 0. This tells the FFT routine -- whether to reconstruct Exp_Table when it's called again. The table -- must be reconstructed whenever Padded_Data_Index_Last changes. end Make_Exp_Table; -------------------------- -- Get_Bit_Reversal_Of -- -------------------------- -- Radix 4 Bit_Reversal using bits 0..Top_Bit. procedure Get_Bit_Reversal_Of (Data_Re, Data_Im : in out Data_Array; Two_To_The_Top_Bit : in Data_Index; Half_Two_To_The_Top_Bit : in Data_Index; Quarter_Two_To_The_Top_Bit : in Data_Index; Top_Bit : in Exponent_Of_Two_Type) is Temp : Real; K, Bit_Reversed_K, Power_Of_Two : Data_Index; Two_To_Top_Bit_minus_Two_To_lesser_Bit : constant Data_Index := Two_To_The_Top_Bit - Half_Two_To_The_Top_Bit; Two_To_Top_Bit_plus_Two_To_lesser_Bit : constant Data_Index := Two_To_The_Top_Bit + Half_Two_To_The_Top_Bit; begin -- No_Of_Data_points = 2**(Top_Bit+1) <= 2: if Top_Bit = 0 then return; end if; -- No_Of_Data_points = 2**(Top_Bit+1) = 4: if Top_Bit = 1 then Temp := Data_Re(2); Data_Re(2) := Data_Re(1); Data_Re(1) := Temp; Temp := Data_Im(2); Data_Im(2) := Data_Im(1); Data_Im(1) := Temp; return; end if; -- No_Of_Data_points = 2**(Top_Bit+1) >= 8: K := 0; Bit_Reversed_K := 0; for count in 0..Half_Two_To_The_Top_Bit-2 loop -- now K = 00xxxxxxxxxxx and Bit_Reversed_K = xxxxxxxxxxxx00 K := K + 1; Bit_Reversed_K := Bit_Reversed_K + Two_To_The_Top_Bit; if K < Bit_Reversed_K then Temp := Data_Re (Bit_Reversed_K); Data_Re(Bit_Reversed_K) := Data_Re(K); Data_Re(K) := Temp; Temp := Data_Im (Bit_Reversed_K); Data_Im(Bit_Reversed_K) := Data_Im(K); Data_Im(K) := Temp; end if; -- now K = 10xxxxxxxxxxx and Bit_Reversed_K = xxxxxxxxxxxx01 K := K + 1; Bit_Reversed_K := Bit_Reversed_K - Two_To_Top_Bit_minus_Two_To_lesser_Bit; if K < Bit_Reversed_K then Temp := Data_Re (Bit_Reversed_K); Data_Re(Bit_Reversed_K) := Data_Re(K); Data_Re(K) := Temp; Temp := Data_Im (Bit_Reversed_K); Data_Im(Bit_Reversed_K) := Data_Im(K); Data_Im(K) := Temp; end if; -- now K = 01xxxxxxxxxxx xxxxxxxxxxxx10 K := K + 1; Bit_Reversed_K := Bit_Reversed_K + Two_To_The_Top_Bit; if K < Bit_Reversed_K then Temp := Data_Re (Bit_Reversed_K); Data_Re(Bit_Reversed_K) := Data_Re(K); Data_Re(K) := Temp; Temp := Data_Im (Bit_Reversed_K); Data_Im(Bit_Reversed_K) := Data_Im(K); Data_Im(K) := Temp; end if; -- now K = 11xxxxxxxxxxx xxxxxxxxxxxx11 K := K + 1; Bit_Reversed_K := Bit_Reversed_K - Two_To_Top_Bit_plus_Two_To_lesser_Bit; Power_Of_Two := Quarter_Two_To_The_Top_Bit; -- 2**(Top_Bit-2) Bit_Reverse_K_Plus_1: for Exponent in reverse 0..Top_Bit-2 loop if Bit_Reversed_K < Power_Of_Two then -- B_R_K has a '0' at position Exponent. Put a '1' there: Bit_Reversed_K := Bit_Reversed_K + Power_Of_Two; exit Bit_Reverse_K_Plus_1; else -- B_R_K has a '1' at position Exponent. Put a '0' there: Bit_Reversed_K := Bit_Reversed_K - Power_Of_Two; Power_Of_Two := Power_Of_Two / 2; end if; end loop Bit_Reverse_K_Plus_1; if K < Bit_Reversed_K then Temp := Data_Re (Bit_Reversed_K); Data_Re(Bit_Reversed_K) := Data_Re(K); Data_Re(K) := Temp; Temp := Data_Im (Bit_Reversed_K); Data_Im(Bit_Reversed_K) := Data_Im(K); Data_Im(K) := Temp; end if; end loop; -- now K = 00xxxxxxxxxxx xxxxxxxxxxxx00 K := K + 1; Bit_Reversed_K := Bit_Reversed_K + Two_To_The_Top_Bit; if K < Bit_Reversed_K then Temp := Data_Re (Bit_Reversed_K); Data_Re(Bit_Reversed_K) := Data_Re(K); Data_Re(K) := Temp; Temp := Data_Im (Bit_Reversed_K); Data_Im(Bit_Reversed_K) := Data_Im(K); Data_Im(K) := Temp; end if; -- now K = 10xxxxxxxxxxx xxxxxxxxxxxx01 K := K + 1; Bit_Reversed_K := Bit_Reversed_K - Two_To_Top_Bit_minus_Two_To_lesser_Bit; if K < Bit_Reversed_K then Temp := Data_Re (Bit_Reversed_K); Data_Re(Bit_Reversed_K) := Data_Re(K); Data_Re(K) := Temp; Temp := Data_Im (Bit_Reversed_K); Data_Im(Bit_Reversed_K) := Data_Im(K); Data_Im(K) := Temp; end if; end Get_Bit_Reversal_Of; pragma Inline (Get_Bit_Reversal_Of); --------- -- FFT -- --------- procedure FFT (Data_Re, Data_Im : in out Data_Array; Transformed_Data_Last : out Data_Index; Input_Data_Last : in Data_Index; Exp_Table : in out Exp_Storage; Inverse_FFT_Desired : in Boolean := False; Normalized_Data_Desired : in Boolean := False; Bit_Reversal_Desired : in Boolean := True) is Sqrt_Half : constant Real := 0.70710_67811_86547_52440_08443_62104_84904; -- Indexing for the FFT Flock_Width, Start_Of_Butterfly, Start_Of_Flock : Data_Index; Butterflies_Per_Flock : Data_Index; Butterflies_Per_Flock2 : Data_Index; Butterflies_Per_Flock3 : Data_Index; Butterflies_Per_Flock4 : Data_Index; Butterflies_Per_Flock5 : Data_Index; Butterflies_Per_Flock6 : Data_Index; Butterflies_Per_Flock7 : Data_Index; No_Of_Butterfly_Flocks : Data_Index; Next_Butterfly : Data_Index; Padded_Data_Index_Last : Data_Index; Half_Data, Quarter_Data, Eighth_Data : Data_Index; Log_Of_Data_Length_Minus_1 : Exponent_Of_Two_Type; Radix_2_Stage_Last : Exponent_Of_Two_Type; Radix_8_Stage_Last : Exponent_Of_Two_Type; No_Of_Radix_8_Stages : Data_Index; No_Of_Radix_4_Stages : Data_Index; No_Of_Radix_2_Stages : Data_Index; Remaining_Radix_2_Stages : Data_Index; Log_Of_Data_Length : Data_Index; No_Of_Preliminary_Radix_8_Stages : Data_Index; Final_Stage_Is_A_Radix_8_Stage : Boolean; Final_Stage_Is_A_Radix_4_Stage : Boolean; Final_Stage_Is_A_Radix_2_Stage : Boolean; NormalizationFactor : Real := 1.0; -- For Radix 2 butterflies DataTop_Re, DataBot_Re : Real; DataTop_Im, DataBot_Im : Real; -- For Radix 4 butterflies Data02sum_Re, Data02sum_Im, Data02del_Re, Data02del_Im : Real; Data13sum_Re, Data13sum_Im, Data13del_Re, Data13del_Im : Real; -- For Radix 8 butterflies D0_Re, D1_Re, D2_Re, D3_Re, D4_Re, D5_Re, D6_Re, D7_Re : Real; D0_Im, D1_Im, D2_Im, D3_Im, D4_Im, D5_Im, D6_Im, D7_Im : Real; D04sum_Re, D15sum_Re, D26sum_Re, D37sum_Re : Real; D04sum_Im, D15sum_Im, D26sum_Im, D37sum_Im : Real; D04del_Re, D15del_Re, D26del_Re, D37del_Re : Real; D04del_Im, D15del_Im, D26del_Im, D37del_Im : Real; D1537sum_Re, D1537sum_Im, D1537del_Re, D1537del_Im : Real; Sqrt_sum_Re, Sqrt_sum_Im, Sqrt_del_Re, Sqrt_del_Im : Real; D04del26sum_Im, D04del26sum_Re, D04del26del_Re, D04del26del_Im : Real; D04sum26sum_Re, D04sum26sum_Im, D04sum26del_Re, D04sum26del_Im : Real; D15sum37sum_Re, D15sum37sum_Im, D15sum37del_Re, D15sum37del_Im : Real; Temp_Re, Temp_Im : Real; Exp1_Re, Exp2_Re, Exp3_Re : Real; Exp1_Im, Exp2_Im, Exp3_Im : Real; Exp4_Re, Exp5_Re, Exp6_Re, Exp7_Re : Real; Exp4_Im, Exp5_Im, Exp6_Im, Exp7_Im : Real; Index0, Index1, Index2, Index3 : Data_Index; Index4, Index5, Index6, Index7 : Data_Index; Exp_Id, E_low : Data_Index; ------------------ -- Integer_Log2 -- ------------------ -- Rounds down, so on range (eg) 0..2**15-1 it returns 0 .. 14 -- returns 0 for I in 0..1 -- returns 1 for I in 2..3, etc. function Integer_Log2 (I : Data_Index) return Exponent_Of_Two_Type is Log2 : Exponent_Of_Two_Type := 0; begin for Exponent in Exponent_Of_Two_Type loop exit when 2**Exponent > I; log2 := Exponent; end loop; return Log2; end Integer_Log2; begin -- Step 1. The FFT of a data set of length 1 is itself. -- So leave the data unchanged, and return. if Input_Data_Last < 1 then Padded_Data_Index_Last := 0; Transformed_Data_Last := 0; return; end if; -- Step 2. -- Pad the data with zeros -- out to the nearest power of 2. First must find what -- that power of 2 is, so use Integer_Log2 (Input_Data_Last). -- Integer_Log2 rounds down so LogOf.. is in Exponent_Of_Two_Type range. -- This is LogOfDataSize - 1, not LogOf(DataSize-1). The length of the -- padded data is twice 2**Log_Of_Data_Length_Minus_1 Log_Of_Data_Length_Minus_1 := Integer_Log2 (Input_Data_Last); Half_Data := 2 ** Integer (Log_Of_Data_Length_Minus_1); Quarter_Data := Half_Data / 2; -- Could be 0 Eighth_Data := Half_Data / 4; -- Could be 0 Padded_Data_Index_Last := Half_Data - 1; Padded_Data_Index_Last := Padded_Data_Index_Last + Half_Data; -- Pad with zeros: if Input_Data_Last < Data_Index'Last then for I in Input_Data_Last+1..Padded_Data_Index_Last loop Data_Re (I) := 0.0; end loop; for I in Input_Data_Last+1..Padded_Data_Index_Last loop Data_Im (I) := 0.0; end loop; end if; -- Step 2b. Must must decide how many Radix 8, 4, and 2 stages to take. -- Radix 2 stage will be the final stage if it is required. For a -- Radix 2 FFT, Stages is in 0..Log_Of_Data_Length_Minus_1. Log_Of_Data_Length := Data_Index (Log_Of_Data_Length_Minus_1) + 1; Remaining_Radix_2_Stages := Log_Of_Data_Length; No_Of_Radix_8_Stages := Remaining_Radix_2_Stages / 3; Remaining_Radix_2_Stages := Remaining_Radix_2_Stages-No_Of_Radix_8_Stages*3; No_Of_Radix_4_Stages := Remaining_Radix_2_Stages / 2; Remaining_Radix_2_Stages := Remaining_Radix_2_Stages-No_Of_Radix_4_Stages*2; No_Of_Radix_2_Stages := Remaining_Radix_2_Stages; Final_Stage_Is_A_Radix_8_Stage := False; Final_Stage_Is_A_Radix_4_Stage := False; Final_Stage_Is_A_Radix_2_Stage := False; if No_Of_Radix_2_Stages > 0 then Final_Stage_Is_A_Radix_2_Stage := True; elsif No_Of_Radix_4_Stages > 0 then Final_Stage_Is_A_Radix_4_Stage := True; elsif No_Of_Radix_8_Stages > 0 then Final_Stage_Is_A_Radix_8_Stage := True; end if; No_Of_Preliminary_Radix_8_Stages := No_Of_Radix_8_Stages; if Final_Stage_Is_A_Radix_8_Stage then -- have Radix_8_Stages > 0 No_Of_Preliminary_Radix_8_Stages := No_Of_Radix_8_Stages - 1; end if; -- Step 3. If haven't done so already, construct the table -- of SIN and COS functions (actually exp(-i*theta)). -- Dont need to remake it if it has already been constructed -- for the right value of Padded_Data_Index_Last. if not (Exp_Table.Current_Size_Of_Exp_Table = Padded_Data_Index_Last) then Make_Exp_Table (Padded_Data_Index_Last, Exp_Table); end if; -- here inline the Inverse (backward) fft by hand: if Inverse_FFT_Desired then -- Step 5a. Perform the FFT radix 8 Stages on 0..Radix_8_Stage_Last -- Each "Butterfly" has 8 inputs on the left, and 8 outputs on the right. -- The 8 on the left (input) are at indices n, n+N/8, n+N/4, n+3N/8 etc. -- Index n is in the range 0..N/8-1, where N is the Data_Length, a power of 2. -- The output data points (on the right) are at the same points. -- The above is for stage 0. At state 1, just replace the N by N/8. -- -- The Radix 8 stage is really a series of 8 point DFT's. The Radix -- 2 stage is a series of 2 point DFT's. We want the output of a single -- Radix 8 stage to be identical to the output of 3 Radix 2 stages. -- Therefore have to make sure that the 8 x 8 DFT's produces -- bit-reversed output just like results of 3 radix 2 stages, so -- have to artifically bit-reverse the results of the 8 x 8. To bit -- reverse an 8 pt DFT, just swap items 1 and 4, and items 3 and 6. -- -- Stage 0 prepares Data so that the N pt DFT can be done by eight N/8 -- pt DFT's in stage 1. Instead of performing the 8 DFT's, Stage 1 prepares -- the Data so the eight N/8 pt DFT's can each be -- done by eight N/64 pt. DFT's in stage 2. The value N/8 in Stage=0 is called -- Butterflies_Per_Flock. Since each butterfly has 8 outputs, the -- N/8 butterflies of stage 0 comprise the entire data set. At stage 0, with -- N/8 butterflies, say Flock_Width = N and No_Of_Butterfly_Flocks = 1. -- At Stage 1, with N/64 butterflies (for each of the 8 DFT's), say -- Flock_Width = N/8, and No_Of_Butterfly_Flocks = 8. if No_Of_Preliminary_Radix_8_Stages > 0 then Radix_8_Stage_Last:=Exponent_Of_Two_Type(No_Of_Preliminary_Radix_8_Stages-1); for Stage in 0 .. Radix_8_Stage_Last loop No_Of_Butterfly_Flocks := 2 ** Integer(3*Stage); Butterflies_Per_Flock := Eighth_Data / No_Of_Butterfly_Flocks; Butterflies_Per_Flock2 := Butterflies_Per_Flock + Butterflies_Per_Flock; Butterflies_Per_Flock3 := Butterflies_Per_Flock2 + Butterflies_Per_Flock; Butterflies_Per_Flock4 := Butterflies_Per_Flock2 + Butterflies_Per_Flock2; Butterflies_Per_Flock5 := Butterflies_Per_Flock2 + Butterflies_Per_Flock3; Butterflies_Per_Flock6 := Butterflies_Per_Flock2 + Butterflies_Per_Flock4; Butterflies_Per_Flock7 := Butterflies_Per_Flock2 + Butterflies_Per_Flock5; -- Butterflies_Per_Flock is in the range Eighth_Data..1 -- No_Of_Butterfly_Flocks is in the range 1..Eighth_Data Flock_Width := 0; -- Flock width overflows if Stage = 0. if Stage > 0 then Flock_Width := 8 * Butterflies_Per_Flock; end if; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop Next_Butterfly := No_Of_Butterfly_Flocks * Butterfly_ID; -- table holds fft exps, not inverse fft, -- so must change sign of imag. parts: Exp_Id := Next_Butterfly; Exp1_Re := Exp_Table.Re(Exp_Id); Exp1_Im := -Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; Exp2_Re := Exp_Table.Re(Exp_Id); Exp2_Im := -Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; Exp3_Re := Exp_Table.Re(Exp_Id); Exp3_Im := -Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; Exp4_Re := Exp_Table.Re(Exp_Id); Exp4_Im := -Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; if Exp_Id < Half_Data then Exp5_Re := Exp_Table.Re(Exp_Id); Exp5_Im := -Exp_Table.Im(Exp_Id); else E_low := Exp_Id - Half_Data; Exp5_Re := -Exp_Table.Re(E_low); Exp5_Im := Exp_Table.Im(E_low); end if; Exp_Id := Exp_Id + Next_Butterfly; if Exp_Id < Half_Data then Exp6_Re := Exp_Table.Re(Exp_Id); Exp6_Im := -Exp_Table.Im(Exp_Id); else E_low := Exp_Id - Half_Data; Exp6_Re := -Exp_Table.Re(E_low); Exp6_Im := Exp_Table.Im(E_low); end if; Exp_Id := Exp_Id + Next_Butterfly; if Exp_Id < Half_Data then Exp7_Re := Exp_Table.Re(Exp_Id); Exp7_Im := -Exp_Table.Im(Exp_Id); else E_low := Exp_Id - Half_Data; Exp7_Re := -Exp_Table.Re(E_low); Exp7_Im := Exp_Table.Im(E_low); end if; -- Next want to perform the 8 pt. Fourier Trans. on butterfly -- with ID = Butterfly_ID, in the Flock with ID = Flock_ID. The -- span of a flock is 8 times the number of butterflies in the -- flock. So the start of the Flock is at Flock_ID * Span, -- and add on to that Butterfly_ID to get the start of the -- desired butterfly. The index of the start of the butterfly -- is called K: -- Here is the abstract version of the inner loop, commented out. -- Below it is unrolled by hand to make it more efficient under -- gcc/gnat. -- -- must change sign of imag. partsfor inverse fft: -- -- D0new := ((D0+D4) + (D2+D6) + ( (D1+D5) + (D3+D7))) * Exp0; -- D2new := ((D0+D4) - (D2+D6) - i*( (D1+D5) - (D3+D7))) * Exp2; -- D4new := ((D0+D4) + (D2+D6) - ( (D1+D5) + (D3+D7))) * Exp4; -- D6new := ((D0+D4) - (D2+D6) + i*( (D1+D5) - (D3+D7))) * Exp6; -- -- D1new := ((D0-D4) - i(D2-D6) + a( 1-i)*(D1-D5) + a(-1-i)*(D3-D7))*Exp1; -- D3new := ((D0-D4) + i(D2-D6) + a(-1-i)*(D1-D5) + a( 1-i)*(D3-D7))*Exp3; -- D5new := ((D0-D4) - i(D2-D6) + a(-1+i)*(D1-D5) + a( 1+i)*(D3-D7))*Exp5; -- D7new := ((D0-D4) + i(D2-D6) + a( 1+i)*(D1-D5) + a(-1+i)*(D3-D7))*Exp7; -- -- The last set can be written: -- --D1new = ((D0-D4) - i(D2-D6) - a(i((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7))))*Exp1; --D3new = ((D0-D4) + i(D2-D6) - a(i((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7))))*Exp3; --D5new = ((D0-D4) - i(D2-D6) + a(i((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7))))*Exp5; --D7new = ((D0-D4) + i(D2-D6) + a(i((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7))))*Exp7; -- for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index4 := Start_Of_Butterfly + Butterflies_Per_Flock4; D0_Re := Data_Re (Index0); D0_Im := Data_Im (Index0); D4_Re := Data_Re (Index4); D4_Im := Data_Im (Index4); D04sum_Re := D0_Re + D4_Re; D04sum_Im := D0_Im + D4_Im; D04del_Re := D0_Re - D4_Re; D04del_Im := D0_Im - D4_Im; Index2 := Start_Of_Butterfly + Butterflies_Per_Flock2; Index6 := Start_Of_Butterfly + Butterflies_Per_Flock6; D2_Re := Data_Re (Index2); D2_Im := Data_Im (Index2); D6_Re := Data_Re (Index6); D6_Im := Data_Im (Index6); D26sum_Re := D2_Re + D6_Re; D26sum_Im := D2_Im + D6_Im; D26del_Re := D2_Re - D6_Re; D26del_Im := D2_Im - D6_Im; D04sum26sum_Re := D04sum_Re + D26sum_Re; D04sum26sum_Im := D04sum_Im + D26sum_Im; D04sum26del_Re := D04sum_Re - D26sum_Re; D04sum26del_Im := D04sum_Im - D26sum_Im; -- D04del26sum := D04del + Im*D26del; D04del26sum_Re := D04del_Re - D26del_Im; D04del26sum_Im := D04del_Im + D26del_Re; -- D04del26del := D04del - Im*D26del; D04del26del_Re := D04del_Re + D26del_Im; D04del26del_Im := D04del_Im - D26del_Re; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; Index5 := Start_Of_Butterfly + Butterflies_Per_Flock5; D1_Re := Data_Re (Index1); D1_Im := Data_Im (Index1); D5_Re := Data_Re (Index5); D5_Im := Data_Im (Index5); D15sum_Re := D1_Re + D5_Re; D15sum_Im := D1_Im + D5_Im; D15del_Re := D1_Re - D5_Re; D15del_Im := D1_Im - D5_Im; Index3 := Start_Of_Butterfly + Butterflies_Per_Flock3; Index7 := Start_Of_Butterfly + Butterflies_Per_Flock7; D3_Re := Data_Re (Index3); D3_Im := Data_Im (Index3); D7_Re := Data_Re (Index7); D7_Im := Data_Im (Index7); D37sum_Re := D3_Re + D7_Re; D37sum_Im := D3_Im + D7_Im; D37del_Re := D3_Re - D7_Re; D37del_Im := D3_Im - D7_Im; D15sum37sum_Re := D15sum_Re + D37sum_Re; D15sum37sum_Im := D15sum_Im + D37sum_Im; D15sum37del_Re := D15sum_Re - D37sum_Re; D15sum37del_Im := D15sum_Im - D37sum_Im; D1537sum_Re := D15del_Re + D37del_Re; D1537sum_Im := D15del_Im + D37del_Im; D1537del_Re := D15del_Re - D37del_Re; D1537del_Im := D15del_Im - D37del_Im; -- D0new := ((D0+D4) + (D2+D6) + ( (D1+D5) + (D3+D7))) * Exp0; -- Data(Index0) := D04sum + D26sum + D15sum + D37sum; Temp_Re := D04sum26sum_Re + D15sum37sum_Re; Temp_Im := D04sum26sum_Im + D15sum37sum_Im; Data_Re (Index0) := Temp_Re; Data_Im (Index0) := Temp_Im; -- Inverse FFT: change sign of i: -- D2new := ((D0+D4) - (D2+D6) + i*((D1+D5) - (D3+D7))) * Exp2; -- Data(Index2) := (D04sum - D26sum + Im * (D15sum - D37sum)) * Exp2; Temp_Re := D04sum26del_Re - D15sum37del_Im; Temp_Im := D04sum26del_Im + D15sum37del_Re; Data_Re (Index2) := Temp_Re*Exp2_Re - Temp_Im*Exp2_Im; Data_Im (Index2) := Temp_Re*Exp2_Im + Temp_Im*Exp2_Re; -- D4new := ((D0+D4) + (D2+D6) - ((D1+D5) + (D3+D7))) * Exp4; -- Data(Index1) := (D04sum + D26sum - (D15sum + D37sum)) * Exp4; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04sum26sum_Re - D15sum37sum_Re; Temp_Im := D04sum26sum_Im - D15sum37sum_Im; Data_Re (Index1) := Temp_Re*Exp4_Re - Temp_Im*Exp4_Im; Data_Im (Index1) := Temp_Re*Exp4_Im + Temp_Im*Exp4_Re; -- Inverse FFT: change sign of i: -- D6new := ((D0+D4) - (D2+D6) - i*((D1+D5) - (D3+D7))) * Exp6; -- Data(Index3) := (D04sum - D26sum - Im*(D15sum - D37sum)) * Exp6; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04sum26del_Re + D15sum37del_Im; Temp_Im := D04sum26del_Im - D15sum37del_Re; Data_Re (Index3) := Temp_Re*Exp6_Re - Temp_Im*Exp6_Im; Data_Im (Index3) := Temp_Re*Exp6_Im + Temp_Im*Exp6_Re; -- Inverse FFT: change sign of i: -- Sqrt_Del := a(-i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); Sqrt_Del_Re := Sqrt_Half * ( D1537sum_Im - D1537del_Re); Sqrt_Del_Im := Sqrt_Half * (-D1537sum_Re - D1537del_Im); -- Inverse FFT: change sign of i: -- Sqrt_Sum := a(-i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); Sqrt_Sum_Re := Sqrt_Half * ( D1537sum_Im + D1537del_Re); Sqrt_Sum_Im := Sqrt_Half * (-D1537sum_Re + D1537del_Im); -- Inverse FFT: change sign of i: -- D04del26sum := D04del + Im*D26del; -- Sqrt_Del := a(-i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); -- D1new := ((D0-D4) + i(D2-D6)) - Sqrt_Del) * Exp1 -- Data(Index4) := (D04del + Im*D26del - Sqrt_Del) * Exp1; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04del26sum_Re - Sqrt_del_Re; Temp_Im := D04del26sum_Im - Sqrt_del_Im; Data_Re (Index4) := Temp_Re*Exp1_Re - Temp_Im*Exp1_Im; Data_Im (Index4) := Temp_Re*Exp1_Im + Temp_Im*Exp1_Re; -- Inverse FFT: change sign of i: -- D04del26del := D04del - Im*D26del; -- Sqrt_Sum := a(-i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); -- D3new := ((D0-D4) - i(D2-D6)) - Sqrt_Sum) * Exp3; -- Data(Index6) := (D04del - Im*D26del - Sqrt_Sum) * Exp3; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04del26del_Re - Sqrt_sum_Re; Temp_Im := D04del26del_Im - Sqrt_sum_Im; Data_Re (Index6) := Temp_Re*Exp3_Re - Temp_Im*Exp3_Im; Data_Im (Index6) := Temp_Re*Exp3_Im + Temp_Im*Exp3_Re; -- D04del26sum := D04del + Im*D26del; -- D5new := ((D0-D4) + i(D2-D6)) + Sqrt_Del) * Exp5; -- Data(Index5) := (D04del + Im*D26del + Sqrt_Del) * Exp5; Temp_Re := D04del26sum_Re + Sqrt_del_Re; Temp_Im := D04del26sum_Im + Sqrt_del_Im; Data_Re (Index5) := Temp_Re*Exp5_Re - Temp_Im*Exp5_Im; Data_Im (Index5) := Temp_Re*Exp5_Im + Temp_Im*Exp5_Re; -- D04del26del := D04del - Im*D26del; -- D7new := ((D0-D4) - i(D2-D6)) + Sqrt_Sum) * Exp7; -- Data(Index7) := (D04del - Im*D26del + Sqrt_Sum) * Exp7; Temp_Re := D04del26del_Re + Sqrt_sum_Re; Temp_Im := D04del26del_Im + Sqrt_sum_Im; Data_Re (Index7) := Temp_Re*Exp7_Re - Temp_Im*Exp7_Im; Data_Im (Index7) := Temp_Re*Exp7_Im + Temp_Im*Exp7_Re; end loop; end loop; end loop; end if; -- Step 5b. Perform the last stage of the Radix 8 set if it exists. if Final_Stage_Is_A_Radix_8_Stage then Radix_8_Stage_Last := Exponent_Of_Two_Type(Log_Of_Data_Length / 3 - 1); for Stage in Radix_8_Stage_Last .. Radix_8_Stage_Last loop No_Of_Butterfly_Flocks := 2 ** Integer (3*Stage); Butterflies_Per_Flock := Eighth_Data / No_Of_Butterfly_Flocks; -- 1 Butterflies_Per_Flock2 := Butterflies_Per_Flock + Butterflies_Per_Flock; Butterflies_Per_Flock3 := Butterflies_Per_Flock2 + Butterflies_Per_Flock; Butterflies_Per_Flock4 := Butterflies_Per_Flock2 + Butterflies_Per_Flock2; Butterflies_Per_Flock5 := Butterflies_Per_Flock2 + Butterflies_Per_Flock3; Butterflies_Per_Flock6 := Butterflies_Per_Flock2 + Butterflies_Per_Flock4; Butterflies_Per_Flock7 := Butterflies_Per_Flock2 + Butterflies_Per_Flock5; -- Butterflies_Per_Flock is in the range Eighth_Data..1 -- No_Of_Butterfly_Flocks is in the range 1..Eighth_Data Flock_Width := 0; -- Flock width overflows if Stage = 0. if Stage > 0 then Flock_Width := 8 * Butterflies_Per_Flock; end if; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop Next_Butterfly := No_Of_Butterfly_Flocks * Butterfly_ID; for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index4 := Start_Of_Butterfly + Butterflies_Per_Flock4; D0_Re := Data_Re (Index0); D0_Im := Data_Im (Index0); D4_Re := Data_Re (Index4); D4_Im := Data_Im (Index4); D04sum_Re := D0_Re + D4_Re; D04sum_Im := D0_Im + D4_Im; D04del_Re := D0_Re - D4_Re; D04del_Im := D0_Im - D4_Im; Index2 := Start_Of_Butterfly + Butterflies_Per_Flock2; Index6 := Start_Of_Butterfly + Butterflies_Per_Flock6; D2_Re := Data_Re (Index2); D2_Im := Data_Im (Index2); D6_Re := Data_Re (Index6); D6_Im := Data_Im (Index6); D26sum_Re := D2_Re + D6_Re; D26sum_Im := D2_Im + D6_Im; D26del_Re := D2_Re - D6_Re; D26del_Im := D2_Im - D6_Im; D04sum26sum_Re := D04sum_Re + D26sum_Re; D04sum26sum_Im := D04sum_Im + D26sum_Im; D04sum26del_Re := D04sum_Re - D26sum_Re; D04sum26del_Im := D04sum_Im - D26sum_Im; -- D04del26sum := D04del + Im*D26del; D04del26sum_Re := D04del_Re - D26del_Im; D04del26sum_Im := D04del_Im + D26del_Re; -- D04del26del := D04del - Im*D26del; D04del26del_Re := D04del_Re + D26del_Im; D04del26del_Im := D04del_Im - D26del_Re; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; Index5 := Start_Of_Butterfly + Butterflies_Per_Flock5; D1_Re := Data_Re (Index1); D1_Im := Data_Im (Index1); D5_Re := Data_Re (Index5); D5_Im := Data_Im (Index5); D15sum_Re := D1_Re + D5_Re; D15sum_Im := D1_Im + D5_Im; D15del_Re := D1_Re - D5_Re; D15del_Im := D1_Im - D5_Im; Index3 := Start_Of_Butterfly + Butterflies_Per_Flock3; Index7 := Start_Of_Butterfly + Butterflies_Per_Flock7; D3_Re := Data_Re (Index3); D3_Im := Data_Im (Index3); D7_Re := Data_Re (Index7); D7_Im := Data_Im (Index7); D37sum_Re := D3_Re + D7_Re; D37sum_Im := D3_Im + D7_Im; D37del_Re := D3_Re - D7_Re; D37del_Im := D3_Im - D7_Im; D15sum37sum_Re := D15sum_Re + D37sum_Re; D15sum37sum_Im := D15sum_Im + D37sum_Im; D15sum37del_Re := D15sum_Re - D37sum_Re; D15sum37del_Im := D15sum_Im - D37sum_Im; D1537sum_Re := D15del_Re + D37del_Re; D1537sum_Im := D15del_Im + D37del_Im; D1537del_Re := D15del_Re - D37del_Re; D1537del_Im := D15del_Im - D37del_Im; -- D0new := ((D0+D4) + (D2+D6) + ( (D1+D5) + (D3+D7))) * Exp0; -- Data(Index0) := D04sum + D26sum + D15sum + D37sum; Temp_Re := D04sum26sum_Re + D15sum37sum_Re; Temp_Im := D04sum26sum_Im + D15sum37sum_Im; Data_Re (Index0) := Temp_Re; Data_Im (Index0) := Temp_Im; -- Inverse FFT: change sign of i: -- D2new := ((D0+D4) - (D2+D6) + i*((D1+D5) - (D3+D7))) * Exp2; -- Data(Index2) := (D04sum - D26sum + Im * (D15sum - D37sum)) * Exp2; Temp_Re := D04sum26del_Re - D15sum37del_Im; Temp_Im := D04sum26del_Im + D15sum37del_Re; Data_Re (Index2) := Temp_Re; Data_Im (Index2) := Temp_Im; -- D4new := ((D0+D4) + (D2+D6) - ((D1+D5) + (D3+D7))) * Exp4; -- Data(Index1) := (D04sum + D26sum - (D15sum + D37sum)) * Exp4; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04sum26sum_Re - D15sum37sum_Re; Temp_Im := D04sum26sum_Im - D15sum37sum_Im; Data_Re (Index1) := Temp_Re; Data_Im (Index1) := Temp_Im; -- Inverse FFT: change sign of i: -- D6new := ((D0+D4) - (D2+D6) - i*((D1+D5) - (D3+D7))) * Exp6; -- Data(Index3) := (D04sum - D26sum - Im*(D15sum - D37sum)) * Exp6; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04sum26del_Re + D15sum37del_Im; Temp_Im := D04sum26del_Im - D15sum37del_Re; Data_Re (Index3) := Temp_Re; Data_Im (Index3) := Temp_Im; -- Inverse FFT: change sign of i: -- Sqrt_Del := a(-i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); Sqrt_Del_Re := Sqrt_Half * ( D1537sum_Im - D1537del_Re); Sqrt_Del_Im := Sqrt_Half * (-D1537sum_Re - D1537del_Im); -- Inverse FFT: change sign of i: -- Sqrt_Sum := a(-i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); Sqrt_Sum_Re := Sqrt_Half * ( D1537sum_Im + D1537del_Re); Sqrt_Sum_Im := Sqrt_Half * (-D1537sum_Re + D1537del_Im); -- Inverse FFT: change sign of i: -- D04del26sum := D04del + Im*D26del; -- Sqrt_Del := a(-i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); -- D1new := ((D0-D4) + i(D2-D6)) - Sqrt_Del) * Exp1 -- Data(Index4) := (D04del + Im*D26del - Sqrt_Del) * Exp1; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04del26sum_Re - Sqrt_del_Re; Temp_Im := D04del26sum_Im - Sqrt_del_Im; Data_Re (Index4) := Temp_Re; Data_Im (Index4) := Temp_Im; -- Inverse FFT: change sign of i: -- D04del26del := D04del - Im*D26del; -- Sqrt_Sum := a(-i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); -- D3new := ((D0-D4) - i(D2-D6)) - Sqrt_Sum) * Exp3; -- Data(Index6) := (D04del - Im*D26del - Sqrt_Sum) * Exp3; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04del26del_Re - Sqrt_sum_Re; Temp_Im := D04del26del_Im - Sqrt_sum_Im; Data_Re (Index6) := Temp_Re; Data_Im (Index6) := Temp_Im; -- D04del26sum := D04del + Im*D26del; -- D5new := ((D0-D4) + i(D2-D6)) + Sqrt_Del) * Exp5; -- Data(Index5) := (D04del + Im*D26del + Sqrt_Del) * Exp5; Temp_Re := D04del26sum_Re + Sqrt_del_Re; Temp_Im := D04del26sum_Im + Sqrt_del_Im; Data_Re (Index5) := Temp_Re; Data_Im (Index5) := Temp_Im; -- D04del26del := D04del - Im*D26del; -- D7new := ((D0-D4) - i(D2-D6)) + Sqrt_Sum) * Exp7; -- Data(Index7) := (D04del - Im*D26del + Sqrt_Sum) * Exp7; Temp_Re := D04del26del_Re + Sqrt_sum_Re; Temp_Im := D04del26del_Im + Sqrt_sum_Im; Data_Re (Index7) := Temp_Re; Data_Im (Index7) := Temp_Im; end loop; end loop; end loop; end if; -- Step 5b. Perform an optimized final stage: a Radix 4 stage if it -- exists. All the Exps are 1.0, optimizations reflect that. if Final_Stage_Is_A_Radix_4_Stage then --Radix_4_Stage_Last := Exponent_Of_Two_Type(Log_Of_Data_Length / 2 - 1); --for Stage in 0 .. Radix_4_Stage_Last loop --No_Of_Butterfly_Flocks := 2 ** Integer (2*Stage); --Butterflies_Per_Flock := Quarter_Data / No_Of_Butterfly_Flocks; No_Of_Butterfly_Flocks := Quarter_Data; Butterflies_Per_Flock := 1; Butterflies_Per_Flock2 := 2*Butterflies_Per_Flock; Butterflies_Per_Flock3 := 3*Butterflies_Per_Flock; -- here: Butterflies_Per_Flock := 1; -- here: No_Of_Butterfly_Flocks := Quarter_Data; Flock_Width := 0; -- Flock width overflows if Stage = 0. --if Stage > 0 then Flock_Width := 4 * Butterflies_Per_Flock; end if; Flock_Width := 4 * Butterflies_Per_Flock; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop -- All the Exp's equal One. for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; Index2 := Start_Of_Butterfly + Butterflies_Per_Flock2; Index3 := Start_Of_Butterfly + Butterflies_Per_Flock3; Data02Sum_Re := Data_Re(Index0) + Data_Re(Index2); Data02Sum_Im := Data_Im(Index0) + Data_Im(Index2); Data02Del_Re := Data_Re(Index0) - Data_Re(Index2); Data02Del_Im := Data_Im(Index0) - Data_Im(Index2); Data13Sum_Re := Data_Re(Index1) + Data_Re(Index3); Data13Sum_Im := Data_Im(Index1) + Data_Im(Index3); Data13Del_Re := Data_Re(Index1) - Data_Re(Index3); Data13Del_Im := Data_Im(Index1) - Data_Im(Index3); Data_Re (Index0) := Data02sum_Re + Data13sum_Re; Data_Im (Index0) := Data02sum_Im + Data13sum_Im; Data_Re (Index1) := Data02sum_Re - Data13sum_Re; Data_Im (Index1) := Data02sum_Im - Data13sum_Im; Data_Re (Index2) := Data02del_Re - Data13del_Im; Data_Im (Index2) := Data02del_Im + Data13del_Re; Data_Re (Index3) := Data02del_Re + Data13del_Im; Data_Im (Index3) := Data02del_Im - Data13del_Re; end loop; end loop; --end loop; end if; -- Step 5c. Perform an optimized final stage, a radix 2 stage -- if it exists. In this stage Stage := Log_Of_Size_Minus_1, -- all of the twiddle factors are 1 (Exp_Fctn = (1.0, 0.0)). if Final_Stage_Is_A_Radix_2_Stage then Radix_2_Stage_Last := Exponent_Of_Two_Type(Log_Of_Data_Length - 1); for Stage in Radix_2_Stage_Last .. Radix_2_Stage_Last loop No_Of_Butterfly_Flocks := 2 ** Stage; Butterflies_Per_Flock := Half_Data / No_Of_Butterfly_Flocks; -- Butterflies_Per_Flock = 1, and No_Of_Butterfly_Flocks = Half_Data Flock_Width := 0; if Stage > 0 then Flock_Width := 2*Butterflies_Per_Flock; end if; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop -- in 0..0 -- Next_Butterfly := No_Of_Butterfly_Flocks * Butterfly_ID; -- Exp_Id := Next_Butterfly; -- Get_Exp_At (Exp_Id, Inverse_FFT_Desired, Exp1_Re, Exp1_Im); for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; DataTop_Re := Data_Re (Index0); DataTop_Im := Data_Im (Index0); DataBot_Re := Data_Re (Index1); DataBot_Im := Data_Im (Index1); -- Here is the 2 pt. FFT. Exp = (1,0) here. -- Data0 := DataTop + DataBot; -- Data1 := (DataTop - DataBot)*(Exp1_Re, Exp1_Im); Data_Re (Index0) := DataTop_Re + DataBot_Re; Data_Im (Index0) := DataTop_Im + DataBot_Im; Data_Re (Index1) := DataTop_Re - DataBot_Re; Data_Im (Index1) := DataTop_Im - DataBot_Im; end loop; end loop; end loop; end if; else -- not Inverse FFT; here inline the forward fft by hand: -- Step 5a. Perform the FFT radix 8 Stages on 0..Radix_8_Stage_Last -- Each "Butterfly" has 8 inputs on the left, and 8 outputs on the right. -- The 8 on the left (input) are at indices n, n+N/8, n+N/4, n+3N/8 etc. -- Index n is in the range 0..N/8-1, where N is the Data_Length, a power -- of 2. The output data points (on the right) are at the same points. -- The above is for stage 0. At state 1, just replace the N by N/8. -- -- The Radix 8 stage is really a series of 8 point DFT's. The Radix -- 2 stage is a series of 2 point DFT's. Want the output of a single -- Radix 8 stage to be identical to the output of 3 Radix 2 stages. -- Therefore have to make sure that the 8 x 8 DFT's produces -- bit-reversed output just like results of 3 radix 2 stages, so -- have to artifically bit-reverse the results of the 8 x 8. To bit -- reverse an 8 pt DFT, just swap items 1 and 4, and items 3 and 6. -- -- Stage 0 prepares Data so that the N pt DFT can be done by eight N/8 -- pt DFT's in stage 1. Instead of performing the 8 DFT's, Stage 1 -- prepares the Data so the eight N/8 pt DFT's can each be -- done by eight N/64 pt. DFT's in stage 2. The value N/8 in Stage=0 is -- called Butterflies_Per_Flock. Since each butterfly has 8 outputs, the -- N/8 butterflies of stage 0 comprise the entire data set. At stage 0, -- with N/8 butterflies, say Flock_Width = N and No_Of_Butterfly_Flocks = 1. -- At Stage 1, with N/64 butterflies (for each of the 8 DFT's), say -- Flock_Width = N/8, and No_Of_Butterfly_Flocks = 8. if No_Of_Preliminary_Radix_8_Stages > 0 then Radix_8_Stage_Last :=Exponent_Of_Two_Type(No_Of_Preliminary_Radix_8_Stages-1); for Stage in 0 .. Radix_8_Stage_Last loop No_Of_Butterfly_Flocks := 2 ** Integer (3*Stage); Butterflies_Per_Flock := Eighth_Data / No_Of_Butterfly_Flocks; Butterflies_Per_Flock2 := Butterflies_Per_Flock + Butterflies_Per_Flock; Butterflies_Per_Flock3 := Butterflies_Per_Flock2 + Butterflies_Per_Flock; Butterflies_Per_Flock4 := Butterflies_Per_Flock2 + Butterflies_Per_Flock2; Butterflies_Per_Flock5 := Butterflies_Per_Flock2 + Butterflies_Per_Flock3; Butterflies_Per_Flock6 := Butterflies_Per_Flock2 + Butterflies_Per_Flock4; Butterflies_Per_Flock7 := Butterflies_Per_Flock2 + Butterflies_Per_Flock5; -- Butterflies_Per_Flock is in the range Eighth_Data..1 -- No_Of_Butterfly_Flocks is in the range 1..Eighth_Data Flock_Width := 0; -- Flock width overflows if Stage = 0. if Stage > 0 then Flock_Width := 8 * Butterflies_Per_Flock; end if; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop Next_Butterfly := No_Of_Butterfly_Flocks * Butterfly_ID; Exp_Id := Next_Butterfly; Exp1_Re := Exp_Table.Re(Exp_Id); Exp1_Im := Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; Exp2_Re := Exp_Table.Re(Exp_Id); Exp2_Im := Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; Exp3_Re := Exp_Table.Re(Exp_Id); Exp3_Im := Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; Exp4_Re := Exp_Table.Re(Exp_Id); Exp4_Im := Exp_Table.Im(Exp_Id); Exp_Id := Exp_Id + Next_Butterfly; if Exp_Id < Half_Data then Exp5_Re := Exp_Table.Re(Exp_Id); Exp5_Im := Exp_Table.Im(Exp_Id); else E_low := Exp_Id - Half_Data; Exp5_Re := -Exp_Table.Re(E_low); Exp5_Im := -Exp_Table.Im(E_low); end if; Exp_Id := Exp_Id + Next_Butterfly; if Exp_Id < Half_Data then Exp6_Re := Exp_Table.Re(Exp_Id); Exp6_Im := Exp_Table.Im(Exp_Id); else E_low := Exp_Id - Half_Data; Exp6_Re := -Exp_Table.Re(E_low); Exp6_Im := -Exp_Table.Im(E_low); end if; Exp_Id := Exp_Id + Next_Butterfly; if Exp_Id < Half_Data then Exp7_Re := Exp_Table.Re(Exp_Id); Exp7_Im := Exp_Table.Im(Exp_Id); else E_low := Exp_Id - Half_Data; Exp7_Re := -Exp_Table.Re(E_low); Exp7_Im := -Exp_Table.Im(E_low); end if; -- Next perform the 8 pt. Fourier Trans. on butterfly -- with ID = Butterfly_ID, in the Flock with ID = Flock_ID. The -- span of a flock is 8 times the number of butterflies in the -- flock. So the start of the Flock is at Flock_ID * Span, -- and add on to that Butterfly_ID to get the start of the -- desired butterfly. The index of the start of the butterfly -- is called K: -- Here is the abstract version of the inner loop, commented out. -- Below it is unrolled by hand to make it more efficient under -- gcc/gnat. -- -- -- D0new := ((D0+D4) + (D2+D6) + ( (D1+D5) + (D3+D7))) * Exp0; -- D2new := ((D0+D4) - (D2+D6) - i*( (D1+D5) - (D3+D7))) * Exp2; -- D4new := ((D0+D4) + (D2+D6) - ( (D1+D5) + (D3+D7))) * Exp4; -- D6new := ((D0+D4) - (D2+D6) + i*( (D1+D5) - (D3+D7))) * Exp6; -- -- D1new := ((D0-D4) - i(D2-D6) + a( 1-i)*(D1-D5) + a(-1-i)*(D3-D7))*Exp1; -- D3new := ((D0-D4) + i(D2-D6) + a(-1-i)*(D1-D5) + a( 1-i)*(D3-D7))*Exp3; -- D5new := ((D0-D4) - i(D2-D6) + a(-1+i)*(D1-D5) + a( 1+i)*(D3-D7))*Exp5; -- D7new := ((D0-D4) + i(D2-D6) + a( 1+i)*(D1-D5) + a(-1+i)*(D3-D7))*Exp7; -- -- The last set can be written: -- --D1new = ((D0-D4) - i(D2-D6) - a(i((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7))))*Exp1; --D3new = ((D0-D4) + i(D2-D6) - a(i((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7))))*Exp3; --D5new = ((D0-D4) - i(D2-D6) + a(i((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7))))*Exp5; --D7new = ((D0-D4) + i(D2-D6) + a(i((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7))))*Exp7; -- for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index4 := Start_Of_Butterfly + Butterflies_Per_Flock4; D0_Re := Data_Re (Index0); D0_Im := Data_Im (Index0); D4_Re := Data_Re (Index4); D4_Im := Data_Im (Index4); D04sum_Re := D0_Re + D4_Re; D04sum_Im := D0_Im + D4_Im; D04del_Re := D0_Re - D4_Re; D04del_Im := D0_Im - D4_Im; Index2 := Start_Of_Butterfly + Butterflies_Per_Flock2; Index6 := Start_Of_Butterfly + Butterflies_Per_Flock6; D2_Re := Data_Re (Index2); D2_Im := Data_Im (Index2); D6_Re := Data_Re (Index6); D6_Im := Data_Im (Index6); D26sum_Re := D2_Re + D6_Re; D26sum_Im := D2_Im + D6_Im; D26del_Re := D2_Re - D6_Re; D26del_Im := D2_Im - D6_Im; D04sum26sum_Re := D04sum_Re + D26sum_Re; D04sum26sum_Im := D04sum_Im + D26sum_Im; D04sum26del_Re := D04sum_Re - D26sum_Re; D04sum26del_Im := D04sum_Im - D26sum_Im; -- D04del26sum := D04del + Im*D26del; D04del26sum_Re := D04del_Re - D26del_Im; D04del26sum_Im := D04del_Im + D26del_Re; -- D04del26del := D04del - Im*D26del; D04del26del_Re := D04del_Re + D26del_Im; D04del26del_Im := D04del_Im - D26del_Re; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; Index5 := Start_Of_Butterfly + Butterflies_Per_Flock5; D1_Re := Data_Re (Index1); D1_Im := Data_Im (Index1); D5_Re := Data_Re (Index5); D5_Im := Data_Im (Index5); D15sum_Re := D1_Re + D5_Re; D15sum_Im := D1_Im + D5_Im; D15del_Re := D1_Re - D5_Re; D15del_Im := D1_Im - D5_Im; Index3 := Start_Of_Butterfly + Butterflies_Per_Flock3; Index7 := Start_Of_Butterfly + Butterflies_Per_Flock7; D3_Re := Data_Re (Index3); D3_Im := Data_Im (Index3); D7_Re := Data_Re (Index7); D7_Im := Data_Im (Index7); D37sum_Re := D3_Re + D7_Re; D37sum_Im := D3_Im + D7_Im; D37del_Re := D3_Re - D7_Re; D37del_Im := D3_Im - D7_Im; D15sum37sum_Re := D15sum_Re + D37sum_Re; D15sum37sum_Im := D15sum_Im + D37sum_Im; D15sum37del_Re := D15sum_Re - D37sum_Re; D15sum37del_Im := D15sum_Im - D37sum_Im; D1537sum_Re := D15del_Re + D37del_Re; D1537sum_Im := D15del_Im + D37del_Im; D1537del_Re := D15del_Re - D37del_Re; D1537del_Im := D15del_Im - D37del_Im; -- D0new := ((D0+D4) + (D2+D6) + ((D1+D5) + (D3+D7))) * Exp0; -- Data(Index0) := D04sum + D26sum + D15sum + D37sum; Temp_Re := D04sum26sum_Re + D15sum37sum_Re; Temp_Im := D04sum26sum_Im + D15sum37sum_Im; Data_Re (Index0) := Temp_Re; Data_Im (Index0) := Temp_Im; -- D2new := ((D0+D4) - (D2+D6) - i*((D1+D5) - (D3+D7))) * Exp2; -- Data(Index2) := (D04sum - D26sum - Im * (D15sum - D37sum)) * Exp2; Temp_Re := D04sum26del_Re + D15sum37del_Im; Temp_Im := D04sum26del_Im - D15sum37del_Re; Data_Re (Index2) := Temp_Re*Exp2_Re - Temp_Im*Exp2_Im; Data_Im (Index2) := Temp_Re*Exp2_Im + Temp_Im*Exp2_Re; -- D4new := ((D0+D4) + (D2+D6) - ((D1+D5) + (D3+D7))) * Exp4; -- Data(Index1) := (D04sum + D26sum - (D15sum + D37sum)) * Exp4; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04sum26sum_Re - D15sum37sum_Re; Temp_Im := D04sum26sum_Im - D15sum37sum_Im; Data_Re (Index1) := Temp_Re*Exp4_Re - Temp_Im*Exp4_Im; Data_Im (Index1) := Temp_Re*Exp4_Im + Temp_Im*Exp4_Re; -- D6new := ((D0+D4) - (D2+D6) + i*((D1+D5) - (D3+D7))) * Exp6; -- Data(Index3) := (D04sum - D26sum + Im*(D15sum - D37sum)) * Exp6; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04sum26del_Re - D15sum37del_Im; Temp_Im := D04sum26del_Im + D15sum37del_Re; Data_Re (Index3) := Temp_Re*Exp6_Re - Temp_Im*Exp6_Im; Data_Im (Index3) := Temp_Re*Exp6_Im + Temp_Im*Exp6_Re; -- Sqrt_Del := a(i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); Sqrt_Del_Re := Sqrt_Half * (-D1537sum_Im - D1537del_Re); Sqrt_Del_Im := Sqrt_Half * ( D1537sum_Re - D1537del_Im); -- Sqrt_Sum := a(i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); Sqrt_Sum_Re := Sqrt_Half * (-D1537sum_Im + D1537del_Re); Sqrt_Sum_Im := Sqrt_Half * ( D1537sum_Re + D1537del_Im); -- D04del26del := D04del - Im*D26del; -- Sqrt_Del := a(i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); -- D1new := ((D0-D4) - i(D2-D6) - Sqrt_Del) * Exp1 -- Data(Index4) := (D04del - Im*D26del - Sqrt_Del) * Exp1; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04del26del_Re - Sqrt_del_Re; Temp_Im := D04del26del_Im - Sqrt_del_Im; Data_Re (Index4) := Temp_Re*Exp1_Re - Temp_Im*Exp1_Im; Data_Im (Index4) := Temp_Re*Exp1_Im + Temp_Im*Exp1_Re; -- D04del26sum := D04del + Im*D26del; -- Sqrt_Sum := a(i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); -- D3new := ((D0-D4) + i(D2-D6) - Sqrt_Sum) * Exp3; -- Data(Index6) := (D04del + Im*D26del - Sqrt_Sum) * Exp3; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04del26sum_Re - Sqrt_sum_Re; Temp_Im := D04del26sum_Im - Sqrt_sum_Im; Data_Re (Index6) := Temp_Re*Exp3_Re - Temp_Im*Exp3_Im; Data_Im (Index6) := Temp_Re*Exp3_Im + Temp_Im*Exp3_Re; -- D04del26del := D04del - Im*D26del; -- D5new := ((D0-D4) - i(D2-D6) + Sqrt_Del) * Exp5; -- Data(Index5) := (D04del - Im*D26del + Sqrt_Del) * Exp5; Temp_Re := D04del26del_Re + Sqrt_del_Re; Temp_Im := D04del26del_Im + Sqrt_del_Im; Data_Re (Index5) := Temp_Re*Exp5_Re - Temp_Im*Exp5_Im; Data_Im (Index5) := Temp_Re*Exp5_Im + Temp_Im*Exp5_Re; -- D04del26sum := D04del + Im*D26del; -- D7new := ((D0-D4) + i(D2-D6) + Sqrt_Sum) * Exp7; -- Data(Index7) := (D04del + Im*D26del + Sqrt_Sum) * Exp7; Temp_Re := D04del26sum_Re + Sqrt_sum_Re; Temp_Im := D04del26sum_Im + Sqrt_sum_Im; Data_Re (Index7) := Temp_Re*Exp7_Re - Temp_Im*Exp7_Im; Data_Im (Index7) := Temp_Re*Exp7_Im + Temp_Im*Exp7_Re; end loop; end loop; end loop; end if; -- Step 5b. Perform the last stage of the Radix 8 set if it exists. if Final_Stage_Is_A_Radix_8_Stage then Radix_8_Stage_Last := Exponent_Of_Two_Type(Log_Of_Data_Length / 3 - 1); for Stage in Radix_8_Stage_Last .. Radix_8_Stage_Last loop No_Of_Butterfly_Flocks := 2 ** Integer (3*Stage); Butterflies_Per_Flock := Eighth_Data / No_Of_Butterfly_Flocks; Butterflies_Per_Flock2 := Butterflies_Per_Flock + Butterflies_Per_Flock; Butterflies_Per_Flock3 := Butterflies_Per_Flock2 + Butterflies_Per_Flock; Butterflies_Per_Flock4 := Butterflies_Per_Flock2 + Butterflies_Per_Flock2; Butterflies_Per_Flock5 := Butterflies_Per_Flock2 + Butterflies_Per_Flock3; Butterflies_Per_Flock6 := Butterflies_Per_Flock2 + Butterflies_Per_Flock4; Butterflies_Per_Flock7 := Butterflies_Per_Flock2 + Butterflies_Per_Flock5; -- Butterflies_Per_Flock is in the range Eighth_Data..1 -- No_Of_Butterfly_Flocks is in the range 1..Eighth_Data Flock_Width := 0; -- Flock width overflows if Stage = 0. if Stage > 0 then Flock_Width := 8 * Butterflies_Per_Flock; end if; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop Next_Butterfly := No_Of_Butterfly_Flocks * Butterfly_ID; for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index4 := Start_Of_Butterfly + Butterflies_Per_Flock4; D0_Re := Data_Re (Index0); D0_Im := Data_Im (Index0); D4_Re := Data_Re (Index4); D4_Im := Data_Im (Index4); D04sum_Re := D0_Re + D4_Re; D04sum_Im := D0_Im + D4_Im; D04del_Re := D0_Re - D4_Re; D04del_Im := D0_Im - D4_Im; Index2 := Start_Of_Butterfly + Butterflies_Per_Flock2; Index6 := Start_Of_Butterfly + Butterflies_Per_Flock6; D2_Re := Data_Re (Index2); D2_Im := Data_Im (Index2); D6_Re := Data_Re (Index6); D6_Im := Data_Im (Index6); D26sum_Re := D2_Re + D6_Re; D26sum_Im := D2_Im + D6_Im; D26del_Re := D2_Re - D6_Re; D26del_Im := D2_Im - D6_Im; D04sum26sum_Re := D04sum_Re + D26sum_Re; D04sum26sum_Im := D04sum_Im + D26sum_Im; D04sum26del_Re := D04sum_Re - D26sum_Re; D04sum26del_Im := D04sum_Im - D26sum_Im; -- D04del26sum := D04del + Im*D26del; D04del26sum_Re := D04del_Re - D26del_Im; D04del26sum_Im := D04del_Im + D26del_Re; -- D04del26del := D04del - Im*D26del; D04del26del_Re := D04del_Re + D26del_Im; D04del26del_Im := D04del_Im - D26del_Re; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; Index5 := Start_Of_Butterfly + Butterflies_Per_Flock5; D1_Re := Data_Re (Index1); D1_Im := Data_Im (Index1); D5_Re := Data_Re (Index5); D5_Im := Data_Im (Index5); D15sum_Re := D1_Re + D5_Re; D15sum_Im := D1_Im + D5_Im; D15del_Re := D1_Re - D5_Re; D15del_Im := D1_Im - D5_Im; Index3 := Start_Of_Butterfly + Butterflies_Per_Flock3; Index7 := Start_Of_Butterfly + Butterflies_Per_Flock7; D3_Re := Data_Re (Index3); D3_Im := Data_Im (Index3); D7_Re := Data_Re (Index7); D7_Im := Data_Im (Index7); D37sum_Re := D3_Re + D7_Re; D37sum_Im := D3_Im + D7_Im; D37del_Re := D3_Re - D7_Re; D37del_Im := D3_Im - D7_Im; D15sum37sum_Re := D15sum_Re + D37sum_Re; D15sum37sum_Im := D15sum_Im + D37sum_Im; D15sum37del_Re := D15sum_Re - D37sum_Re; D15sum37del_Im := D15sum_Im - D37sum_Im; D1537sum_Re := D15del_Re + D37del_Re; D1537sum_Im := D15del_Im + D37del_Im; D1537del_Re := D15del_Re - D37del_Re; D1537del_Im := D15del_Im - D37del_Im; -- D0new := ((D0+D4) + (D2+D6) + ((D1+D5) + (D3+D7))) * Exp0; -- Data(Index0) := D04sum + D26sum + D15sum + D37sum; Temp_Re := D04sum26sum_Re + D15sum37sum_Re; Temp_Im := D04sum26sum_Im + D15sum37sum_Im; Data_Re (Index0) := Temp_Re; Data_Im (Index0) := Temp_Im; -- D2new := ((D0+D4) - (D2+D6) - i*((D1+D5) - (D3+D7))) * Exp2; -- Data(Index2) := (D04sum - D26sum - Im * (D15sum - D37sum)) * Exp2; Temp_Re := D04sum26del_Re + D15sum37del_Im; Temp_Im := D04sum26del_Im - D15sum37del_Re; Data_Re (Index2) := Temp_Re; Data_Im (Index2) := Temp_Im; -- D4new := ((D0+D4) + (D2+D6) - ((D1+D5) + (D3+D7))) * Exp4; -- Data(Index1) := (D04sum + D26sum - (D15sum + D37sum)) * Exp4; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04sum26sum_Re - D15sum37sum_Re; Temp_Im := D04sum26sum_Im - D15sum37sum_Im; Data_Re (Index1) := Temp_Re; Data_Im (Index1) := Temp_Im; -- D6new := ((D0+D4) - (D2+D6) + i*((D1+D5) - (D3+D7))) * Exp6; -- Data(Index3) := (D04sum - D26sum + Im*(D15sum - D37sum)) * Exp6; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04sum26del_Re - D15sum37del_Im; Temp_Im := D04sum26del_Im + D15sum37del_Re; Data_Re (Index3) := Temp_Re; Data_Im (Index3) := Temp_Im; -- Sqrt_Del := a(i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); Sqrt_Del_Re := Sqrt_Half * (-D1537sum_Im - D1537del_Re); Sqrt_Del_Im := Sqrt_Half * ( D1537sum_Re - D1537del_Im); -- Sqrt_Sum := a(i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); Sqrt_Sum_Re := Sqrt_Half * (-D1537sum_Im + D1537del_Re); Sqrt_Sum_Im := Sqrt_Half * ( D1537sum_Re + D1537del_Im); -- D04del26del := D04del - Im*D26del; -- Sqrt_Del := a(i*((D1-D5)+(D3-D7)) - ((D1-D5)-(D3-D7)); -- D1new := ((D0-D4) - i(D2-D6) - Sqrt_Del) * Exp1 -- Data(Index4) := (D04del - Im*D26del - Sqrt_Del) * Exp1; -- To bit reverse the 8 x 8 DFT, swap items 4 and 1: Temp_Re := D04del26del_Re - Sqrt_del_Re; Temp_Im := D04del26del_Im - Sqrt_del_Im; Data_Re (Index4) := Temp_Re; Data_Im (Index4) := Temp_Im; -- D04del26sum := D04del + Im*D26del; -- Sqrt_Sum := a(i*((D1-D5)+(D3-D7)) + ((D1-D5)-(D3-D7)); -- D3new := ((D0-D4) + i(D2-D6) - Sqrt_Sum) * Exp3; -- Data(Index6) := (D04del + Im*D26del - Sqrt_Sum) * Exp3; -- To bit reverse the 8 x 8 DFT, swap items 6 and 3: Temp_Re := D04del26sum_Re - Sqrt_sum_Re; Temp_Im := D04del26sum_Im - Sqrt_sum_Im; Data_Re (Index6) := Temp_Re; Data_Im (Index6) := Temp_Im; -- D04del26del := D04del - Im*D26del; -- D5new := ((D0-D4) - i(D2-D6) + Sqrt_Del) * Exp5; -- Data(Index5) := (D04del - Im*D26del + Sqrt_Del) * Exp5; Temp_Re := D04del26del_Re + Sqrt_del_Re; Temp_Im := D04del26del_Im + Sqrt_del_Im; Data_Re (Index5) := Temp_Re; Data_Im (Index5) := Temp_Im; -- D04del26sum := D04del + Im*D26del; -- D7new := ((D0-D4) + i(D2-D6) + Sqrt_Sum) * Exp7; -- Data(Index7) := (D04del + Im*D26del + Sqrt_Sum) * Exp7; Temp_Re := D04del26sum_Re + Sqrt_sum_Re; Temp_Im := D04del26sum_Im + Sqrt_sum_Im; Data_Re (Index7) := Temp_Re; Data_Im (Index7) := Temp_Im; end loop; end loop; end loop; end if; -- Step 5b. Perform an optimized final stage: a Radix 4 stage if it -- exists. All the Exps are 1.0, optimizations reflect that. if Final_Stage_Is_A_Radix_4_Stage then --Radix_4_Stage_Last := Exponent_Of_Two_Type(Log_Of_Data_Length / 2 - 1); --for Stage in 0 .. Radix_4_Stage_Last loop --No_Of_Butterfly_Flocks := 2 ** Integer (2*Stage); --Butterflies_Per_Flock := Quarter_Data / No_Of_Butterfly_Flocks; No_Of_Butterfly_Flocks := Quarter_Data; Butterflies_Per_Flock := 1; Butterflies_Per_Flock2 := 2*Butterflies_Per_Flock; Butterflies_Per_Flock3 := 3*Butterflies_Per_Flock; -- here: Butterflies_Per_Flock := 1; -- here: No_Of_Butterfly_Flocks := Quarter_Data; Flock_Width := 0; -- Flock width overflows if Stage = 0. --if Stage > 0 then Flock_Width := 4 * Butterflies_Per_Flock; end if; Flock_Width := 4 * Butterflies_Per_Flock; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop -- All the Exp's equal One. for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; Index2 := Start_Of_Butterfly + Butterflies_Per_Flock2; Index3 := Start_Of_Butterfly + Butterflies_Per_Flock3; Data02Sum_Re := Data_Re(Index0) + Data_Re(Index2); Data02Sum_Im := Data_Im(Index0) + Data_Im(Index2); Data02Del_Re := Data_Re(Index0) - Data_Re(Index2); Data02Del_Im := Data_Im(Index0) - Data_Im(Index2); Data13Sum_Re := Data_Re(Index1) + Data_Re(Index3); Data13Sum_Im := Data_Im(Index1) + Data_Im(Index3); Data13Del_Re := Data_Re(Index1) - Data_Re(Index3); Data13Del_Im := Data_Im(Index1) - Data_Im(Index3); Data_Re (Index0) := Data02sum_Re + Data13sum_Re; Data_Im (Index0) := Data02sum_Im + Data13sum_Im; Data_Re (Index1) := Data02sum_Re - Data13sum_Re; Data_Im (Index1) := Data02sum_Im - Data13sum_Im; Data_Re (Index2) := Data02del_Re + Data13del_Im; Data_Im (Index2) := Data02del_Im - Data13del_Re; Data_Re (Index3) := Data02del_Re - Data13del_Im; Data_Im (Index3) := Data02del_Im + Data13del_Re; end loop; end loop; --end loop; end if; -- Step 5c. Perform an optimized final stage, a radix 2 stage -- if it exists. In this stage Stage := Log_Of_Size_Minus_1, -- all of the twiddle factors are 1 (Exp_Fctn = (1.0, 0.0)). if Final_Stage_Is_A_Radix_2_Stage then Radix_2_Stage_Last := Exponent_Of_Two_Type(Log_Of_Data_Length - 1); for Stage in Radix_2_Stage_Last .. Radix_2_Stage_Last loop No_Of_Butterfly_Flocks := 2 ** Stage; Butterflies_Per_Flock := Half_Data / No_Of_Butterfly_Flocks; -- Butterflies_Per_Flock = 1, and No_Of_Butterfly_Flocks = Half_Data Flock_Width := 0; if Stage > 0 then Flock_Width := 2*Butterflies_Per_Flock; end if; for Butterfly_ID in 0 .. Butterflies_Per_Flock-1 loop -- in 0..0 -- Next_Butterfly := No_Of_Butterfly_Flocks * Butterfly_ID; -- Exp_Id := Next_Butterfly; -- Get_Exp_At (Exp_Id, Inverse_FFT_Desired, Exp1_Re, Exp1_Im); for Flock_ID in 0 .. No_Of_Butterfly_Flocks-1 loop Start_Of_Flock := Flock_ID * Flock_Width; Start_Of_Butterfly := Start_Of_Flock + Butterfly_ID; Index0 := Start_Of_Butterfly; Index1 := Start_Of_Butterfly + Butterflies_Per_Flock; DataTop_Re := Data_Re (Index0); DataTop_Im := Data_Im (Index0); DataBot_Re := Data_Re (Index1); DataBot_Im := Data_Im (Index1); -- Here is the 2 pt. FFT. Exp = (1,0) here. -- Data0 := DataTop + DataBot; -- Data1 := (DataTop - DataBot)*(Exp1_Re, Exp1_Im); Data_Re (Index0) := DataTop_Re + DataBot_Re; Data_Im (Index0) := DataTop_Im + DataBot_Im; Data_Re (Index1) := DataTop_Re - DataBot_Re; Data_Im (Index1) := DataTop_Im - DataBot_Im; end loop; end loop; end loop; end if; end if; -- not inverse fft if Normalized_Data_Desired then NormalizationFactor := 1.0 / SQRT (Real(Padded_Data_Index_Last)+1.0); for K in 0..Padded_Data_Index_Last loop Data_Re (K) := Data_Re (K) * NormalizationFactor; end loop; for K in 0..Padded_Data_Index_Last loop Data_Im (K) := Data_Im (K) * NormalizationFactor; end loop; end if; if Bit_Reversal_Desired then Get_Bit_Reversal_Of (Data_Re => Data_Re, Data_Im => Data_Im, Two_To_The_Top_Bit => Half_Data, Half_Two_To_The_Top_Bit => Quarter_Data, Quarter_Two_To_The_Top_Bit => Eighth_Data, Top_Bit => Log_Of_Data_Length_Minus_1); end if; Transformed_Data_Last := Padded_Data_Index_Last; end FFT; end Fourier8;
-- Copyright 2012-2021 Free Software Foundation, Inc. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. with System; package Pck is type Bounded is array (Integer range <>) of Integer; function New_Bounded (Low, High : Integer) return Bounded; procedure Do_Nothing (A : System.Address); end Pck;
pragma Ada_2005; pragma Style_Checks (Off); pragma Warnings (Off); with Interfaces.C; use Interfaces.C; with glib; with glib; with glib.Values; with System; with GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstbin_h; with GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstcamerabin_enum_h; -- limited -- with GStreamer.GST_Low_Level.glib_2_0_glib_gthread_h; limited with GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstcaps_h; limited with GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstelement_h; limited with GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstcamerabinpreview_h; limited with GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstbuffer_h; package GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstbasecamerasrc_h is -- unsupported macro: GST_TYPE_BASE_CAMERA_SRC (gst_base_camera_src_get_type()) -- arg-macro: function GST_BASE_CAMERA_SRC (obj) -- return G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_BASE_CAMERA_SRC,GstBaseCameraSrc); -- arg-macro: function GST_BASE_CAMERA_SRC_GET_CLASS (obj) -- return G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_BASE_CAMERA_SRC, GstBaseCameraSrcClass); -- arg-macro: function GST_BASE_CAMERA_SRC_CLASS (klass) -- return G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_BASE_CAMERA_SRC,GstBaseCameraSrcClass); -- arg-macro: function GST_IS_BASE_CAMERA_SRC (obj) -- return G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_BASE_CAMERA_SRC); -- arg-macro: function GST_IS_BASE_CAMERA_SRC_CLASS (klass) -- return G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_BASE_CAMERA_SRC); -- arg-macro: function GST_BASE_CAMERA_SRC_CAST (obj) -- return (GstBaseCameraSrc *) (obj); GST_BASE_CAMERA_SRC_VIEWFINDER_PAD_NAME : aliased constant String := "vfsrc" & ASCII.NUL; -- gst/basecamerabinsrc/gstbasecamerasrc.h:56 GST_BASE_CAMERA_SRC_IMAGE_PAD_NAME : aliased constant String := "imgsrc" & ASCII.NUL; -- gst/basecamerabinsrc/gstbasecamerasrc.h:57 GST_BASE_CAMERA_SRC_VIDEO_PAD_NAME : aliased constant String := "vidsrc" & ASCII.NUL; -- gst/basecamerabinsrc/gstbasecamerasrc.h:58 GST_BASE_CAMERA_SRC_PREVIEW_MESSAGE_NAME : aliased constant String := "preview-image" & ASCII.NUL; -- gst/basecamerabinsrc/gstbasecamerasrc.h:60 MIN_ZOOM : constant := 1.0; -- gst/basecamerabinsrc/gstbasecamerasrc.h:129 MAX_ZOOM : constant := 10.0; -- gst/basecamerabinsrc/gstbasecamerasrc.h:130 -- unsupported macro: ZOOM_1X MIN_ZOOM -- * GStreamer -- * Copyright (C) 2010 Texas Instruments, Inc -- * Copyright (C) 2011 Thiago Santos <thiago.sousa.santos@collabora.com> -- * -- * This library is free software; you can redistribute it and/or -- * modify it under the terms of the GNU Library General Public -- * License as published by the Free Software Foundation; either -- * version 2 of the License, or (at your option) any later version. -- * -- * This library is distributed in the hope that it will be useful, -- * but WITHOUT ANY WARRANTY; without even the implied warranty of -- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -- * Library General Public License for more details. -- * -- * You should have received a copy of the GNU Library General Public -- * License along with this library; if not, write to the -- * Free Software Foundation, Inc., 59 Temple Place - Suite 330, -- * Boston, MA 02111-1307, USA. -- function gst_base_camera_src_get_type return GLIB.GType; -- gst/basecamerabinsrc/gstbasecamerasrc.h:51 pragma Import (C, gst_base_camera_src_get_type, "gst_base_camera_src_get_type"); type GstBaseCameraSrc; type u_GstBaseCameraSrc_u_gst_reserved_array is array (0 .. 19) of System.Address; --subtype GstBaseCameraSrc is u_GstBaseCameraSrc; -- gst/basecamerabinsrc/gstbasecamerasrc.h:53 type GstBaseCameraSrcClass; type u_GstBaseCameraSrcClass_u_gst_reserved_array is array (0 .. 19) of System.Address; --subtype GstBaseCameraSrcClass is u_GstBaseCameraSrcClass; -- gst/basecamerabinsrc/gstbasecamerasrc.h:54 --* -- * GstBaseCameraSrc: -- type GstBaseCameraSrc is record parent : aliased GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstbin_h.GstBin; -- gst/basecamerabinsrc/gstbasecamerasrc.h:67 mode : aliased GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstcamerabin_enum_h.GstCameraBinMode; -- gst/basecamerabinsrc/gstbasecamerasrc.h:69 capturing : aliased GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:71 capturing_mutex : access GStreamer.GST_Low_Level.glib_2_0_glib_gthread_h.GMutex; -- gst/basecamerabinsrc/gstbasecamerasrc.h:72 preview_caps : access GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstcaps_h.GstCaps; -- gst/basecamerabinsrc/gstbasecamerasrc.h:75 post_preview : aliased GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:76 preview_filter : access GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstelement_h.GstElement; -- gst/basecamerabinsrc/gstbasecamerasrc.h:77 preview_pipeline : access GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstcamerabinpreview_h.GstCameraBinPreviewPipelineData; -- gst/basecamerabinsrc/gstbasecamerasrc.h:78 width : aliased GLIB.gint; -- gst/basecamerabinsrc/gstbasecamerasrc.h:81 height : aliased GLIB.gint; -- gst/basecamerabinsrc/gstbasecamerasrc.h:82 zoom : aliased GLIB.gfloat; -- gst/basecamerabinsrc/gstbasecamerasrc.h:84 max_zoom : aliased GLIB.gfloat; -- gst/basecamerabinsrc/gstbasecamerasrc.h:85 u_gst_reserved : u_GstBaseCameraSrc_u_gst_reserved_array; -- gst/basecamerabinsrc/gstbasecamerasrc.h:87 end record; pragma Convention (C_Pass_By_Copy, GstBaseCameraSrc); -- gst/basecamerabinsrc/gstbasecamerasrc.h:65 -- Preview convert pipeline -- Resolution of the buffers configured to camerabin --* -- * GstBaseCameraSrcClass: -- * @construct_pipeline: construct pipeline -- * @setup_pipeline: configure pipeline for the chosen settings -- * @set_zoom: set the zoom -- * @set_mode: set the mode -- type GstBaseCameraSrcClass is record parent : aliased GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstbin_h.GstBinClass; -- gst/basecamerabinsrc/gstbasecamerasrc.h:100 construct_pipeline : access function (arg1 : access GstBaseCameraSrc) return GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:103 setup_pipeline : access function (arg1 : access GstBaseCameraSrc) return GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:106 set_zoom : access procedure (arg1 : access GstBaseCameraSrc; arg2 : GLIB.gfloat); -- gst/basecamerabinsrc/gstbasecamerasrc.h:109 set_mode : access function (arg1 : access GstBaseCameraSrc; arg2 : GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstcamerabin_enum_h.GstCameraBinMode) return GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:113 set_preview : access function (arg1 : access GstBaseCameraSrc; arg2 : access GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstcaps_h.GstCaps) return GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:117 start_capture : access function (arg1 : access GstBaseCameraSrc) return GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:120 stop_capture : access procedure (arg1 : access GstBaseCameraSrc); -- gst/basecamerabinsrc/gstbasecamerasrc.h:123 u_gst_reserved : u_GstBaseCameraSrcClass_u_gst_reserved_array; -- gst/basecamerabinsrc/gstbasecamerasrc.h:125 end record; pragma Convention (C_Pass_By_Copy, GstBaseCameraSrcClass); -- gst/basecamerabinsrc/gstbasecamerasrc.h:98 -- Construct pipeline. (called in GST_STATE_CHANGE_NULL_TO_READY) Optional. -- (called in GST_STATE_CHANGE_READY_TO_PAUSED). Optional. -- Set the zoom. If set, called when changing 'zoom' property. Optional. -- Set the mode. If set, called when changing 'mode' property. Optional. -- Set preview caps. If set, called called when setting new 'preview-caps'. Optional. -- Called by the handler for 'start-capture'. Mandatory. -- Called by the handler for 'stop-capture'. Mandatory. function gst_base_camera_src_set_mode (self : access GstBaseCameraSrc; mode : GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstcamerabin_enum_h.GstCameraBinMode) return GLIB.gboolean; -- gst/basecamerabinsrc/gstbasecamerasrc.h:133 pragma Import (C, gst_base_camera_src_set_mode, "gst_base_camera_src_set_mode"); procedure gst_base_camera_src_setup_zoom (self : access GstBaseCameraSrc); -- gst/basecamerabinsrc/gstbasecamerasrc.h:134 pragma Import (C, gst_base_camera_src_setup_zoom, "gst_base_camera_src_setup_zoom"); procedure gst_base_camera_src_setup_preview (self : access GstBaseCameraSrc; preview_caps : access GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstcaps_h.GstCaps); -- gst/basecamerabinsrc/gstbasecamerasrc.h:135 pragma Import (C, gst_base_camera_src_setup_preview, "gst_base_camera_src_setup_preview"); procedure gst_base_camera_src_finish_capture (self : access GstBaseCameraSrc); -- gst/basecamerabinsrc/gstbasecamerasrc.h:136 pragma Import (C, gst_base_camera_src_finish_capture, "gst_base_camera_src_finish_capture"); procedure gst_base_camera_src_post_preview (self : access GstBaseCameraSrc; buf : access GStreamer.GST_Low_Level.gstreamer_0_10_gst_gstbuffer_h.GstBuffer); -- gst/basecamerabinsrc/gstbasecamerasrc.h:139 pragma Import (C, gst_base_camera_src_post_preview, "gst_base_camera_src_post_preview"); -- XXX add methods to get/set img capture and vid capture caps.. end GStreamer.GST_Low_Level.gstreamer_0_10_gst_basecamerabinsrc_gstbasecamerasrc_h;
----------------------------------------------------------------------- -- files.tests -- Unit tests for files -- Copyright (C) 2011, 2012, 2013, 2014, 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Ada.Unchecked_Deallocation; with Util.Tests; with Util.Log.Loggers; with ASF.Principals; with ASF.Tests; with ASF.Responses.Mockup; with AWA.Applications; with AWA.Tests; with AWA.Users.Modules; with ADO.Sessions; with ADO.SQL; package body AWA.Tests.Helpers.Users is use AWA.Users.Services; use type AWA.Users.Principals.Principal_Access; Log : constant Util.Log.Loggers.Logger := Util.Log.Loggers.Create ("AWA.Tests.Helpers.Users"); MAX_USERS : constant Positive := 10; Logged_Users : array (1 .. MAX_USERS) of AWA.Users.Principals.Principal_Access; procedure Free is new Ada.Unchecked_Deallocation (Object => AWA.Users.Principals.Principal'Class, Name => AWA.Users.Principals.Principal_Access); -- ------------------------------ -- Initialize the service context. -- ------------------------------ procedure Initialize (Principal : in out Test_User) is begin -- Setup the service context. Principal.Context.Set_Context (AWA.Tests.Get_Application, null); if Principal.Manager = null then Principal.Manager := AWA.Users.Modules.Get_User_Manager; if Principal.Manager = null then Log.Error ("There is no User_Manager in the application."); end if; end if; end Initialize; -- ------------------------------ -- Create a test user associated with the given email address. -- Get an open session for that user. If the user already exists, no error is reported. -- ------------------------------ procedure Create_User (Principal : in out Test_User; Email : in String) is DB : ADO.Sessions.Session; Query : ADO.SQL.Query; Found : Boolean; Key : AWA.Users.Models.Access_Key_Ref; begin Initialize (Principal); DB := Principal.Manager.Get_Session; -- Find the user Query.Set_Join ("inner join awa_email e on e.user_id = o.id"); Query.Set_Filter ("e.email = ?"); Query.Bind_Param (1, Email); Principal.User.Find (DB, Query, Found); if not Found then Principal.User.Set_First_Name ("Joe"); Principal.User.Set_Last_Name ("Pot"); Principal.User.Set_Password ("admin"); Principal.Email.Set_Email (Email); Principal.Manager.Create_User (Principal.User, Principal.Email); Find_Access_Key (Principal, Email, Key); -- Run the verification and get the user and its session Principal.Manager.Verify_User (Key.Get_Access_Key, "192.168.1.1", Principal.Principal); else Principal.Manager.Authenticate (Email => Email, Password => "admin", IpAddr => "192.168.1.1", Principal => Principal.Principal); end if; Principal.User := Principal.Principal.Get_User; Principal.Session := Principal.Principal.Get_Session; end Create_User; -- ------------------------------ -- Create a test user for a new test and get an open session. -- ------------------------------ procedure Create_User (Principal : in out Test_User) is Key : AWA.Users.Models.Access_Key_Ref; Email : constant String := "Joe-" & Util.Tests.Get_Uuid & "@gmail.com"; begin Initialize (Principal); Principal.User.Set_First_Name ("Joe"); Principal.User.Set_Last_Name ("Pot"); Principal.User.Set_Password ("admin"); Principal.Email.Set_Email (Email); Principal.Manager.Create_User (Principal.User, Principal.Email); Find_Access_Key (Principal, Email, Key); -- Run the verification and get the user and its session Principal.Manager.Verify_User (Key.Get_Access_Key, "192.168.1.1", Principal.Principal); Principal.User := Principal.Principal.Get_User; Principal.Session := Principal.Principal.Get_Session; end Create_User; -- ------------------------------ -- Find the access key associated with a user (if any). -- ------------------------------ procedure Find_Access_Key (Principal : in out Test_User; Email : in String; Key : in out AWA.Users.Models.Access_Key_Ref) is DB : ADO.Sessions.Session; Query : ADO.SQL.Query; Found : Boolean; Signup_Kind : constant Integer := AWA.Users.Models.Key_Type'Pos (AWA.Users.Models.SIGNUP_KEY); Password_Kind : constant Integer := AWA.Users.Models.Key_Type'Pos (AWA.Users.Models.RESET_PASSWORD_KEY); begin Initialize (Principal); DB := Principal.Manager.Get_Session; -- Find the access key Query.Set_Join ("inner join awa_email e on e.user_id = o.user_id"); Query.Set_Filter ("e.email = ? AND o.kind = ?"); Query.Bind_Param (1, Email); Query.Bind_Param (2, Signup_Kind); Key.Find (DB, Query, Found); if not Found then Query.Bind_Param (2, Password_Kind); Key.Find (DB, Query, Found); if not Found then Log.Error ("Cannot find access key for email {0}", Email); end if; end if; end Find_Access_Key; -- ------------------------------ -- Login a user and create a session -- ------------------------------ procedure Login (Principal : in out Test_User) is begin Initialize (Principal); Principal.Manager.Authenticate (Email => Principal.Email.Get_Email, Password => "admin", IpAddr => "192.168.1.1", Principal => Principal.Principal); Principal.User := Principal.Principal.Get_User; Principal.Session := Principal.Principal.Get_Session; end Login; -- ------------------------------ -- Logout the user and closes the current session. -- ------------------------------ procedure Logout (Principal : in out Test_User) is begin Initialize (Principal); Principal.Manager.Close_Session (Principal.Session.Get_Id, True); end Logout; -- ------------------------------ -- Simulate a user login in the given service context. -- ------------------------------ procedure Login (Context : in out AWA.Services.Contexts.Service_Context'Class; Sec_Context : in out Security.Contexts.Security_Context; Email : in String) is User : Test_User; Principal : AWA.Users.Principals.Principal_Access; App : constant AWA.Applications.Application_Access := AWA.Tests.Get_Application; begin AWA.Tests.Set_Application_Context; Create_User (User, Email); Principal := AWA.Users.Principals.Create (User.User, User.Session); Context.Set_Context (App, Principal); Sec_Context.Set_Context (Manager => App.Get_Security_Manager, Principal => Principal.all'Access); -- Keep track of the Principal instance so that Tear_Down will release it. -- Most tests will call Login but don't call Logout because there is no real purpose -- for the test in doing that and it allows to keep the unit test simple. This creates -- memory leak because the Principal instance is not freed. for I in Logged_Users'Range loop if Logged_Users (I) = null then Logged_Users (I) := Principal; exit; end if; end loop; end Login; -- ------------------------------ -- Simulate a user login on the request. Upon successful login, a session that is -- authentified is associated with the request object. -- ------------------------------ procedure Login (Email : in String; Request : in out ASF.Requests.Mockup.Request) is User : Test_User; Reply : ASF.Responses.Mockup.Response; begin Create_User (User, Email); ASF.Tests.Do_Get (Request, Reply, "/auth/login.html", "login-user-1.html"); Request.Set_Parameter ("email", Email); Request.Set_Parameter ("password", "admin"); Request.Set_Parameter ("login", "1"); Request.Set_Parameter ("login-button", "1"); ASF.Tests.Do_Post (Request, Reply, "/auth/login.html", "login-user-2.html"); end Login; -- ------------------------------ -- Setup the context and security context to simulate an anonymous user. -- ------------------------------ procedure Anonymous (Context : in out AWA.Services.Contexts.Service_Context'Class; Sec_Context : in out Security.Contexts.Security_Context) is App : constant AWA.Applications.Application_Access := AWA.Tests.Get_Application; begin AWA.Tests.Set_Application_Context; Context.Set_Context (App, null); Sec_Context.Set_Context (Manager => App.Get_Security_Manager, Principal => null); end Anonymous; -- ------------------------------ -- Simulate the recovery password process for the given user. -- ------------------------------ procedure Recover_Password (Email : in String) is use type ASF.Principals.Principal_Access; Request : ASF.Requests.Mockup.Request; Reply : ASF.Responses.Mockup.Response; begin Request.Set_Parameter ("email", Email); Request.Set_Parameter ("lost-password", "1"); Request.Set_Parameter ("lost-password-button", "1"); ASF.Tests.Do_Post (Request, Reply, "/auth/lost-password.html", "lost-password-2.html"); if Reply.Get_Status /= ASF.Responses.SC_MOVED_TEMPORARILY then Log.Error ("Invalid redirect after lost password"); end if; -- Now, get the access key and simulate a click on the reset password link. declare Principal : AWA.Tests.Helpers.Users.Test_User; Key : AWA.Users.Models.Access_Key_Ref; begin AWA.Tests.Set_Application_Context; AWA.Tests.Helpers.Users.Find_Access_Key (Principal, Email, Key); if not Key.Is_Null then Log.Error ("There is no access key associated with the user"); end if; -- Simulate user clicking on the reset password link. -- This verifies the key, login the user and redirect him to the change-password page Request.Set_Parameter ("key", Key.Get_Access_Key); Request.Set_Parameter ("password", "admin"); Request.Set_Parameter ("reset-password", "1"); ASF.Tests.Do_Post (Request, Reply, "/auth/change-password.html", "reset-password-2.html"); if Reply.Get_Status /= ASF.Responses.SC_MOVED_TEMPORARILY then Log.Error ("Invalid response"); end if; -- Check that the user is logged and we have a user principal now. if Request.Get_User_Principal = null then Log.Error ("A user principal should be defined"); end if; end; end Recover_Password; overriding procedure Finalize (Principal : in out Test_User) is begin Free (Principal.Principal); end Finalize; -- ------------------------------ -- Cleanup and release the Principal that have been allocated from the Login session -- but not released because the Logout is not called from the unit test. -- ------------------------------ procedure Tear_Down is begin for I in Logged_Users'Range loop if Logged_Users (I) /= null then Free (Logged_Users (I)); end if; end loop; end Tear_Down; end AWA.Tests.Helpers.Users;
with Ada.Unchecked_Deallocation; package body kv.Ref_Counting_Mixin is procedure Free is new Ada.Unchecked_Deallocation(Data_Type, Data_Access); procedure Free is new Ada.Unchecked_Deallocation(Control_Type, Control_Access); ----------------------------------------------------------------------------- procedure Initialize(Self : in out Ref_Type) is begin Self.Control := new Control_Type; Self.Control.Data := new Data_Type; Self.Control.Count := 1; end Initialize; ----------------------------------------------------------------------------- procedure Adjust(Self : in out Ref_Type) is Control : Control_Access := Self.Control; begin if Control /= null then Control.Count := Control.Count + 1; end if; end Adjust; ----------------------------------------------------------------------------- procedure Finalize(Self : in out Ref_Type) is Control : Control_Access := Self.Control; begin Self.Control := null; if Control /= null then Control.Count := Control.Count - 1; if Control.Count = 0 then Free(Control.Data); Free(Control); end if; end if; end Finalize; ----------------------------------------------------------------------------- procedure Set(Self : in out Ref_Type; Data : in Data_Access) is begin Self.Control.Data := Data; end Set; ----------------------------------------------------------------------------- function Get(Self : Ref_Type) return Data_Access is begin return Self.Control.Data; end Get; end kv.Ref_Counting_Mixin;
-- MIT License -- -- Copyright (c) 2021 Glen Cornell <glen.m.cornell@gmail.com> -- -- Permission is hereby granted, free of charge, to any person obtaining a copy -- of this software and associated documentation files (the "Software"), to deal -- in the Software without restriction, including without limitation the rights -- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -- copies of the Software, and to permit persons to whom the Software is -- furnished to do so, subject to the following conditions: -- -- The above copyright notice and this permission notice shall be included in all -- copies or substantial portions of the Software. -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -- SOFTWARE. package Sockets is pragma Pure; end Sockets;
----------------------------------------------------------------------- -- util-streams-encoders -- Streams with encoding and decoding capabilities -- Copyright (C) 2017, 2019, 2021 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Encoders; -- == Encoding Streams == -- The <tt>Encoding_Stream</tt> tagged record represents a stream with encoding capabilities. -- The stream passes the data to be written to the <tt>Transformer</tt> interface that -- allows to make transformations on the data before being written. -- -- Encode : Util.Streams.Buffered.Encoders.Encoding_Stream; -- -- The encoding stream manages a buffer that is used to hold the encoded data before it is -- written to the target stream. The <tt>Initialize</tt> procedure must be called to indicate -- the target stream, the size of the buffer and the encoding format to be used. -- -- Encode.Initialize (Output => File'Access, Size => 4096, Format => "base64"); -- generic type Encoder is limited new Util.Encoders.Transformer with private; package Util.Streams.Buffered.Encoders is -- ----------------------- -- Encoding stream -- ----------------------- -- The <b>Encoding_Stream</b> is an output stream which uses an encoder to -- transform the data before writing it to the output. The transformer can -- change the data by encoding it in Base64, Base16 or encrypting it. type Encoder_Stream is limited new Util.Streams.Buffered.Input_Output_Buffer_Stream with record Transform : Encoder; Flushed : Boolean := False; end record; -- Initialize the stream with a buffer of <b>Size</b> bytes. procedure Initialize (Stream : in out Encoder_Stream; Size : in Positive); -- Initialize the stream to write on the given stream. -- An internal buffer is allocated for writing the stream. procedure Produces (Stream : in out Encoder_Stream; Output : access Output_Stream'Class; Size : in Positive); -- Initialize the stream to read the given streams. procedure Consumes (Stream : in out Encoder_Stream; Input : access Input_Stream'Class; Size : in Positive); -- Close the sink. overriding procedure Close (Stream : in out Encoder_Stream); -- Write the buffer array to the output stream. overriding procedure Write (Stream : in out Encoder_Stream; Buffer : in Ada.Streams.Stream_Element_Array); -- Read into the buffer as many bytes as possible and return in -- `last` the position of the last byte read. overriding procedure Read (Stream : in out Encoder_Stream; Into : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset); -- Flush the buffer by writing on the output stream. -- Raises Data_Error if there is no output stream. overriding procedure Flush (Stream : in out Encoder_Stream); overriding procedure Finalize (Stream : in out Encoder_Stream); -- Fill the buffer by reading the input stream. -- Raises Data_Error if there is no input stream; procedure Fill (Stream : in out Encoder_Stream); end Util.Streams.Buffered.Encoders;
No-one has translated the peering3 example into Ada yet. Be the first to create peering3 in Ada and get one free Internet! If you're the author of the Ada binding, this is a great way to get people to use 0MQ in Ada. To submit a new translation email it to zeromq-dev@lists.zeromq.org. Please: * Stick to identical functionality and naming used in examples so that readers can easily compare languages. * You MUST place your name as author in the examples so readers can contact you. * You MUST state in the email that you license your code under the MIT/X11 license. Subscribe to the email list at http://lists.zeromq.org/mailman/listinfo/zeromq-dev.
-------------------------------------------------------------------------------------------------------------------- -- Copyright (c) 2013-2020, Luke A. Guest -- -- This software is provided 'as-is', without any express or implied -- warranty. In no event will the authors be held liable for any damages -- arising from the use of this software. -- -- Permission is granted to anyone to use this software for any purpose, -- including commercial applications, and to alter it and redistribute it -- freely, subject to the following restrictions: -- -- 1. The origin of this software must not be misrepresented; you must not -- claim that you wrote the original software. If you use this software -- in a product, an acknowledgment in the product documentation would be -- appreciated but is not required. -- -- 2. Altered source versions must be plainly marked as such, and must not be -- misrepresented as being the original software. -- -- 3. This notice may not be removed or altered from any source -- distribution. -------------------------------------------------------------------------------------------------------------------- -- SDL.Inputs.Joysticks.Makers -------------------------------------------------------------------------------------------------------------------- with Interfaces.C; private with SDL.C_Pointers; package body SDL.Inputs.Joysticks.Makers is package C renames Interfaces.C; use type C.int; use type SDL.C_Pointers.Joystick_Pointer; function SDL_Joystick_Open (Device : in C.int) return SDL.C_Pointers.Joystick_Pointer with Import => True, Convention => C, External_Name => "SDL_JoystickOpen"; function Create (Device : in Devices) return Joystick is begin return J : Joystick := (Ada.Finalization.Limited_Controlled with Internal => SDL_Joystick_Open (C.int (Device) - 1), Owns => True) do null; end return; end Create; procedure Create (Device : in Devices; Actual_Stick : out Joystick) is begin Actual_Stick.Internal := SDL_Joystick_Open (C.int (Device) - 1); end Create; end SDL.Inputs.Joysticks.Makers;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . A S S E R T I O N S -- -- -- -- S p e c -- -- -- -- Copyright (C) 1992-2009, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package provides support for the GNAT assert pragma -- This unit may be used directly from an application program by providing -- an appropriate WITH, and the interface can be expected to remain stable. pragma Compiler_Unit; package System.Assertions is Assert_Failure : exception; -- Exception raised when assertion fails procedure Raise_Assert_Failure (Msg : String); pragma No_Return (Raise_Assert_Failure); -- Called to raise Assert_Failure with given message end System.Assertions;
-- Copyright 2018-2020 Free Software Foundation, Inc. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. package body Pack is procedure Do_Nothing (A : System.Address) is begin null; end Do_Nothing; end Pack;
PACKAGE List_Lib IS TYPE Node_Pointer IS PRIVATE; TYPE LL_Type IS PRIVATE; -- exported exceptions OUT_OF_SPACE: EXCEPTION; PAST_END: EXCEPTION; PAST_BEGIN: EXCEPTION; LL_UNDERFLOW: EXCEPTION; -------------------------------------------------------------------------- -- constructor operations PROCEDURE InitLL (One_LL: IN OUT LL_Type); -- Pre: One_LL is defined -- Post: One_LL is empty and ready to take nodes --Traverse to next key in key list PROCEDURE Next_key(L : IN OUT LL_type); --compare current key with position of hero Function CheckCurrent(L : LL_type; Xpos : integer; Ypos : Integer) Return integer; PROCEDURE Add(One_LL: IN OUT LL_Type; X: IN integer; Y : In integer); --No more keys in list Function NoKey(L : LL_type) return integer; --Print key list procedure PrintL(L : In out LL_type); -------------------------------------------------------------------------- -- input/output operations -------------------------------------------------------------------------- PRIVATE TYPE Node; TYPE Node_Pointer IS ACCESS Node; TYPE Node IS RECORD X: Integer; Y: Integer; Next: Node_Pointer; END RECORD; TYPE LL_Type IS RECORD Head: Node_Pointer; Tail: Node_Pointer; Current: Node_pointer; END RECORD; END List_Lib;
with C.elf; with C.link; with C.sys.types; package body System.Storage_Map is pragma Suppress (All_Checks); use type C.signed_int; use type C.signed_long; -- 64bit ssize_t -- the type of dlpi_phdr is different between 32bit and 64bit. function To_Address (Value : access constant C.elf.Elf32_Phdr) return Address with Import, Convention => Intrinsic; function To_Address (Value : access constant C.elf.Elf64_Phdr) return Address with Import, Convention => Intrinsic; pragma Warnings (Off, To_Address); type Rec is record First_Load_Address : Address; end record; pragma Suppress_Initialization (Rec); function Callback ( Info : access C.link.struct_dl_phdr_info; Size : C.size_t; Data : C.void_ptr) return C.signed_int with Convention => C; function Callback ( Info : access C.link.struct_dl_phdr_info; Size : C.size_t; Data : C.void_ptr) return C.signed_int is pragma Unreferenced (Size); R : Rec; for R'Address use Address (Data); begin if Standard'Address_Size <= 32 then declare use type C.elf.Elf32_Half; -- dlpi_phnum use type C.elf.Elf32_Word; -- p_type and p_vaddr type Elf32_Phdr_array is array (C.sys.types.ssize_t range <>) of aliased C.elf.Elf32_Phdr with Convention => C; dlpi_phdr : Elf32_Phdr_array ( 0 .. C.sys.types.ssize_t (Info.dlpi_phnum) - 1); for dlpi_phdr'Address use To_Address (Info.dlpi_phdr); begin for I in dlpi_phdr'Range loop if dlpi_phdr (I).p_type = C.elf.PT_LOAD then R.First_Load_Address := System'To_Address ( dlpi_phdr (I).p_vaddr + C.elf.Elf32_Addr'Mod (Info.dlpi_addr)); return 1; -- finish end if; end loop; end; else declare use type C.elf.Elf64_Half; -- dlpi_phnum use type C.elf.Elf64_Word; -- p_type use type C.elf.Elf64_Addr; -- p_vaddr type Elf64_Phdr_array is array (C.sys.types.ssize_t range <>) of aliased C.elf.Elf64_Phdr with Convention => C; dlpi_phdr : Elf64_Phdr_array ( 0 .. C.sys.types.ssize_t (Info.dlpi_phnum) - 1); for dlpi_phdr'Address use To_Address (Info.dlpi_phdr); begin for I in dlpi_phdr'Range loop if dlpi_phdr (I).p_type = C.elf.PT_LOAD then R.First_Load_Address := System'To_Address ( dlpi_phdr (I).p_vaddr + C.elf.Elf64_Addr'Mod (Info.dlpi_addr)); return 1; -- finish end if; end loop; end; end if; return 0; -- continue end Callback; -- implementation function Load_Address return Address is R : aliased Rec; Dummy : C.signed_int; begin R.First_Load_Address := Null_Address; Dummy := C.link.dl_iterate_phdr ( Callback'Access, C.void_ptr (R'Address)); return R.First_Load_Address; end Load_Address; end System.Storage_Map;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- A D A . T A S K _ A T T R I B U T E S -- -- -- -- B o d y -- -- -- -- $Revision$ -- -- -- Copyright (C) 1991-2000 Florida State University -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNARL is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNARL; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- -- -- -- GNARL was developed by the GNARL team at Florida State University. It is -- -- now maintained by Ada Core Technologies Inc. in cooperation with Florida -- -- State University (http://www.gnat.com). -- -- -- ------------------------------------------------------------------------------ -- The following notes are provided in case someone decides the -- implementation of this package is too complicated, or too slow. -- Please read this before making any "simplifications". -- Correct implementation of this package is more difficult than one -- might expect. After considering (and coding) several alternatives, -- we settled on the present compromise. Things we do not like about -- this implementation include: -- - It is vulnerable to bad Task_ID values, to the extent of -- possibly trashing memory and crashing the runtime system. -- - It requires dynamic storage allocation for each new attribute value, -- except for types that happen to be the same size as System.Address, -- or shorter. -- - Instantiations at other than the library level rely on being able to -- do down-level calls to a procedure declared in the generic package body. -- This makes it potentially vulnerable to compiler changes. -- The main implementation issue here is that the connection from -- task to attribute is a potential source of dangling references. -- When a task goes away, we want to be able to recover all the storage -- associated with its attributes. The Ada mechanism for this is -- finalization, via controlled attribute types. For this reason, -- the ARM requires finalization of attribute values when the -- associated task terminates. -- This finalization must be triggered by the tasking runtime system, -- during termination of the task. Given the active set of instantiations -- of Ada.Task_Attributes is dynamic, the number and types of attributes -- belonging to a task will not be known until the task actually terminates. -- Some of these types may be controlled and some may not. The RTS must find -- some way to determine which of these attributes need finalization, and -- invoke the appropriate finalization on them. -- One way this might be done is to create a special finalization chain -- for each task, similar to the finalization chain that is used for -- controlled objects within the task. This would differ from the usual -- finalization chain in that it would not have a LIFO structure, since -- attributes may be added to a task at any time during its lifetime. -- This might be the right way to go for the longer term, but at present -- this approach is not open, since GNAT does not provide such special -- finalization support. -- Lacking special compiler support, the RTS is limited to the -- normal ways an application invokes finalization, i.e. -- a) Explicit call to the procedure Finalize, if we know the type -- has this operation defined on it. This is not sufficient, since -- we have no way of determining whether a given generic formal -- Attribute type is controlled, and no visibility of the associated -- Finalize procedure, in the generic body. -- b) Leaving the scope of a local object of a controlled type. -- This does not help, since the lifetime of an instantiation of -- Ada.Task_Attributes does not correspond to the lifetimes of the -- various tasks which may have that attribute. -- c) Assignment of another value to the object. This would not help, -- since we then have to finalize the new value of the object. -- d) Unchecked deallocation of an object of a controlled type. -- This seems to be the only mechanism available to the runtime -- system for finalization of task attributes. -- We considered two ways of using unchecked deallocation, both based -- on a linked list of that would hang from the task control block. -- In the first approach the objects on the attribute list are all derived -- from one controlled type, say T, and are linked using an access type to -- T'Class. The runtime system has an Unchecked_Deallocation for T'Class -- with access type T'Class, and uses this to deallocate and finalize all -- the items in the list. The limitation of this approach is that each -- instantiation of the package Ada.Task_Attributes derives a new record -- extension of T, and since T is controlled (RM 3.9.1 (3)), instantiation -- is only allowed at the library level. -- In the second approach the objects on the attribute list are of -- unrelated but structurally similar types. Unchecked conversion is -- used to circument Ada type checking. Each attribute-storage node -- contains not only the attribute value and a link for chaining, but -- also a pointer to a descriptor for the corresponding instantiation -- of Task_Attributes. The instantiation-descriptor contains a -- pointer to a procedure that can do the correct deallocation and -- finalization for that type of attribute. On task termination, the -- runtime system uses the pointer to call the appropriate deallocator. -- While this gets around the limitation that instantiations be at -- the library level, it relies on an implementation feature that -- may not always be safe, i.e. that it is safe to call the -- Deallocate procedure for an instantiation of Ada.Task_Attributes -- that no longer exists. In general, it seems this might result in -- dangling references. -- Another problem with instantiations deeper than the library level -- is that there is risk of storage leakage, or dangling references -- to reused storage. That is, if an instantiation of Ada.Task_Attributes -- is made within a procedure, what happens to the storage allocated for -- attributes, when the procedure call returns? Apparently (RM 7.6.1 (4)) -- any such objects must be finalized, since they will no longer be -- accessible, and in general one would expect that the storage they occupy -- would be recovered for later reuse. (If not, we would have a case of -- storage leakage.) Assuming the storage is recovered and later reused, -- we have potentially dangerous dangling references. When the procedure -- containing the instantiation of Ada.Task_Attributes returns, there -- may still be unterminated tasks with associated attribute values for -- that instantiation. When such tasks eventually terminate, the RTS -- will attempt to call the Deallocate procedure on them. If the -- corresponding storage has already been deallocated, when the master -- of the access type was left, we have a potential disaster. This -- disaster is compounded since the pointer to Deallocate is probably -- through a "trampoline" which will also have been destroyed. -- For this reason, we arrange to remove all dangling references -- before leaving the scope of an instantiation. This is ugly, since -- it requires traversing the list of all tasks, but it is no more ugly -- than a similar traversal that we must do at the point of instantiation -- in order to initialize the attributes of all tasks. At least we only -- need to do these traversals if the type is controlled. -- We chose to defer allocation of storage for attributes until the -- Reference function is called or the attribute is first set to a value -- different from the default initial one. This allows a potential -- savings in allocation, for attributes that are not used by all tasks. -- For efficiency, we reserve space in the TCB for a fixed number of -- direct-access attributes. These are required to be of a size that -- fits in the space of an object of type System.Address. Because -- we must use unchecked bitwise copy operations on these values, they -- cannot be of a controlled type, but that is covered automatically -- since controlled objects are too large to fit in the spaces. -- We originally deferred the initialization of these direct-access -- attributes, just as we do for the indirect-access attributes, and -- used a per-task bit vector to keep track of which attributes were -- currently defined for that task. We found that the overhead of -- maintaining this bit-vector seriously slowed down access to the -- attributes, and made the fetch operation non-atomic, so that even -- to read an attribute value required locking the TCB. Therefore, -- we now initialize such attributes for all existing tasks at the time -- of the attribute instantiation, and initialize existing attributes -- for each new task at the time it is created. -- The latter initialization requires a list of all the instantiation -- descriptors. Updates to this list, as well as the bit-vector that -- is used to reserve slots for attributes in the TCB, require mutual -- exclusion. That is provided by the lock -- System.Tasking.Task_Attributes.All_Attrs_L. -- One special problem that added complexity to the design is that -- the per-task list of indirect attributes contains objects of -- different types. We use unchecked pointer conversion to link -- these nodes together and access them, but the records may not have -- identical internal structure. Initially, we thought it would be -- enough to allocate all the common components of the records at the -- front of each record, so that their positions would correspond. -- Unfortunately, GNAT adds "dope" information at the front of a record, -- if the record contains any controlled-type components. -- -- This means that the offset of the fields we use to link the nodes is -- at different positions on nodes of different types. To get around this, -- each attribute storage record consists of a core node and wrapper. -- The core nodes are all of the same type, and it is these that are -- linked together and generally "seen" by the RTS. Each core node -- contains a pointer to its own wrapper, which is a record that contains -- the core node along with an attribute value, approximately -- as follows: -- type Node; -- type Node_Access is access all Node; -- type Node_Access; -- type Access_Wrapper is access all Wrapper; -- type Node is record -- Next : Node_Access; -- ... -- Wrapper : Access_Wrapper; -- end record; -- type Wrapper is record -- Noed : aliased Node; -- Value : aliased Attribute; -- the generic formal type -- end record; -- Another interesting problem is with the initialization of -- the instantiation descriptors. Originally, we did this all via -- the Initialize procedure of the descriptor type and code in the -- package body. It turned out that the Initialize procedure needed -- quite a bit of information, including the size of the attribute -- type, the initial value of the attribute (if it fits in the TCB), -- and a pointer to the deallocator procedure. These needed to be -- "passed" in via access discriminants. GNAT was having trouble -- with access discriminants, so all this work was moved to the -- package body. with Ada.Task_Identification; -- used for Task_Id -- Null_Task_ID -- Current_Task with System.Error_Reporting; -- used for Shutdown; with System.Storage_Elements; -- used for Integer_Address with System.Task_Primitives.Operations; -- used for Write_Lock -- Unlock -- Lock/Unlock_All_Tasks_List with System.Tasking; -- used for Access_Address -- Task_ID -- Direct_Index_Vector -- Direct_Index with System.Tasking.Initialization; -- used for Defer_Abortion -- Undefer_Abortion -- Initialize_Attributes_Link -- Finalize_Attributes_Link with System.Tasking.Task_Attributes; -- used for Access_Node -- Access_Dummy_Wrapper -- Deallocator -- Instance -- Node -- Access_Instance with Ada.Exceptions; -- used for Raise_Exception with Unchecked_Conversion; with Unchecked_Deallocation; pragma Elaborate_All (System.Tasking.Task_Attributes); -- to ensure the initialization of object Local (below) will work package body Ada.Task_Attributes is use System.Error_Reporting, System.Tasking.Initialization, System.Tasking, System.Tasking.Task_Attributes, Ada.Exceptions; use type System.Tasking.Access_Address; package POP renames System.Task_Primitives.Operations; --------------------------- -- Unchecked Conversions -- --------------------------- pragma Warnings (Off); -- These unchecked conversions can give warnings when alignments -- are incorrect, but they will not be used in such cases anyway, -- so the warnings can be safely ignored. -- The following type corresponds to Dummy_Wrapper, -- declared in System.Tasking.Task_Attributes. type Wrapper; type Access_Wrapper is access all Wrapper; function To_Attribute_Handle is new Unchecked_Conversion (Access_Address, Attribute_Handle); -- For reference to directly addressed task attributes type Access_Integer_Address is access all System.Storage_Elements.Integer_Address; function To_Attribute_Handle is new Unchecked_Conversion (Access_Integer_Address, Attribute_Handle); -- For reference to directly addressed task attributes function To_Access_Address is new Unchecked_Conversion (Access_Node, Access_Address); -- To store pointer to list of indirect attributes function To_Access_Node is new Unchecked_Conversion (Access_Address, Access_Node); -- To fetch pointer to list of indirect attributes function To_Access_Wrapper is new Unchecked_Conversion (Access_Dummy_Wrapper, Access_Wrapper); -- To fetch pointer to actual wrapper of attribute node function To_Access_Dummy_Wrapper is new Unchecked_Conversion (Access_Wrapper, Access_Dummy_Wrapper); -- To store pointer to actual wrapper of attribute node function To_Task_ID is new Unchecked_Conversion (Task_Identification.Task_Id, Task_ID); -- To access TCB of identified task Null_ID : constant Task_ID := To_Task_ID (Task_Identification.Null_Task_Id); -- ??? need comments on use and purpose type Local_Deallocator is access procedure (P : in out Access_Node); function To_Lib_Level_Deallocator is new Unchecked_Conversion (Local_Deallocator, Deallocator); -- To defeat accessibility check pragma Warnings (On); ------------------------ -- Storage Management -- ------------------------ procedure Deallocate (P : in out Access_Node); -- Passed to the RTS via unchecked conversion of a pointer to -- permit finalization and deallocation of attribute storage nodes -------------------------- -- Instantiation Record -- -------------------------- Local : aliased Instance; -- Initialized in package body type Wrapper is record Noed : aliased Node; Value : aliased Attribute := Initial_Value; -- The generic formal type, may be controlled end record; procedure Free is new Unchecked_Deallocation (Wrapper, Access_Wrapper); procedure Deallocate (P : in out Access_Node) is T : Access_Wrapper := To_Access_Wrapper (P.Wrapper); begin Free (T); exception when others => pragma Assert (Shutdown ("Exception in Deallocate")); null; end Deallocate; --------------- -- Reference -- --------------- function Reference (T : Task_Identification.Task_Id := Task_Identification.Current_Task) return Attribute_Handle is TT : Task_ID := To_Task_ID (T); Error_Message : constant String := "Trying to get the reference of a"; begin if TT = Null_ID then Raise_Exception (Program_Error'Identity, Error_Message & "null task"); end if; if TT.Common.State = Terminated then Raise_Exception (Tasking_Error'Identity, Error_Message & "terminated task"); end if; begin Defer_Abortion; POP.Write_Lock (All_Attrs_L'Access); if Local.Index /= 0 then POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; return To_Attribute_Handle (TT.Direct_Attributes (Local.Index)'Access); else declare P : Access_Node := To_Access_Node (TT.Indirect_Attributes); W : Access_Wrapper; begin while P /= null loop if P.Instance = Access_Instance'(Local'Unchecked_Access) then POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; return To_Access_Wrapper (P.Wrapper).Value'Access; end if; P := P.Next; end loop; -- Unlock All_Attrs_L here to follow the lock ordering rule -- that prevent us from using new (i.e the Global_Lock) while -- holding any other lock. POP.Unlock (All_Attrs_L'Access); W := new Wrapper' ((null, Local'Unchecked_Access, null), Initial_Value); POP.Write_Lock (All_Attrs_L'Access); P := W.Noed'Unchecked_Access; P.Wrapper := To_Access_Dummy_Wrapper (W); P.Next := To_Access_Node (TT.Indirect_Attributes); TT.Indirect_Attributes := To_Access_Address (P); POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; return W.Value'Access; end; end if; pragma Assert (Shutdown ("Should never get here in Reference")); return null; exception when others => POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; raise; end; exception when Tasking_Error | Program_Error => raise; when others => raise Program_Error; end Reference; ------------------ -- Reinitialize -- ------------------ procedure Reinitialize (T : Task_Identification.Task_Id := Task_Identification.Current_Task) is TT : Task_ID := To_Task_ID (T); Error_Message : constant String := "Trying to Reinitialize a"; begin if TT = Null_ID then Raise_Exception (Program_Error'Identity, Error_Message & "null task"); end if; if TT.Common.State = Terminated then Raise_Exception (Tasking_Error'Identity, Error_Message & "terminated task"); end if; if Local.Index = 0 then declare P, Q : Access_Node; W : Access_Wrapper; begin Defer_Abortion; POP.Write_Lock (All_Attrs_L'Access); Q := To_Access_Node (TT.Indirect_Attributes); while Q /= null loop if Q.Instance = Access_Instance'(Local'Unchecked_Access) then if P = null then TT.Indirect_Attributes := To_Access_Address (Q.Next); else P.Next := Q.Next; end if; W := To_Access_Wrapper (Q.Wrapper); Free (W); POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; return; end if; P := Q; Q := Q.Next; end loop; POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; exception when others => POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; end; else Set_Value (Initial_Value, T); end if; exception when Tasking_Error | Program_Error => raise; when others => raise Program_Error; end Reinitialize; --------------- -- Set_Value -- --------------- procedure Set_Value (Val : Attribute; T : Task_Identification.Task_Id := Task_Identification.Current_Task) is TT : Task_ID := To_Task_ID (T); Error_Message : constant String := "Trying to Set the Value of a"; begin if TT = Null_ID then Raise_Exception (Program_Error'Identity, Error_Message & "null task"); end if; if TT.Common.State = Terminated then Raise_Exception (Tasking_Error'Identity, Error_Message & "terminated task"); end if; begin Defer_Abortion; POP.Write_Lock (All_Attrs_L'Access); if Local.Index /= 0 then To_Attribute_Handle (TT.Direct_Attributes (Local.Index)'Access).all := Val; POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; return; else declare P : Access_Node := To_Access_Node (TT.Indirect_Attributes); W : Access_Wrapper; begin while P /= null loop if P.Instance = Access_Instance'(Local'Unchecked_Access) then To_Access_Wrapper (P.Wrapper).Value := Val; POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; return; end if; P := P.Next; end loop; -- Unlock TT here to follow the lock ordering rule that -- prevent us from using new (i.e the Global_Lock) while -- holding any other lock. POP.Unlock (All_Attrs_L'Access); W := new Wrapper' ((null, Local'Unchecked_Access, null), Val); POP.Write_Lock (All_Attrs_L'Access); P := W.Noed'Unchecked_Access; P.Wrapper := To_Access_Dummy_Wrapper (W); P.Next := To_Access_Node (TT.Indirect_Attributes); TT.Indirect_Attributes := To_Access_Address (P); end; end if; POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; exception when others => POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; raise; end; return; exception when Tasking_Error | Program_Error => raise; when others => raise Program_Error; end Set_Value; ----------- -- Value -- ----------- function Value (T : Task_Identification.Task_Id := Task_Identification.Current_Task) return Attribute is Result : Attribute; TT : Task_ID := To_Task_ID (T); Error_Message : constant String := "Trying to get the Value of a"; begin if TT = Null_ID then Raise_Exception (Program_Error'Identity, Error_Message & "null task"); end if; if TT.Common.State = Terminated then Raise_Exception (Program_Error'Identity, Error_Message & "terminated task"); end if; begin if Local.Index /= 0 then Result := To_Attribute_Handle (TT.Direct_Attributes (Local.Index)'Access).all; else declare P : Access_Node; begin Defer_Abortion; POP.Write_Lock (All_Attrs_L'Access); P := To_Access_Node (TT.Indirect_Attributes); while P /= null loop if P.Instance = Access_Instance'(Local'Unchecked_Access) then POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; return To_Access_Wrapper (P.Wrapper).Value; end if; P := P.Next; end loop; Result := Initial_Value; POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; exception when others => POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; raise; end; end if; return Result; end; exception when Tasking_Error | Program_Error => raise; when others => raise Program_Error; end Value; -- Start of elaboration code for package Ada.Task_Attributes begin -- This unchecked conversion can give warnings when alignments -- are incorrect, but they will not be used in such cases anyway, -- so the warnings can be safely ignored. pragma Warnings (Off); Local.Deallocate := To_Lib_Level_Deallocator (Deallocate'Access); pragma Warnings (On); declare Two_To_J : Direct_Index_Vector; begin Defer_Abortion; POP.Write_Lock (All_Attrs_L'Access); -- Add this instantiation to the list of all instantiations. Local.Next := System.Tasking.Task_Attributes.All_Attributes; System.Tasking.Task_Attributes.All_Attributes := Local'Unchecked_Access; -- Try to find space for the attribute in the TCB. Local.Index := 0; Two_To_J := 2 ** Direct_Index'First; if Attribute'Size <= System.Address'Size then for J in Direct_Index loop if (Two_To_J and In_Use) /= 0 then -- Reserve location J for this attribute In_Use := In_Use or Two_To_J; Local.Index := J; -- This unchecked conversions can give a warning when the -- the alignment is incorrect, but it will not be used in -- such a case anyway, so the warning can be safely ignored. pragma Warnings (Off); To_Attribute_Handle (Local.Initial_Value'Access).all := Initial_Value; pragma Warnings (On); exit; end if; Two_To_J := Two_To_J * 2; end loop; end if; -- Need protection of All_Tasks_L for updating links to -- per-task initialization and finalization routines, -- in case some task is being created or terminated concurrently. POP.Lock_All_Tasks_List; -- Attribute goes directly in the TCB if Local.Index /= 0 then -- Replace stub for initialization routine -- that is called at task creation. Initialization.Initialize_Attributes_Link := System.Tasking.Task_Attributes.Initialize_Attributes'Access; -- Initialize the attribute, for all tasks. declare C : System.Tasking.Task_ID := System.Tasking.All_Tasks_List; begin while C /= null loop POP.Write_Lock (C); C.Direct_Attributes (Local.Index) := System.Storage_Elements.To_Address (Local.Initial_Value); POP.Unlock (C); C := C.Common.All_Tasks_Link; end loop; end; -- Attribute goes into a node onto a linked list else -- Replace stub for finalization routine -- that is called at task termination. Initialization.Finalize_Attributes_Link := System.Tasking.Task_Attributes.Finalize_Attributes'Access; end if; POP.Unlock_All_Tasks_List; POP.Unlock (All_Attrs_L'Access); Undefer_Abortion; exception when others => null; pragma Assert (Shutdown ("Exception in task attribute initializer")); -- If we later decide to allow exceptions to propagate, we need to -- not only release locks and undefer abortion, we also need to undo -- any initializations that succeeded up to this point, or we will -- risk a dangling reference when the task terminates. end; end Ada.Task_Attributes;
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <!DOCTYPE boost_serialization> <boost_serialization signature="serialization::archive" version="14"> <syndb class_id="0" tracking_level="0" version="0"> <userIPLatency>-1</userIPLatency> <userIPName/> <cdfg class_id="1" tracking_level="1" version="0" object_id="_0"> <name>p_source_files_sr</name> <ret_bitwidth>64</ret_bitwidth> <ports class_id="2" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="3" tracking_level="1" version="0" object_id="_1"> <Value class_id="4" tracking_level="0" version="0"> <Obj class_id="5" tracking_level="0" version="0"> <type>1</type> <id>1</id> <name>p_read</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo class_id="6" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>64</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs class_id="7" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> </ports> <nodes class_id="8" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="9" tracking_level="1" version="0" object_id="_2"> <Value> <Obj> <type>0</type> <id>2</id> <name>p_read_1</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>6</item> <item>7</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_3"> <Value> <Obj> <type>0</type> <id>3</id> <name/> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>8</item> </oprand_edges> <opcode>ret</opcode> <m_Display>0</m_Display> </item> </nodes> <consts class_id="11" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </consts> <blocks class_id="12" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="13" tracking_level="1" version="0" object_id="_4"> <Obj> <type>3</type> <id>4</id> <name>__../source_files/sr</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <node_objs> <count>2</count> <item_version>0</item_version> <item>2</item> <item>3</item> </node_objs> </item> </blocks> <edges class_id="14" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="15" tracking_level="1" version="0" object_id="_5"> <id>7</id> <edge_type>1</edge_type> <source_obj>1</source_obj> <sink_obj>2</sink_obj> </item> <item class_id_reference="15" object_id="_6"> <id>8</id> <edge_type>1</edge_type> <source_obj>2</source_obj> <sink_obj>3</sink_obj> </item> </edges> </cdfg> <cdfg_regions class_id="16" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="17" tracking_level="1" version="0" object_id="_7"> <mId>1</mId> <mTag>__../source_files/sr</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>4</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>0</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"/> </item> </cdfg_regions> <fsm class_id="19" tracking_level="1" version="0" object_id="_8"> <states class_id="20" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="21" tracking_level="1" version="0" object_id="_9"> <id>1</id> <operations class_id="22" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="23" tracking_level="1" version="0" object_id="_10"> <id>2</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="23" object_id="_11"> <id>3</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> </states> <transitions class_id="24" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </transitions> </fsm> <res class_id="25" tracking_level="1" version="0" object_id="_12"> <dp_component_resource class_id="26" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_component_resource> <dp_expression_resource> <count>1</count> <item_version>0</item_version> <item class_id="27" tracking_level="0" version="0"> <first>ap_block_state1 ( or ) </first> <second class_id="28" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="29" tracking_level="0" version="0"> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>1</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>2</second> </item> </second> </item> </dp_expression_resource> <dp_fifo_resource> <count>0</count> <item_version>0</item_version> </dp_fifo_resource> <dp_memory_resource> <count>0</count> <item_version>0</item_version> </dp_memory_resource> <dp_multiplexer_resource> <count>2</count> <item_version>0</item_version> <item> <first>ap_done</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>ap_return</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>64</second> </item> <item> <first>(2Count)</first> <second>128</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> </dp_multiplexer_resource> <dp_register_resource> <count>3</count> <item_version>0</item_version> <item> <first>ap_CS_fsm</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_done_reg</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_return_preg</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>64</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>64</second> </item> </second> </item> </dp_register_resource> <dp_component_map class_id="30" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_component_map> <dp_expression_map> <count>0</count> <item_version>0</item_version> </dp_expression_map> <dp_fifo_map> <count>0</count> <item_version>0</item_version> </dp_fifo_map> <dp_memory_map> <count>0</count> <item_version>0</item_version> </dp_memory_map> </res> <node_label_latency class_id="31" tracking_level="0" version="0"> <count>2</count> <item_version>0</item_version> <item class_id="32" tracking_level="0" version="0"> <first>2</first> <second class_id="33" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>3</first> <second> <first>0</first> <second>0</second> </second> </item> </node_label_latency> <bblk_ent_exit class_id="34" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="35" tracking_level="0" version="0"> <first>4</first> <second class_id="36" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> </bblk_ent_exit> <regions class_id="37" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </regions> <dp_fu_nodes class_id="38" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="39" tracking_level="0" version="0"> <first>4</first> <second> <count>1</count> <item_version>0</item_version> <item>2</item> </second> </item> </dp_fu_nodes> <dp_fu_nodes_expression class_id="41" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_fu_nodes_expression> <dp_fu_nodes_module> <count>0</count> <item_version>0</item_version> </dp_fu_nodes_module> <dp_fu_nodes_io> <count>1</count> <item_version>0</item_version> <item class_id="42" tracking_level="0" version="0"> <first>p_read_1_read_fu_4</first> <second> <count>1</count> <item_version>0</item_version> <item>2</item> </second> </item> </dp_fu_nodes_io> <return_ports> <count>1</count> <item_version>0</item_version> <item> <first>ap_return</first> <second> <count>1</count> <item_version>0</item_version> <item>3</item> </second> </item> </return_ports> <dp_mem_port_nodes class_id="43" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_mem_port_nodes> <dp_reg_nodes> <count>0</count> <item_version>0</item_version> </dp_reg_nodes> <dp_regname_nodes> <count>0</count> <item_version>0</item_version> </dp_regname_nodes> <dp_reg_phi> <count>0</count> <item_version>0</item_version> </dp_reg_phi> <dp_regname_phi> <count>0</count> <item_version>0</item_version> </dp_regname_phi> <dp_port_io_nodes class_id="44" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="45" tracking_level="0" version="0"> <first>p_read</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>2</item> </second> </item> </second> </item> </dp_port_io_nodes> <port2core class_id="46" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </port2core> <node2core> <count>0</count> <item_version>0</item_version> </node2core> </syndb> </boost_serialization>
-- pragma SPARK_Mode; with Types; use Types; with Interfaces.C; use Interfaces.C; -- @summary -- Interface to the robots 3-axis gyroscope -- -- @description -- This package exposes the interface to the robot's 3 axis gyroscope -- package Zumo_L3gd20h is -- The gain to apply to a sensor reading Gain : constant := 0.07; -- degrees/s/digit -- True if package is init'd Initd : Boolean := False; -- Inits the package. Pin muxing and whatnot. procedure Init with Global => (In_Out => Initd), Pre => not Initd, Post => Initd; -- Read the temperature of the sensor -- @return a byte value with the temperature function Read_Temp return signed_char with Pre => Initd; -- Read the status of the sensor -- @return a byte value with the status function Read_Status return Byte with Pre => Initd; -- Read the gyro of the sensor -- @param Data the read data from the sensor procedure Read_Gyro (Data : out Axis_Data) with Pre => Initd; L3GD20H_Exception : exception; private -- Reads the WHOAMI register from the sensor and compares it against -- the known value procedure Check_WHOAMI; -- The mapping of registers in the sensor -- @value WHO_AM_I Device identification register -- @value CTRL1 control 1 register -- @value CTRL2 control 2 register -- @value CTRL3 control 3 register -- @value CTRL4 control 4 register -- @value CTRL5 control 5 register -- @value REFERENCE Digital high pass filter reference value -- @value OUT_TEMP Temperature data (-1LSB/deg with 8 bit resolution). -- The value is expressed as two's complement. -- @value STATUS sensor status register -- @value OUT_X_L X-axis angular rate data low register -- @value OUT_X_H X-axis angular rate data high register -- @value OUT_Y_L Y-axis angular rate data low register -- @value OUT_Y_H Y-axis angular rate data high register -- @value OUT_Z_L Z-axis angular rate data low register -- @value OUT_Z_H Z-axis angular rate data high register -- @value FIFO_CTRL fifo control register -- @value FIFO_SRC stored data level in fifo type Reg_Index is (WHO_AM_I, CTRL1, CTRL2, CTRL3, CTRL4, CTRL5, REFERENCE, OUT_TEMP, STATUS, OUT_X_L, OUT_X_H, OUT_Y_L, OUT_Y_H, OUT_Z_L, OUT_Z_H, FIFO_CTRL, FIFO_SRC, IG_CFG, IG_SRC, IG_THS_XH, IG_THS_XL, IG_THS_YH, IG_THS_YL, IG_THS_ZH, IG_THS_ZL, IG_DURATION, LOW_ODR); -- Mapping of register enums to actual register addresses Regs : constant array (Reg_Index) of Byte := (WHO_AM_I => 16#0F#, CTRL1 => 16#20#, CTRL2 => 16#21#, CTRL3 => 16#22#, CTRL4 => 16#23#, CTRL5 => 16#24#, REFERENCE => 16#25#, OUT_TEMP => 16#26#, STATUS => 16#27#, OUT_X_L => 16#28#, OUT_X_H => 16#29#, OUT_Y_L => 16#2A#, OUT_Y_H => 16#2B#, OUT_Z_L => 16#2C#, OUT_Z_H => 16#2D#, FIFO_CTRL => 16#2E#, FIFO_SRC => 16#2F#, IG_CFG => 16#30#, IG_SRC => 16#31#, IG_THS_XH => 16#32#, IG_THS_XL => 16#33#, IG_THS_YH => 16#34#, IG_THS_YL => 16#35#, IG_THS_ZH => 16#36#, IG_THS_ZL => 16#37#, IG_DURATION => 16#38#, LOW_ODR => 16#39#); type Register_Bytes is record Register : Reg_Index; Value : Byte; end record; type Register_Byte_Array is array (Natural range <>) of Register_Bytes; end Zumo_L3gd20h;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Localization, Internationalization, Globalization for Ada -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2011, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- This is x86_64 specific version of the package. ------------------------------------------------------------------------------ with Matreshka.Internals.Strings.Handlers.X86_64; package Matreshka.Internals.Strings.Configuration is pragma Preelaborate; String_Handler : not null access Matreshka.Internals.Strings.Handlers.Abstract_String_Handler'Class := Matreshka.Internals.Strings.Handlers.X86_64.Handler'Access; -- Platform dependent strings handler to be used for operations on strings. procedure Initialize; -- Setup most optimal string handler. end Matreshka.Internals.Strings.Configuration;
------------------------------------------------------------------------------ -- -- -- Copyright (c) 2016 Vitalij Bondarenko <vibondare@gmail.com> -- -- -- ------------------------------------------------------------------------------ -- -- -- The MIT License (MIT) -- -- -- -- Permission is hereby granted, free of charge, to any person obtaining a -- -- copy of this software and associated documentation files (the -- -- "Software"), to deal in the Software without restriction, including -- -- without limitation the rights to use, copy, modify, merge, publish, -- -- distribute, sublicense, and/or sell copies of the Software, and to -- -- permit persons to whom the Software is furnished to do so, subject to -- -- the following conditions: -- -- -- -- The above copyright notice and this permission notice shall be included -- -- in all copies or substantial portions of the Software. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- -- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- -- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- -- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -- -- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -- -- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -- -- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- ------------------------------------------------------------------------------ with Formatted_Output.Integer_Output; package Formatted_Output_Short_Short_Integer is new Formatted_Output.Integer_Output (Short_Short_Integer);
-- The Cupcake GUI Toolkit -- (c) Kristian Klomsten Skordal 2012 <kristian.skordal@gmail.com> -- Report bugs and issues on <http://github.com/skordal/cupcake/issues> -- vim:ts=3:sw=3:et:si:sta with Ada.Numerics; with System; with Cupcake.Colors; with Cupcake.Primitives; package Cupcake.Backends is use Ada.Numerics; -- Interface implemented by backends: type Backend is limited interface; type Backend_Access is access all Backend'Class; -- Backend exceptions: Initialization_Error : exception; -- Gets and sets the backend to be used for operations: function Get_Backend return Backend_Access with Inline, Pure_Function; procedure Set_Backend (Use_Backend : in Backend_Access) with Inline; ---- GENERAL BACKEND OPERATIONS: ---- -- Gets the name of the backend: function Get_Name (This : in Backend) return String is abstract; -- Initializes the backend: procedure Initialize (This : in out Backend) is abstract; -- Checks if the backend has been initialized: function Is_Initialized (This : in Backend) return Boolean is abstract; -- Finalizes the backend: procedure Finalize (This : in out Backend) is abstract; -- Enters the main loop: procedure Enter_Main_Loop (This : in out Backend) is abstract; -- Exits the main loop: procedure Exit_Main_Loop (This : in out Backend) is abstract; ---- BACKEND WINDOW OPERATIONS: ---- -- Backend window type: type Window_Data_Pointer is new System.Address; Null_Window_Data_Pointer : constant Window_Data_Pointer := Window_Data_Pointer (System.Null_Address); -- Type used for window IDs: type Window_ID_Type is mod 2**32; for Window_ID_Type'Size use 32; -- Creates a new window: function New_Window (This : in Backend; Title : in String; Size : in Primitives.Dimension; Position : in Primitives.Point := (0, 0); Parent : in Window_Data_Pointer := Null_Window_Data_Pointer) return Window_Data_Pointer is abstract; -- Destroys a window: procedure Destroy_Window (This : in out Backend; Window_Data : in out Window_Data_Pointer) is abstract; -- Gets the ID of a window: function Get_Window_ID (This : in Backend; Window_Data : in Window_Data_Pointer) return Window_ID_Type is abstract; -- Sets the title of a window: procedure Set_Window_Title (This : in Backend; Window_Data : in Window_Data_Pointer; Title : in String) is abstract; -- Sets the size of a window: procedure Set_Window_Size (This : in Backend; Window_Data : in Window_Data_Pointer; Size : in Primitives.Dimension) is abstract; -- Sets the window visibility on screen: procedure Set_Window_Visibility (This : in Backend; Window_Data : in Window_Data_Pointer; Visibility : in Boolean) is abstract; ---- WINDOW DRAWING OPERATIONS: ---- -- Draws a straight line between two points: procedure Draw_Line (This : in out Backend; Window_Data : in Window_Data_Pointer; Origin, Destination : in Primitives.Point; Color : in Colors.Color := Colors.BLACK; Line_Width : in Float := 1.0) is abstract; -- Draws a circle with specified centre and radius; draws the circle -- between 0 and the specified amount of radians. This value can be -- negative, in which case the circle will be drawn counter-clockwise: procedure Draw_Circle (This : in out Backend; Window_Data : in Window_Data_Pointer; Origin : in Primitives.Point; Radius : in Float; Arc : in Float := 2.0 * Pi; Color : in Colors.Color := Colors.BLACK; Line_Width : in Float := 1.0) is abstract; -- Fills the specified area with the specified color: procedure Fill_Area (This : in out Backend; Window_Data : in Window_Data_Pointer; Area : in Primitives.Rectangle; Color : in Colors.Color) is abstract; ---- FONT OPERATIONS: ---- -- Backend font type: type Font_Data_Pointer is new System.Address; private -- The active backend: Active_Backend : Backend_Access := null; end Cupcake.Backends;
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <!DOCTYPE boost_serialization> <boost_serialization signature="serialization::archive" version="14"> <syndb class_id="0" tracking_level="0" version="0"> <userIPLatency>-1</userIPLatency> <userIPName/> <cdfg class_id="1" tracking_level="1" version="0" object_id="_0"> <name>rgb2yuv11</name> <ret_bitwidth>0</ret_bitwidth> <ports class_id="2" tracking_level="0" version="0"> <count>16</count> <item_version>0</item_version> <item class_id="3" tracking_level="1" version="0" object_id="_1"> <Value class_id="4" tracking_level="0" version="0"> <Obj class_id="5" tracking_level="0" version="0"> <type>1</type> <id>1</id> <name>in_channels_ch1</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo class_id="6" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>in.channels.ch1</originalName> <rtlName/> <coreName>RAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>0</direction> <if_type>1</if_type> <array_size>2457600</array_size> <bit_vecs class_id="7" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_2"> <Value> <Obj> <type>1</type> <id>2</id> <name>in_channels_ch2</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>in.channels.ch2</originalName> <rtlName/> <coreName>RAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>0</direction> <if_type>1</if_type> <array_size>2457600</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_3"> <Value> <Obj> <type>1</type> <id>3</id> <name>in_channels_ch3</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>in.channels.ch3</originalName> <rtlName/> <coreName>RAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>0</direction> <if_type>1</if_type> <array_size>2457600</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_4"> <Value> <Obj> <type>1</type> <id>4</id> <name>in_width</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>in.width</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_5"> <Value> <Obj> <type>1</type> <id>5</id> <name>in_height</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>in.height</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_6"> <Value> <Obj> <type>1</type> <id>6</id> <name>out_channels_ch1</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>out.channels.ch1</originalName> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_7"> <Value> <Obj> <type>1</type> <id>7</id> <name>out_channels_ch2</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>out.channels.ch2</originalName> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_8"> <Value> <Obj> <type>1</type> <id>8</id> <name>out_channels_ch3</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>out.channels.ch3</originalName> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_9"> <Value> <Obj> <type>1</type> <id>9</id> <name>out_width</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>out.width</originalName> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_10"> <Value> <Obj> <type>1</type> <id>10</id> <name>out_height</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>out.height</originalName> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>16</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_11"> <Value> <Obj> <type>1</type> <id>11</id> <name>Y_scale</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_12"> <Value> <Obj> <type>1</type> <id>12</id> <name>U_scale</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_13"> <Value> <Obj> <type>1</type> <id>13</id> <name>V_scale</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <direction>0</direction> <if_type>0</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_14"> <Value> <Obj> <type>1</type> <id>14</id> <name>Y_scale_out</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_15"> <Value> <Obj> <type>1</type> <id>15</id> <name>U_scale_out</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> <item class_id_reference="3" object_id="_16"> <Value> <Obj> <type>1</type> <id>16</id> <name>V_scale_out</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName>FIFO_LUTRAM</coreName> </Obj> <bitwidth>8</bitwidth> </Value> <direction>1</direction> <if_type>3</if_type> <array_size>0</array_size> <bit_vecs> <count>0</count> <item_version>0</item_version> </bit_vecs> </item> </ports> <nodes class_id="8" tracking_level="0" version="0"> <count>93</count> <item_version>0</item_version> <item class_id="9" tracking_level="1" version="0" object_id="_17"> <Value> <Obj> <type>0</type> <id>23</id> <name>V_scale_read</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>129</item> <item>130</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_18"> <Value> <Obj> <type>0</type> <id>24</id> <name>U_scale_read</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>131</item> <item>132</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_19"> <Value> <Obj> <type>0</type> <id>25</id> <name>Y_scale_read</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>133</item> <item>134</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_20"> <Value> <Obj> <type>0</type> <id>26</id> <name/> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>136</item> <item>137</item> <item>138</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_21"> <Value> <Obj> <type>0</type> <id>28</id> <name/> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>139</item> <item>140</item> <item>141</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_22"> <Value> <Obj> <type>0</type> <id>30</id> <name/> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>142</item> <item>143</item> <item>144</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_23"> <Value> <Obj> <type>0</type> <id>31</id> <name>width</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>43</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item class_id="11" tracking_level="0" version="0"> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second class_id="12" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="13" tracking_level="0" version="0"> <first class_id="14" tracking_level="0" version="0"> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>43</second> </item> </second> </item> </inlineStackInfo> <originalName>width</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>146</item> <item>147</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_24"> <Value> <Obj> <type>0</type> <id>32</id> <name>height</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>44</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>44</second> </item> </second> </item> </inlineStackInfo> <originalName>height</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>148</item> <item>149</item> </oprand_edges> <opcode>read</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_25"> <Value> <Obj> <type>0</type> <id>33</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>45</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>45</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>151</item> <item>152</item> <item>153</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_26"> <Value> <Obj> <type>0</type> <id>34</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>46</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>46</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>154</item> <item>155</item> <item>156</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_27"> <Value> <Obj> <type>0</type> <id>35</id> <name>cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>43</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>43</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>bound_fu_594_p10</rtlName> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>157</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_28"> <Value> <Obj> <type>0</type> <id>36</id> <name>cast1</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>44</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>44</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>bound_fu_594_p00</rtlName> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>158</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_29"> <Value> <Obj> <type>0</type> <id>37</id> <name>bound</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>44</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>44</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mul_mubkb_U1</rtlName> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>159</item> <item>160</item> </oprand_edges> <opcode>mul</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_30"> <Value> <Obj> <type>0</type> <id>38</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>49</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>49</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>161</item> </oprand_edges> <opcode>br</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_31"> <Value> <Obj> <type>0</type> <id>40</id> <name>indvar_flatten</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>163</item> <item>164</item> <item>165</item> <item>166</item> </oprand_edges> <opcode>phi</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_32"> <Value> <Obj> <type>0</type> <id>41</id> <name>x_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>168</item> <item>169</item> <item>170</item> <item>171</item> </oprand_edges> <opcode>phi</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_33"> <Value> <Obj> <type>0</type> <id>42</id> <name>y_i_i</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName>y</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>172</item> <item>173</item> <item>174</item> <item>175</item> </oprand_edges> <opcode>phi</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_34"> <Value> <Obj> <type>0</type> <id>43</id> <name>exitcond_flatten</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>44</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>44</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>exitcond_flatten_fu_302_p2</rtlName> <coreName/> </Obj> <bitwidth>1</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>176</item> <item>177</item> </oprand_edges> <opcode>icmp</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_35"> <Value> <Obj> <type>0</type> <id>44</id> <name>indvar_flatten_next</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName>indvar_flatten_next_fu_307_p2</rtlName> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>178</item> <item>180</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_36"> <Value> <Obj> <type>0</type> <id>45</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>44</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>44</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>181</item> <item>182</item> <item>183</item> </oprand_edges> <opcode>br</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_37"> <Value> <Obj> <type>0</type> <id>47</id> <name>x</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>49</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>49</second> </item> </second> </item> </inlineStackInfo> <originalName>x</originalName> <rtlName>x_fu_313_p2</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>185</item> <item>186</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_38"> <Value> <Obj> <type>0</type> <id>50</id> <name>exitcond_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>52</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>52</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>exitcond_i_i_fu_319_p2</rtlName> <coreName/> </Obj> <bitwidth>1</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>187</item> <item>188</item> </oprand_edges> <opcode>icmp</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_39"> <Value> <Obj> <type>0</type> <id>51</id> <name>y_i_i_mid2</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>52</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>52</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>y_i_i_mid2_fu_324_p3</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>189</item> <item>190</item> <item>191</item> </oprand_edges> <opcode>select</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_40"> <Value> <Obj> <type>0</type> <id>52</id> <name>tmp_i_i_mid2_v</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_i_i_mid2_v_fu_332_p3</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>192</item> <item>193</item> <item>194</item> </oprand_edges> <opcode>select</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_41"> <Value> <Obj> <type>0</type> <id>53</id> <name>tmp_22</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_22_fu_340_p1</rtlName> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>195</item> </oprand_edges> <opcode>trunc</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_42"> <Value> <Obj> <type>0</type> <id>54</id> <name>p_shl_cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl_cast_fu_348_p3</rtlName> <coreName/> </Obj> <bitwidth>23</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>197</item> <item>198</item> <item>200</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_43"> <Value> <Obj> <type>0</type> <id>55</id> <name>tmp_23</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_23_fu_344_p1</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>201</item> </oprand_edges> <opcode>trunc</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_44"> <Value> <Obj> <type>0</type> <id>56</id> <name>p_shl1_cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl1_cast_fu_355_p3</rtlName> <coreName/> </Obj> <bitwidth>23</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>203</item> <item>204</item> <item>206</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_45"> <Value> <Obj> <type>0</type> <id>57</id> <name>tmp_s</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_s_fu_362_p2</rtlName> <coreName/> </Obj> <bitwidth>23</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>207</item> <item>208</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_46"> <Value> <Obj> <type>0</type> <id>61</id> <name>tmp_i_i_cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_i_i_cast_fu_368_p1</rtlName> <coreName/> </Obj> <bitwidth>23</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>209</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_47"> <Value> <Obj> <type>0</type> <id>62</id> <name>tmp_24</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_24_fu_371_p2</rtlName> <coreName/> </Obj> <bitwidth>23</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>210</item> <item>211</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_48"> <Value> <Obj> <type>0</type> <id>63</id> <name>tmp_26_cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_26_cast_fu_382_p1</rtlName> <coreName/> </Obj> <bitwidth>64</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>212</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_49"> <Value> <Obj> <type>0</type> <id>64</id> <name>in_channels_ch1_addr</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>22</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>213</item> <item>215</item> <item>216</item> </oprand_edges> <opcode>getelementptr</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_50"> <Value> <Obj> <type>0</type> <id>65</id> <name>in_channels_ch2_addr</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>55</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>55</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>22</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>217</item> <item>218</item> <item>219</item> </oprand_edges> <opcode>getelementptr</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_51"> <Value> <Obj> <type>0</type> <id>66</id> <name>in_channels_ch3_addr</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>56</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>56</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>22</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>220</item> <item>221</item> <item>222</item> </oprand_edges> <opcode>getelementptr</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_52"> <Value> <Obj> <type>0</type> <id>67</id> <name>R</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>54</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>54</second> </item> </second> </item> </inlineStackInfo> <originalName>R</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>223</item> </oprand_edges> <opcode>load</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_53"> <Value> <Obj> <type>0</type> <id>68</id> <name>G</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>55</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>55</second> </item> </second> </item> </inlineStackInfo> <originalName>G</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>224</item> </oprand_edges> <opcode>load</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_54"> <Value> <Obj> <type>0</type> <id>69</id> <name>B</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>56</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>56</second> </item> </second> </item> </inlineStackInfo> <originalName>B</originalName> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>225</item> </oprand_edges> <opcode>load</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_55"> <Value> <Obj> <type>0</type> <id>70</id> <name>tmp_40_cast14_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_40_cast14_i_i_fu_406_p1</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>226</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_56"> <Value> <Obj> <type>0</type> <id>71</id> <name>p_shl5_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl5_i_i_fu_409_p3</rtlName> <coreName/> </Obj> <bitwidth>14</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>228</item> <item>229</item> <item>231</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_57"> <Value> <Obj> <type>0</type> <id>72</id> <name>p_shl5_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl5_cast_i_i_fu_416_p1</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>232</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_58"> <Value> <Obj> <type>0</type> <id>73</id> <name>p_shl6_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl6_i_i_fu_388_p3</rtlName> <coreName/> </Obj> <bitwidth>9</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>234</item> <item>235</item> <item>237</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_59"> <Value> <Obj> <type>0</type> <id>74</id> <name>p_shl6_cast_i_i_cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl6_cast_i_i_cast_fu_396_p1</rtlName> <coreName/> </Obj> <bitwidth>10</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>238</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_60"> <Value> <Obj> <type>0</type> <id>75</id> <name>tmp_42_cast11_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_42_cast11_i_i_fu_543_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>239</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_61"> <Value> <Obj> <type>0</type> <id>76</id> <name>tmp_42_cast11_i_i_ca</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>grp_fu_600_p20</rtlName> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>240</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_62"> <Value> <Obj> <type>0</type> <id>77</id> <name>p_shl4_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl4_i_i_fu_423_p3</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>242</item> <item>243</item> <item>245</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_63"> <Value> <Obj> <type>0</type> <id>78</id> <name>p_shl4_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl4_cast_i_i_fu_430_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>246</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_64"> <Value> <Obj> <type>0</type> <id>79</id> <name>tmp_44_cast10_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>grp_fu_600_p10</rtlName> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>247</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_65"> <Value> <Obj> <type>0</type> <id>80</id> <name>tmp_45_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mucud_U2</rtlName> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>249</item> <item>250</item> </oprand_edges> <opcode>mul</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_66"> <Value> <Obj> <type>0</type> <id>81</id> <name>tmp</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_fu_400_p2</rtlName> <coreName/> </Obj> <bitwidth>10</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>252</item> <item>253</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_67"> <Value> <Obj> <type>0</type> <id>82</id> <name>tmp_cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_cast_fu_437_p1</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>254</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_68"> <Value> <Obj> <type>0</type> <id>83</id> <name>tmp_46_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_46_i_i_fu_440_p2</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>255</item> <item>256</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_69"> <Value> <Obj> <type>0</type> <id>84</id> <name>tmp_46_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_46_cast_i_i_fu_446_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>257</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_70"> <Value> <Obj> <type>0</type> <id>85</id> <name>tmp1</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp1_fu_450_p2</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>258</item> <item>259</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_71"> <Value> <Obj> <type>0</type> <id>86</id> <name>tmp2</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mucud_U2</rtlName> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>260</item> <item>261</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_72"> <Value> <Obj> <type>0</type> <id>87</id> <name>tmp2_cast</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp2_cast_fu_456_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>262</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_73"> <Value> <Obj> <type>0</type> <id>88</id> <name>tmp_48_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_48_i_i_fu_459_p2</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>263</item> <item>264</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_74"> <Value> <Obj> <type>0</type> <id>89</id> <name>tmp_50_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_50_i_i_reg_734</rtlName> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>266</item> <item>267</item> <item>269</item> <item>271</item> </oprand_edges> <opcode>partselect</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_75"> <Value> <Obj> <type>0</type> <id>90</id> <name>Y</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>57</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>57</second> </item> </second> </item> </inlineStackInfo> <originalName>Y</originalName> <rtlName>out_channels_ch1_din</rtlName> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>273</item> <item>274</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_76"> <Value> <Obj> <type>0</type> <id>91</id> <name>tmp_51_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mudEe_U3</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>276</item> <item>277</item> </oprand_edges> <opcode>mul</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_77"> <Value> <Obj> <type>0</type> <id>92</id> <name>tmp_52_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mufYi_U5</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>279</item> <item>280</item> </oprand_edges> <opcode>mul</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_78"> <Value> <Obj> <type>0</type> <id>93</id> <name>p_shl2_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl2_i_i_fu_475_p3</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>281</item> <item>282</item> <item>283</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_79"> <Value> <Obj> <type>0</type> <id>94</id> <name>p_shl2_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl2_cast_i_i_fu_482_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>284</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_80"> <Value> <Obj> <type>0</type> <id>95</id> <name>p_shl3_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl3_i_i_fu_486_p3</rtlName> <coreName/> </Obj> <bitwidth>12</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>286</item> <item>287</item> <item>289</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_81"> <Value> <Obj> <type>0</type> <id>96</id> <name>p_shl3_cast7_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl3_cast7_i_i_fu_493_p1</rtlName> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>290</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_82"> <Value> <Obj> <type>0</type> <id>97</id> <name>p_shl3_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl3_cast_i_i_fu_497_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>291</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_83"> <Value> <Obj> <type>0</type> <id>98</id> <name>tmp_53_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_53_i_i_fu_501_p2</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>292</item> <item>293</item> </oprand_edges> <opcode>sub</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_84"> <Value> <Obj> <type>0</type> <id>99</id> <name>tmp_54_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mudEe_U3</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>295</item> <item>296</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_85"> <Value> <Obj> <type>0</type> <id>100</id> <name>tmp_54_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_54_cast_i_i_fu_507_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>297</item> </oprand_edges> <opcode>sext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_86"> <Value> <Obj> <type>0</type> <id>101</id> <name>tmp3</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp3_fu_510_p2</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>298</item> <item>299</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_87"> <Value> <Obj> <type>0</type> <id>102</id> <name>tmp_56_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mufYi_U5</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>300</item> <item>301</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_88"> <Value> <Obj> <type>0</type> <id>103</id> <name>tmp_58_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_58_i_i_reg_754</rtlName> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>302</item> <item>303</item> <item>304</item> <item>305</item> </oprand_edges> <opcode>partselect</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_89"> <Value> <Obj> <type>0</type> <id>104</id> <name>U</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName>U</originalName> <rtlName>out_channels_ch2_din</rtlName> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>306</item> <item>308</item> </oprand_edges> <opcode>xor</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_90"> <Value> <Obj> <type>0</type> <id>105</id> <name>tmp_59_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mueOg_U4</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>310</item> <item>311</item> </oprand_edges> <opcode>mul</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_91"> <Value> <Obj> <type>0</type> <id>106</id> <name>tmp_60_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mufYi_U6</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>313</item> <item>314</item> </oprand_edges> <opcode>mul</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_92"> <Value> <Obj> <type>0</type> <id>107</id> <name>p_neg_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_neg_i_i_fu_516_p2</rtlName> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>316</item> <item>317</item> </oprand_edges> <opcode>sub</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_93"> <Value> <Obj> <type>0</type> <id>108</id> <name>p_neg_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>58</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>58</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_neg_cast_i_i_fu_522_p1</rtlName> <coreName/> </Obj> <bitwidth>14</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>318</item> </oprand_edges> <opcode>sext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_94"> <Value> <Obj> <type>0</type> <id>109</id> <name>p_shl1_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl1_i_i_fu_526_p3</rtlName> <coreName/> </Obj> <bitwidth>9</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>319</item> <item>320</item> <item>321</item> </oprand_edges> <opcode>bitconcatenate</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_95"> <Value> <Obj> <type>0</type> <id>110</id> <name>p_shl1_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>p_shl1_cast_i_i_fu_533_p1</rtlName> <coreName/> </Obj> <bitwidth>14</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>322</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_96"> <Value> <Obj> <type>0</type> <id>111</id> <name>tmp_61_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_61_i_i_fu_537_p2</rtlName> <coreName/> </Obj> <bitwidth>14</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>323</item> <item>324</item> </oprand_edges> <opcode>sub</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_97"> <Value> <Obj> <type>0</type> <id>112</id> <name>tmp_61_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_61_cast_i_i_fu_555_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>325</item> </oprand_edges> <opcode>sext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_98"> <Value> <Obj> <type>0</type> <id>113</id> <name>tmp_62_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mueOg_U4</rtlName> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>326</item> <item>327</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_99"> <Value> <Obj> <type>0</type> <id>114</id> <name>tmp_62_cast_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_62_cast_i_i_fu_558_p1</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>328</item> </oprand_edges> <opcode>zext</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_100"> <Value> <Obj> <type>0</type> <id>115</id> <name>tmp4</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>grp_fu_634_p2</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>329</item> <item>330</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_101"> <Value> <Obj> <type>0</type> <id>116</id> <name>tmp_64_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>yuv_filter_mac_mufYi_U6</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>331</item> <item>332</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_102"> <Value> <Obj> <type>0</type> <id>117</id> <name>tmp_66_i_i</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName>tmp_66_i_i_reg_759</rtlName> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>4</count> <item_version>0</item_version> <item>333</item> <item>334</item> <item>335</item> <item>336</item> </oprand_edges> <opcode>partselect</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_103"> <Value> <Obj> <type>0</type> <id>118</id> <name>V</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>59</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>59</second> </item> </second> </item> </inlineStackInfo> <originalName>V</originalName> <rtlName>out_channels_ch3_din</rtlName> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>337</item> <item>338</item> </oprand_edges> <opcode>xor</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_104"> <Value> <Obj> <type>0</type> <id>119</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>60</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>60</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>340</item> <item>341</item> <item>342</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_105"> <Value> <Obj> <type>0</type> <id>120</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>61</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>61</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>343</item> <item>344</item> <item>345</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_106"> <Value> <Obj> <type>0</type> <id>121</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>62</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>62</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>3</count> <item_version>0</item_version> <item>346</item> <item>347</item> <item>348</item> </oprand_edges> <opcode>write</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_107"> <Value> <Obj> <type>0</type> <id>123</id> <name>y</name> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>52</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>52</second> </item> </second> </item> </inlineStackInfo> <originalName>y</originalName> <rtlName>y_fu_377_p2</rtlName> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <oprand_edges> <count>2</count> <item_version>0</item_version> <item>349</item> <item>350</item> </oprand_edges> <opcode>add</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_108"> <Value> <Obj> <type>0</type> <id>124</id> <name/> <fileName>yuv_filter.c</fileName> <fileDirectory>..</fileDirectory> <lineNumber>52</lineNumber> <contextFuncName>rgb2yuv</contextFuncName> <inlineStackInfo> <count>1</count> <item_version>0</item_version> <item> <first>/home/lfvelez/Documentos/ISPR/HLS/labsource/labs/lab2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first> <first>yuv_filter.c</first> <second>rgb2yuv</second> </first> <second>52</second> </item> </second> </item> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>1</count> <item_version>0</item_version> <item>351</item> </oprand_edges> <opcode>br</opcode> <m_Display>0</m_Display> </item> <item class_id_reference="9" object_id="_109"> <Value> <Obj> <type>0</type> <id>126</id> <name/> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>0</bitwidth> </Value> <oprand_edges> <count>0</count> <item_version>0</item_version> </oprand_edges> <opcode>ret</opcode> <m_Display>0</m_Display> </item> </nodes> <consts class_id="15" tracking_level="0" version="0"> <count>23</count> <item_version>0</item_version> <item class_id="16" tracking_level="1" version="0" object_id="_110"> <Value> <Obj> <type>2</type> <id>162</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_111"> <Value> <Obj> <type>2</type> <id>167</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_112"> <Value> <Obj> <type>2</type> <id>179</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <const_type>0</const_type> <content>1</content> </item> <item class_id_reference="16" object_id="_113"> <Value> <Obj> <type>2</type> <id>184</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <const_type>0</const_type> <content>1</content> </item> <item class_id_reference="16" object_id="_114"> <Value> <Obj> <type>2</type> <id>199</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>10</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_115"> <Value> <Obj> <type>2</type> <id>205</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_116"> <Value> <Obj> <type>2</type> <id>214</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>64</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_117"> <Value> <Obj> <type>2</type> <id>230</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>6</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_118"> <Value> <Obj> <type>2</type> <id>236</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>1</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_119"> <Value> <Obj> <type>2</type> <id>244</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>7</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_120"> <Value> <Obj> <type>2</type> <id>248</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <const_type>0</const_type> <content>25</content> </item> <item class_id_reference="16" object_id="_121"> <Value> <Obj> <type>2</type> <id>251</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>10</bitwidth> </Value> <const_type>0</const_type> <content>128</content> </item> <item class_id_reference="16" object_id="_122"> <Value> <Obj> <type>2</type> <id>268</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <const_type>0</const_type> <content>8</content> </item> <item class_id_reference="16" object_id="_123"> <Value> <Obj> <type>2</type> <id>270</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>32</bitwidth> </Value> <const_type>0</const_type> <content>15</content> </item> <item class_id_reference="16" object_id="_124"> <Value> <Obj> <type>2</type> <id>272</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <const_type>0</const_type> <content>16</content> </item> <item class_id_reference="16" object_id="_125"> <Value> <Obj> <type>2</type> <id>275</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <const_type>0</const_type> <content>32730</content> </item> <item class_id_reference="16" object_id="_126"> <Value> <Obj> <type>2</type> <id>278</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <const_type>0</const_type> <content>65462</content> </item> <item class_id_reference="16" object_id="_127"> <Value> <Obj> <type>2</type> <id>288</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>4</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> <item class_id_reference="16" object_id="_128"> <Value> <Obj> <type>2</type> <id>294</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <const_type>0</const_type> <content>128</content> </item> <item class_id_reference="16" object_id="_129"> <Value> <Obj> <type>2</type> <id>307</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>8</bitwidth> </Value> <const_type>0</const_type> <content>128</content> </item> <item class_id_reference="16" object_id="_130"> <Value> <Obj> <type>2</type> <id>309</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>15</bitwidth> </Value> <const_type>0</const_type> <content>122</content> </item> <item class_id_reference="16" object_id="_131"> <Value> <Obj> <type>2</type> <id>312</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>16</bitwidth> </Value> <const_type>0</const_type> <content>65442</content> </item> <item class_id_reference="16" object_id="_132"> <Value> <Obj> <type>2</type> <id>315</id> <name>empty</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <bitwidth>13</bitwidth> </Value> <const_type>0</const_type> <content>0</content> </item> </consts> <blocks class_id="17" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="18" tracking_level="1" version="0" object_id="_133"> <Obj> <type>3</type> <id>39</id> <name>entry</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <node_objs> <count>14</count> <item_version>0</item_version> <item>23</item> <item>24</item> <item>25</item> <item>26</item> <item>28</item> <item>30</item> <item>31</item> <item>32</item> <item>33</item> <item>34</item> <item>35</item> <item>36</item> <item>37</item> <item>38</item> </node_objs> </item> <item class_id_reference="18" object_id="_134"> <Obj> <type>3</type> <id>46</id> <name/> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <node_objs> <count>6</count> <item_version>0</item_version> <item>40</item> <item>41</item> <item>42</item> <item>43</item> <item>44</item> <item>45</item> </node_objs> </item> <item class_id_reference="18" object_id="_135"> <Obj> <type>3</type> <id>125</id> <name>.reset</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <node_objs> <count>72</count> <item_version>0</item_version> <item>47</item> <item>50</item> <item>51</item> <item>52</item> <item>53</item> <item>54</item> <item>55</item> <item>56</item> <item>57</item> <item>61</item> <item>62</item> <item>63</item> <item>64</item> <item>65</item> <item>66</item> <item>67</item> <item>68</item> <item>69</item> <item>70</item> <item>71</item> <item>72</item> <item>73</item> <item>74</item> <item>75</item> <item>76</item> <item>77</item> <item>78</item> <item>79</item> <item>80</item> <item>81</item> <item>82</item> <item>83</item> <item>84</item> <item>85</item> <item>86</item> <item>87</item> <item>88</item> <item>89</item> <item>90</item> <item>91</item> <item>92</item> <item>93</item> <item>94</item> <item>95</item> <item>96</item> <item>97</item> <item>98</item> <item>99</item> <item>100</item> <item>101</item> <item>102</item> <item>103</item> <item>104</item> <item>105</item> <item>106</item> <item>107</item> <item>108</item> <item>109</item> <item>110</item> <item>111</item> <item>112</item> <item>113</item> <item>114</item> <item>115</item> <item>116</item> <item>117</item> <item>118</item> <item>119</item> <item>120</item> <item>121</item> <item>123</item> <item>124</item> </node_objs> </item> <item class_id_reference="18" object_id="_136"> <Obj> <type>3</type> <id>127</id> <name>.exit</name> <fileName/> <fileDirectory/> <lineNumber>0</lineNumber> <contextFuncName/> <inlineStackInfo> <count>0</count> <item_version>0</item_version> </inlineStackInfo> <originalName/> <rtlName/> <coreName/> </Obj> <node_objs> <count>1</count> <item_version>0</item_version> <item>126</item> </node_objs> </item> </blocks> <edges class_id="19" tracking_level="0" version="0"> <count>169</count> <item_version>0</item_version> <item class_id="20" tracking_level="1" version="0" object_id="_137"> <id>130</id> <edge_type>1</edge_type> <source_obj>13</source_obj> <sink_obj>23</sink_obj> </item> <item class_id_reference="20" object_id="_138"> <id>132</id> <edge_type>1</edge_type> <source_obj>12</source_obj> <sink_obj>24</sink_obj> </item> <item class_id_reference="20" object_id="_139"> <id>134</id> <edge_type>1</edge_type> <source_obj>11</source_obj> <sink_obj>25</sink_obj> </item> <item class_id_reference="20" object_id="_140"> <id>137</id> <edge_type>1</edge_type> <source_obj>14</source_obj> <sink_obj>26</sink_obj> </item> <item class_id_reference="20" object_id="_141"> <id>138</id> <edge_type>1</edge_type> <source_obj>25</source_obj> <sink_obj>26</sink_obj> </item> <item class_id_reference="20" object_id="_142"> <id>140</id> <edge_type>1</edge_type> <source_obj>15</source_obj> <sink_obj>28</sink_obj> </item> <item class_id_reference="20" object_id="_143"> <id>141</id> <edge_type>1</edge_type> <source_obj>24</source_obj> <sink_obj>28</sink_obj> </item> <item class_id_reference="20" object_id="_144"> <id>143</id> <edge_type>1</edge_type> <source_obj>16</source_obj> <sink_obj>30</sink_obj> </item> <item class_id_reference="20" object_id="_145"> <id>144</id> <edge_type>1</edge_type> <source_obj>23</source_obj> <sink_obj>30</sink_obj> </item> <item class_id_reference="20" object_id="_146"> <id>147</id> <edge_type>1</edge_type> <source_obj>4</source_obj> <sink_obj>31</sink_obj> </item> <item class_id_reference="20" object_id="_147"> <id>149</id> <edge_type>1</edge_type> <source_obj>5</source_obj> <sink_obj>32</sink_obj> </item> <item class_id_reference="20" object_id="_148"> <id>152</id> <edge_type>1</edge_type> <source_obj>9</source_obj> <sink_obj>33</sink_obj> </item> <item class_id_reference="20" object_id="_149"> <id>153</id> <edge_type>1</edge_type> <source_obj>31</source_obj> <sink_obj>33</sink_obj> </item> <item class_id_reference="20" object_id="_150"> <id>155</id> <edge_type>1</edge_type> <source_obj>10</source_obj> <sink_obj>34</sink_obj> </item> <item class_id_reference="20" object_id="_151"> <id>156</id> <edge_type>1</edge_type> <source_obj>32</source_obj> <sink_obj>34</sink_obj> </item> <item class_id_reference="20" object_id="_152"> <id>157</id> <edge_type>1</edge_type> <source_obj>31</source_obj> <sink_obj>35</sink_obj> </item> <item class_id_reference="20" object_id="_153"> <id>158</id> <edge_type>1</edge_type> <source_obj>32</source_obj> <sink_obj>36</sink_obj> </item> <item class_id_reference="20" object_id="_154"> <id>159</id> <edge_type>1</edge_type> <source_obj>36</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_155"> <id>160</id> <edge_type>1</edge_type> <source_obj>35</source_obj> <sink_obj>37</sink_obj> </item> <item class_id_reference="20" object_id="_156"> <id>161</id> <edge_type>2</edge_type> <source_obj>46</source_obj> <sink_obj>38</sink_obj> </item> <item class_id_reference="20" object_id="_157"> <id>163</id> <edge_type>1</edge_type> <source_obj>162</source_obj> <sink_obj>40</sink_obj> </item> <item class_id_reference="20" object_id="_158"> <id>164</id> <edge_type>2</edge_type> <source_obj>39</source_obj> <sink_obj>40</sink_obj> </item> <item class_id_reference="20" object_id="_159"> <id>165</id> <edge_type>1</edge_type> <source_obj>44</source_obj> <sink_obj>40</sink_obj> </item> <item class_id_reference="20" object_id="_160"> <id>166</id> <edge_type>2</edge_type> <source_obj>125</source_obj> <sink_obj>40</sink_obj> </item> <item class_id_reference="20" object_id="_161"> <id>168</id> <edge_type>1</edge_type> <source_obj>167</source_obj> <sink_obj>41</sink_obj> </item> <item class_id_reference="20" object_id="_162"> <id>169</id> <edge_type>2</edge_type> <source_obj>39</source_obj> <sink_obj>41</sink_obj> </item> <item class_id_reference="20" object_id="_163"> <id>170</id> <edge_type>1</edge_type> <source_obj>52</source_obj> <sink_obj>41</sink_obj> </item> <item class_id_reference="20" object_id="_164"> <id>171</id> <edge_type>2</edge_type> <source_obj>125</source_obj> <sink_obj>41</sink_obj> </item> <item class_id_reference="20" object_id="_165"> <id>172</id> <edge_type>1</edge_type> <source_obj>167</source_obj> <sink_obj>42</sink_obj> </item> <item class_id_reference="20" object_id="_166"> <id>173</id> <edge_type>2</edge_type> <source_obj>39</source_obj> <sink_obj>42</sink_obj> </item> <item class_id_reference="20" object_id="_167"> <id>174</id> <edge_type>1</edge_type> <source_obj>123</source_obj> <sink_obj>42</sink_obj> </item> <item class_id_reference="20" object_id="_168"> <id>175</id> <edge_type>2</edge_type> <source_obj>125</source_obj> <sink_obj>42</sink_obj> </item> <item class_id_reference="20" object_id="_169"> <id>176</id> <edge_type>1</edge_type> <source_obj>40</source_obj> <sink_obj>43</sink_obj> </item> <item class_id_reference="20" object_id="_170"> <id>177</id> <edge_type>1</edge_type> <source_obj>37</source_obj> <sink_obj>43</sink_obj> </item> <item class_id_reference="20" object_id="_171"> <id>178</id> <edge_type>1</edge_type> <source_obj>40</source_obj> <sink_obj>44</sink_obj> </item> <item class_id_reference="20" object_id="_172"> <id>180</id> <edge_type>1</edge_type> <source_obj>179</source_obj> <sink_obj>44</sink_obj> </item> <item class_id_reference="20" object_id="_173"> <id>181</id> <edge_type>1</edge_type> <source_obj>43</source_obj> <sink_obj>45</sink_obj> </item> <item class_id_reference="20" object_id="_174"> <id>182</id> <edge_type>2</edge_type> <source_obj>125</source_obj> <sink_obj>45</sink_obj> </item> <item class_id_reference="20" object_id="_175"> <id>183</id> <edge_type>2</edge_type> <source_obj>127</source_obj> <sink_obj>45</sink_obj> </item> <item class_id_reference="20" object_id="_176"> <id>185</id> <edge_type>1</edge_type> <source_obj>184</source_obj> <sink_obj>47</sink_obj> </item> <item class_id_reference="20" object_id="_177"> <id>186</id> <edge_type>1</edge_type> <source_obj>41</source_obj> <sink_obj>47</sink_obj> </item> <item class_id_reference="20" object_id="_178"> <id>187</id> <edge_type>1</edge_type> <source_obj>42</source_obj> <sink_obj>50</sink_obj> </item> <item class_id_reference="20" object_id="_179"> <id>188</id> <edge_type>1</edge_type> <source_obj>32</source_obj> <sink_obj>50</sink_obj> </item> <item class_id_reference="20" object_id="_180"> <id>189</id> <edge_type>1</edge_type> <source_obj>50</source_obj> <sink_obj>51</sink_obj> </item> <item class_id_reference="20" object_id="_181"> <id>190</id> <edge_type>1</edge_type> <source_obj>167</source_obj> <sink_obj>51</sink_obj> </item> <item class_id_reference="20" object_id="_182"> <id>191</id> <edge_type>1</edge_type> <source_obj>42</source_obj> <sink_obj>51</sink_obj> </item> <item class_id_reference="20" object_id="_183"> <id>192</id> <edge_type>1</edge_type> <source_obj>50</source_obj> <sink_obj>52</sink_obj> </item> <item class_id_reference="20" object_id="_184"> <id>193</id> <edge_type>1</edge_type> <source_obj>47</source_obj> <sink_obj>52</sink_obj> </item> <item class_id_reference="20" object_id="_185"> <id>194</id> <edge_type>1</edge_type> <source_obj>41</source_obj> <sink_obj>52</sink_obj> </item> <item class_id_reference="20" object_id="_186"> <id>195</id> <edge_type>1</edge_type> <source_obj>52</source_obj> <sink_obj>53</sink_obj> </item> <item class_id_reference="20" object_id="_187"> <id>198</id> <edge_type>1</edge_type> <source_obj>53</source_obj> <sink_obj>54</sink_obj> </item> <item class_id_reference="20" object_id="_188"> <id>200</id> <edge_type>1</edge_type> <source_obj>199</source_obj> <sink_obj>54</sink_obj> </item> <item class_id_reference="20" object_id="_189"> <id>201</id> <edge_type>1</edge_type> <source_obj>52</source_obj> <sink_obj>55</sink_obj> </item> <item class_id_reference="20" object_id="_190"> <id>204</id> <edge_type>1</edge_type> <source_obj>55</source_obj> <sink_obj>56</sink_obj> </item> <item class_id_reference="20" object_id="_191"> <id>206</id> <edge_type>1</edge_type> <source_obj>205</source_obj> <sink_obj>56</sink_obj> </item> <item class_id_reference="20" object_id="_192"> <id>207</id> <edge_type>1</edge_type> <source_obj>54</source_obj> <sink_obj>57</sink_obj> </item> <item class_id_reference="20" object_id="_193"> <id>208</id> <edge_type>1</edge_type> <source_obj>56</source_obj> <sink_obj>57</sink_obj> </item> <item class_id_reference="20" object_id="_194"> <id>209</id> <edge_type>1</edge_type> <source_obj>51</source_obj> <sink_obj>61</sink_obj> </item> <item class_id_reference="20" object_id="_195"> <id>210</id> <edge_type>1</edge_type> <source_obj>61</source_obj> <sink_obj>62</sink_obj> </item> <item class_id_reference="20" object_id="_196"> <id>211</id> <edge_type>1</edge_type> <source_obj>57</source_obj> <sink_obj>62</sink_obj> </item> <item class_id_reference="20" object_id="_197"> <id>212</id> <edge_type>1</edge_type> <source_obj>62</source_obj> <sink_obj>63</sink_obj> </item> <item class_id_reference="20" object_id="_198"> <id>213</id> <edge_type>1</edge_type> <source_obj>1</source_obj> <sink_obj>64</sink_obj> </item> <item class_id_reference="20" object_id="_199"> <id>215</id> <edge_type>1</edge_type> <source_obj>214</source_obj> <sink_obj>64</sink_obj> </item> <item class_id_reference="20" object_id="_200"> <id>216</id> <edge_type>1</edge_type> <source_obj>63</source_obj> <sink_obj>64</sink_obj> </item> <item class_id_reference="20" object_id="_201"> <id>217</id> <edge_type>1</edge_type> <source_obj>2</source_obj> <sink_obj>65</sink_obj> </item> <item class_id_reference="20" object_id="_202"> <id>218</id> <edge_type>1</edge_type> <source_obj>214</source_obj> <sink_obj>65</sink_obj> </item> <item class_id_reference="20" object_id="_203"> <id>219</id> <edge_type>1</edge_type> <source_obj>63</source_obj> <sink_obj>65</sink_obj> </item> <item class_id_reference="20" object_id="_204"> <id>220</id> <edge_type>1</edge_type> <source_obj>3</source_obj> <sink_obj>66</sink_obj> </item> <item class_id_reference="20" object_id="_205"> <id>221</id> <edge_type>1</edge_type> <source_obj>214</source_obj> <sink_obj>66</sink_obj> </item> <item class_id_reference="20" object_id="_206"> <id>222</id> <edge_type>1</edge_type> <source_obj>63</source_obj> <sink_obj>66</sink_obj> </item> <item class_id_reference="20" object_id="_207"> <id>223</id> <edge_type>1</edge_type> <source_obj>64</source_obj> <sink_obj>67</sink_obj> </item> <item class_id_reference="20" object_id="_208"> <id>224</id> <edge_type>1</edge_type> <source_obj>65</source_obj> <sink_obj>68</sink_obj> </item> <item class_id_reference="20" object_id="_209"> <id>225</id> <edge_type>1</edge_type> <source_obj>66</source_obj> <sink_obj>69</sink_obj> </item> <item class_id_reference="20" object_id="_210"> <id>226</id> <edge_type>1</edge_type> <source_obj>67</source_obj> <sink_obj>70</sink_obj> </item> <item class_id_reference="20" object_id="_211"> <id>229</id> <edge_type>1</edge_type> <source_obj>67</source_obj> <sink_obj>71</sink_obj> </item> <item class_id_reference="20" object_id="_212"> <id>231</id> <edge_type>1</edge_type> <source_obj>230</source_obj> <sink_obj>71</sink_obj> </item> <item class_id_reference="20" object_id="_213"> <id>232</id> <edge_type>1</edge_type> <source_obj>71</source_obj> <sink_obj>72</sink_obj> </item> <item class_id_reference="20" object_id="_214"> <id>235</id> <edge_type>1</edge_type> <source_obj>67</source_obj> <sink_obj>73</sink_obj> </item> <item class_id_reference="20" object_id="_215"> <id>237</id> <edge_type>1</edge_type> <source_obj>236</source_obj> <sink_obj>73</sink_obj> </item> <item class_id_reference="20" object_id="_216"> <id>238</id> <edge_type>1</edge_type> <source_obj>73</source_obj> <sink_obj>74</sink_obj> </item> <item class_id_reference="20" object_id="_217"> <id>239</id> <edge_type>1</edge_type> <source_obj>68</source_obj> <sink_obj>75</sink_obj> </item> <item class_id_reference="20" object_id="_218"> <id>240</id> <edge_type>1</edge_type> <source_obj>68</source_obj> <sink_obj>76</sink_obj> </item> <item class_id_reference="20" object_id="_219"> <id>243</id> <edge_type>1</edge_type> <source_obj>68</source_obj> <sink_obj>77</sink_obj> </item> <item class_id_reference="20" object_id="_220"> <id>245</id> <edge_type>1</edge_type> <source_obj>244</source_obj> <sink_obj>77</sink_obj> </item> <item class_id_reference="20" object_id="_221"> <id>246</id> <edge_type>1</edge_type> <source_obj>77</source_obj> <sink_obj>78</sink_obj> </item> <item class_id_reference="20" object_id="_222"> <id>247</id> <edge_type>1</edge_type> <source_obj>69</source_obj> <sink_obj>79</sink_obj> </item> <item class_id_reference="20" object_id="_223"> <id>249</id> <edge_type>1</edge_type> <source_obj>248</source_obj> <sink_obj>80</sink_obj> </item> <item class_id_reference="20" object_id="_224"> <id>250</id> <edge_type>1</edge_type> <source_obj>79</source_obj> <sink_obj>80</sink_obj> </item> <item class_id_reference="20" object_id="_225"> <id>252</id> <edge_type>1</edge_type> <source_obj>251</source_obj> <sink_obj>81</sink_obj> </item> <item class_id_reference="20" object_id="_226"> <id>253</id> <edge_type>1</edge_type> <source_obj>74</source_obj> <sink_obj>81</sink_obj> </item> <item class_id_reference="20" object_id="_227"> <id>254</id> <edge_type>1</edge_type> <source_obj>81</source_obj> <sink_obj>82</sink_obj> </item> <item class_id_reference="20" object_id="_228"> <id>255</id> <edge_type>1</edge_type> <source_obj>82</source_obj> <sink_obj>83</sink_obj> </item> <item class_id_reference="20" object_id="_229"> <id>256</id> <edge_type>1</edge_type> <source_obj>72</source_obj> <sink_obj>83</sink_obj> </item> <item class_id_reference="20" object_id="_230"> <id>257</id> <edge_type>1</edge_type> <source_obj>83</source_obj> <sink_obj>84</sink_obj> </item> <item class_id_reference="20" object_id="_231"> <id>258</id> <edge_type>1</edge_type> <source_obj>78</source_obj> <sink_obj>85</sink_obj> </item> <item class_id_reference="20" object_id="_232"> <id>259</id> <edge_type>1</edge_type> <source_obj>84</source_obj> <sink_obj>85</sink_obj> </item> <item class_id_reference="20" object_id="_233"> <id>260</id> <edge_type>1</edge_type> <source_obj>80</source_obj> <sink_obj>86</sink_obj> </item> <item class_id_reference="20" object_id="_234"> <id>261</id> <edge_type>1</edge_type> <source_obj>76</source_obj> <sink_obj>86</sink_obj> </item> <item class_id_reference="20" object_id="_235"> <id>262</id> <edge_type>1</edge_type> <source_obj>86</source_obj> <sink_obj>87</sink_obj> </item> <item class_id_reference="20" object_id="_236"> <id>263</id> <edge_type>1</edge_type> <source_obj>87</source_obj> <sink_obj>88</sink_obj> </item> <item class_id_reference="20" object_id="_237"> <id>264</id> <edge_type>1</edge_type> <source_obj>85</source_obj> <sink_obj>88</sink_obj> </item> <item class_id_reference="20" object_id="_238"> <id>267</id> <edge_type>1</edge_type> <source_obj>88</source_obj> <sink_obj>89</sink_obj> </item> <item class_id_reference="20" object_id="_239"> <id>269</id> <edge_type>1</edge_type> <source_obj>268</source_obj> <sink_obj>89</sink_obj> </item> <item class_id_reference="20" object_id="_240"> <id>271</id> <edge_type>1</edge_type> <source_obj>270</source_obj> <sink_obj>89</sink_obj> </item> <item class_id_reference="20" object_id="_241"> <id>273</id> <edge_type>1</edge_type> <source_obj>272</source_obj> <sink_obj>90</sink_obj> </item> <item class_id_reference="20" object_id="_242"> <id>274</id> <edge_type>1</edge_type> <source_obj>89</source_obj> <sink_obj>90</sink_obj> </item> <item class_id_reference="20" object_id="_243"> <id>276</id> <edge_type>1</edge_type> <source_obj>275</source_obj> <sink_obj>91</sink_obj> </item> <item class_id_reference="20" object_id="_244"> <id>277</id> <edge_type>1</edge_type> <source_obj>70</source_obj> <sink_obj>91</sink_obj> </item> <item class_id_reference="20" object_id="_245"> <id>279</id> <edge_type>1</edge_type> <source_obj>278</source_obj> <sink_obj>92</sink_obj> </item> <item class_id_reference="20" object_id="_246"> <id>280</id> <edge_type>1</edge_type> <source_obj>75</source_obj> <sink_obj>92</sink_obj> </item> <item class_id_reference="20" object_id="_247"> <id>282</id> <edge_type>1</edge_type> <source_obj>69</source_obj> <sink_obj>93</sink_obj> </item> <item class_id_reference="20" object_id="_248"> <id>283</id> <edge_type>1</edge_type> <source_obj>244</source_obj> <sink_obj>93</sink_obj> </item> <item class_id_reference="20" object_id="_249"> <id>284</id> <edge_type>1</edge_type> <source_obj>93</source_obj> <sink_obj>94</sink_obj> </item> <item class_id_reference="20" object_id="_250"> <id>287</id> <edge_type>1</edge_type> <source_obj>69</source_obj> <sink_obj>95</sink_obj> </item> <item class_id_reference="20" object_id="_251"> <id>289</id> <edge_type>1</edge_type> <source_obj>288</source_obj> <sink_obj>95</sink_obj> </item> <item class_id_reference="20" object_id="_252"> <id>290</id> <edge_type>1</edge_type> <source_obj>95</source_obj> <sink_obj>96</sink_obj> </item> <item class_id_reference="20" object_id="_253"> <id>291</id> <edge_type>1</edge_type> <source_obj>95</source_obj> <sink_obj>97</sink_obj> </item> <item class_id_reference="20" object_id="_254"> <id>292</id> <edge_type>1</edge_type> <source_obj>94</source_obj> <sink_obj>98</sink_obj> </item> <item class_id_reference="20" object_id="_255"> <id>293</id> <edge_type>1</edge_type> <source_obj>97</source_obj> <sink_obj>98</sink_obj> </item> <item class_id_reference="20" object_id="_256"> <id>295</id> <edge_type>1</edge_type> <source_obj>294</source_obj> <sink_obj>99</sink_obj> </item> <item class_id_reference="20" object_id="_257"> <id>296</id> <edge_type>1</edge_type> <source_obj>91</source_obj> <sink_obj>99</sink_obj> </item> <item class_id_reference="20" object_id="_258"> <id>297</id> <edge_type>1</edge_type> <source_obj>99</source_obj> <sink_obj>100</sink_obj> </item> <item class_id_reference="20" object_id="_259"> <id>298</id> <edge_type>1</edge_type> <source_obj>98</source_obj> <sink_obj>101</sink_obj> </item> <item class_id_reference="20" object_id="_260"> <id>299</id> <edge_type>1</edge_type> <source_obj>100</source_obj> <sink_obj>101</sink_obj> </item> <item class_id_reference="20" object_id="_261"> <id>300</id> <edge_type>1</edge_type> <source_obj>101</source_obj> <sink_obj>102</sink_obj> </item> <item class_id_reference="20" object_id="_262"> <id>301</id> <edge_type>1</edge_type> <source_obj>92</source_obj> <sink_obj>102</sink_obj> </item> <item class_id_reference="20" object_id="_263"> <id>303</id> <edge_type>1</edge_type> <source_obj>102</source_obj> <sink_obj>103</sink_obj> </item> <item class_id_reference="20" object_id="_264"> <id>304</id> <edge_type>1</edge_type> <source_obj>268</source_obj> <sink_obj>103</sink_obj> </item> <item class_id_reference="20" object_id="_265"> <id>305</id> <edge_type>1</edge_type> <source_obj>270</source_obj> <sink_obj>103</sink_obj> </item> <item class_id_reference="20" object_id="_266"> <id>306</id> <edge_type>1</edge_type> <source_obj>103</source_obj> <sink_obj>104</sink_obj> </item> <item class_id_reference="20" object_id="_267"> <id>308</id> <edge_type>1</edge_type> <source_obj>307</source_obj> <sink_obj>104</sink_obj> </item> <item class_id_reference="20" object_id="_268"> <id>310</id> <edge_type>1</edge_type> <source_obj>309</source_obj> <sink_obj>105</sink_obj> </item> <item class_id_reference="20" object_id="_269"> <id>311</id> <edge_type>1</edge_type> <source_obj>70</source_obj> <sink_obj>105</sink_obj> </item> <item class_id_reference="20" object_id="_270"> <id>313</id> <edge_type>1</edge_type> <source_obj>312</source_obj> <sink_obj>106</sink_obj> </item> <item class_id_reference="20" object_id="_271"> <id>314</id> <edge_type>1</edge_type> <source_obj>75</source_obj> <sink_obj>106</sink_obj> </item> <item class_id_reference="20" object_id="_272"> <id>316</id> <edge_type>1</edge_type> <source_obj>315</source_obj> <sink_obj>107</sink_obj> </item> <item class_id_reference="20" object_id="_273"> <id>317</id> <edge_type>1</edge_type> <source_obj>96</source_obj> <sink_obj>107</sink_obj> </item> <item class_id_reference="20" object_id="_274"> <id>318</id> <edge_type>1</edge_type> <source_obj>107</source_obj> <sink_obj>108</sink_obj> </item> <item class_id_reference="20" object_id="_275"> <id>320</id> <edge_type>1</edge_type> <source_obj>69</source_obj> <sink_obj>109</sink_obj> </item> <item class_id_reference="20" object_id="_276"> <id>321</id> <edge_type>1</edge_type> <source_obj>236</source_obj> <sink_obj>109</sink_obj> </item> <item class_id_reference="20" object_id="_277"> <id>322</id> <edge_type>1</edge_type> <source_obj>109</source_obj> <sink_obj>110</sink_obj> </item> <item class_id_reference="20" object_id="_278"> <id>323</id> <edge_type>1</edge_type> <source_obj>108</source_obj> <sink_obj>111</sink_obj> </item> <item class_id_reference="20" object_id="_279"> <id>324</id> <edge_type>1</edge_type> <source_obj>110</source_obj> <sink_obj>111</sink_obj> </item> <item class_id_reference="20" object_id="_280"> <id>325</id> <edge_type>1</edge_type> <source_obj>111</source_obj> <sink_obj>112</sink_obj> </item> <item class_id_reference="20" object_id="_281"> <id>326</id> <edge_type>1</edge_type> <source_obj>294</source_obj> <sink_obj>113</sink_obj> </item> <item class_id_reference="20" object_id="_282"> <id>327</id> <edge_type>1</edge_type> <source_obj>105</source_obj> <sink_obj>113</sink_obj> </item> <item class_id_reference="20" object_id="_283"> <id>328</id> <edge_type>1</edge_type> <source_obj>113</source_obj> <sink_obj>114</sink_obj> </item> <item class_id_reference="20" object_id="_284"> <id>329</id> <edge_type>1</edge_type> <source_obj>114</source_obj> <sink_obj>115</sink_obj> </item> <item class_id_reference="20" object_id="_285"> <id>330</id> <edge_type>1</edge_type> <source_obj>112</source_obj> <sink_obj>115</sink_obj> </item> <item class_id_reference="20" object_id="_286"> <id>331</id> <edge_type>1</edge_type> <source_obj>115</source_obj> <sink_obj>116</sink_obj> </item> <item class_id_reference="20" object_id="_287"> <id>332</id> <edge_type>1</edge_type> <source_obj>106</source_obj> <sink_obj>116</sink_obj> </item> <item class_id_reference="20" object_id="_288"> <id>334</id> <edge_type>1</edge_type> <source_obj>116</source_obj> <sink_obj>117</sink_obj> </item> <item class_id_reference="20" object_id="_289"> <id>335</id> <edge_type>1</edge_type> <source_obj>268</source_obj> <sink_obj>117</sink_obj> </item> <item class_id_reference="20" object_id="_290"> <id>336</id> <edge_type>1</edge_type> <source_obj>270</source_obj> <sink_obj>117</sink_obj> </item> <item class_id_reference="20" object_id="_291"> <id>337</id> <edge_type>1</edge_type> <source_obj>117</source_obj> <sink_obj>118</sink_obj> </item> <item class_id_reference="20" object_id="_292"> <id>338</id> <edge_type>1</edge_type> <source_obj>307</source_obj> <sink_obj>118</sink_obj> </item> <item class_id_reference="20" object_id="_293"> <id>341</id> <edge_type>1</edge_type> <source_obj>6</source_obj> <sink_obj>119</sink_obj> </item> <item class_id_reference="20" object_id="_294"> <id>342</id> <edge_type>1</edge_type> <source_obj>90</source_obj> <sink_obj>119</sink_obj> </item> <item class_id_reference="20" object_id="_295"> <id>344</id> <edge_type>1</edge_type> <source_obj>7</source_obj> <sink_obj>120</sink_obj> </item> <item class_id_reference="20" object_id="_296"> <id>345</id> <edge_type>1</edge_type> <source_obj>104</source_obj> <sink_obj>120</sink_obj> </item> <item class_id_reference="20" object_id="_297"> <id>347</id> <edge_type>1</edge_type> <source_obj>8</source_obj> <sink_obj>121</sink_obj> </item> <item class_id_reference="20" object_id="_298"> <id>348</id> <edge_type>1</edge_type> <source_obj>118</source_obj> <sink_obj>121</sink_obj> </item> <item class_id_reference="20" object_id="_299"> <id>349</id> <edge_type>1</edge_type> <source_obj>184</source_obj> <sink_obj>123</sink_obj> </item> <item class_id_reference="20" object_id="_300"> <id>350</id> <edge_type>1</edge_type> <source_obj>51</source_obj> <sink_obj>123</sink_obj> </item> <item class_id_reference="20" object_id="_301"> <id>351</id> <edge_type>2</edge_type> <source_obj>46</source_obj> <sink_obj>124</sink_obj> </item> <item class_id_reference="20" object_id="_302"> <id>523</id> <edge_type>2</edge_type> <source_obj>39</source_obj> <sink_obj>46</sink_obj> </item> <item class_id_reference="20" object_id="_303"> <id>524</id> <edge_type>2</edge_type> <source_obj>46</source_obj> <sink_obj>127</sink_obj> </item> <item class_id_reference="20" object_id="_304"> <id>525</id> <edge_type>2</edge_type> <source_obj>46</source_obj> <sink_obj>125</sink_obj> </item> <item class_id_reference="20" object_id="_305"> <id>526</id> <edge_type>2</edge_type> <source_obj>125</source_obj> <sink_obj>46</sink_obj> </item> </edges> </cdfg> <cdfg_regions class_id="21" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="22" tracking_level="1" version="0" object_id="_306"> <mId>1</mId> <mTag>rgb2yuv11</mTag> <mType>0</mType> <sub_regions> <count>3</count> <item_version>0</item_version> <item>2</item> <item>3</item> <item>4</item> </sub_regions> <basic_blocks> <count>0</count> <item_version>0</item_version> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>2457609</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"/> </item> <item class_id_reference="22" object_id="_307"> <mId>2</mId> <mTag>Entry</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>39</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>0</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"/> </item> <item class_id_reference="22" object_id="_308"> <mId>3</mId> <mTag>RGB2YUV_LOOP_X_RGB2YUV_LOOP_Y</mTag> <mType>1</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>2</count> <item_version>0</item_version> <item>46</item> <item>125</item> </basic_blocks> <mII>1</mII> <mDepth>9</mDepth> <mMinTripCount>40000</mMinTripCount> <mMaxTripCount>2457600</mMaxTripCount> <mMinLatency>2457607</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"/> </item> <item class_id_reference="22" object_id="_309"> <mId>4</mId> <mTag>Return</mTag> <mType>0</mType> <sub_regions> <count>0</count> <item_version>0</item_version> </sub_regions> <basic_blocks> <count>1</count> <item_version>0</item_version> <item>127</item> </basic_blocks> <mII>-1</mII> <mDepth>-1</mDepth> <mMinTripCount>-1</mMinTripCount> <mMaxTripCount>-1</mMaxTripCount> <mMinLatency>0</mMinLatency> <mMaxLatency>-1</mMaxLatency> <mIsDfPipe>0</mIsDfPipe> <mDfPipe class_id="-1"/> </item> </cdfg_regions> <fsm class_id="24" tracking_level="1" version="0" object_id="_310"> <states class_id="25" tracking_level="0" version="0"> <count>11</count> <item_version>0</item_version> <item class_id="26" tracking_level="1" version="0" object_id="_311"> <id>1</id> <operations class_id="27" tracking_level="0" version="0"> <count>22</count> <item_version>0</item_version> <item class_id="28" tracking_level="1" version="0" object_id="_312"> <id>17</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_313"> <id>18</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_314"> <id>19</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_315"> <id>20</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_316"> <id>21</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_317"> <id>22</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_318"> <id>23</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_319"> <id>24</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_320"> <id>25</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_321"> <id>26</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_322"> <id>27</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_323"> <id>28</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_324"> <id>29</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_325"> <id>30</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_326"> <id>31</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_327"> <id>32</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_328"> <id>33</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_329"> <id>34</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_330"> <id>35</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_331"> <id>36</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_332"> <id>37</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_333"> <id>38</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_334"> <id>2</id> <operations> <count>12</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_335"> <id>40</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_336"> <id>41</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_337"> <id>42</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_338"> <id>43</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_339"> <id>44</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_340"> <id>45</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_341"> <id>47</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_342"> <id>50</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_343"> <id>51</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_344"> <id>52</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_345"> <id>53</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_346"> <id>55</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_347"> <id>3</id> <operations> <count>6</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_348"> <id>54</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_349"> <id>56</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_350"> <id>57</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_351"> <id>61</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_352"> <id>62</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_353"> <id>123</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_354"> <id>4</id> <operations> <count>7</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_355"> <id>63</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_356"> <id>64</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_357"> <id>65</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_358"> <id>66</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_359"> <id>67</id> <stage>4</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_360"> <id>68</id> <stage>4</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_361"> <id>69</id> <stage>4</stage> <latency>4</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_362"> <id>5</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_363"> <id>67</id> <stage>3</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_364"> <id>68</id> <stage>3</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_365"> <id>69</id> <stage>3</stage> <latency>4</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_366"> <id>6</id> <operations> <count>3</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_367"> <id>67</id> <stage>2</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_368"> <id>68</id> <stage>2</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_369"> <id>69</id> <stage>2</stage> <latency>4</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_370"> <id>7</id> <operations> <count>6</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_371"> <id>67</id> <stage>1</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_372"> <id>68</id> <stage>1</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_373"> <id>69</id> <stage>1</stage> <latency>4</latency> </item> <item class_id_reference="28" object_id="_374"> <id>73</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_375"> <id>74</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_376"> <id>81</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_377"> <id>8</id> <operations> <count>33</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_378"> <id>70</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_379"> <id>71</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_380"> <id>72</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_381"> <id>76</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_382"> <id>77</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_383"> <id>78</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_384"> <id>79</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_385"> <id>80</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_386"> <id>82</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_387"> <id>83</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_388"> <id>84</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_389"> <id>85</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_390"> <id>86</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_391"> <id>87</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_392"> <id>88</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_393"> <id>89</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_394"> <id>91</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_395"> <id>93</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_396"> <id>94</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_397"> <id>95</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_398"> <id>96</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_399"> <id>97</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_400"> <id>98</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_401"> <id>99</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_402"> <id>100</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_403"> <id>101</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_404"> <id>105</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_405"> <id>107</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_406"> <id>108</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_407"> <id>109</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_408"> <id>110</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_409"> <id>111</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_410"> <id>113</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_411"> <id>9</id> <operations> <count>10</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_412"> <id>75</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_413"> <id>92</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_414"> <id>102</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_415"> <id>103</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_416"> <id>106</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_417"> <id>112</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_418"> <id>114</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_419"> <id>115</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_420"> <id>116</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_421"> <id>117</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_422"> <id>10</id> <operations> <count>13</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_423"> <id>48</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_424"> <id>49</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_425"> <id>58</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_426"> <id>59</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_427"> <id>60</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_428"> <id>90</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_429"> <id>104</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_430"> <id>118</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_431"> <id>119</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_432"> <id>120</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_433"> <id>121</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_434"> <id>122</id> <stage>1</stage> <latency>1</latency> </item> <item class_id_reference="28" object_id="_435"> <id>124</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> <item class_id_reference="26" object_id="_436"> <id>11</id> <operations> <count>1</count> <item_version>0</item_version> <item class_id_reference="28" object_id="_437"> <id>126</id> <stage>1</stage> <latency>1</latency> </item> </operations> </item> </states> <transitions class_id="29" tracking_level="0" version="0"> <count>11</count> <item_version>0</item_version> <item class_id="30" tracking_level="1" version="0" object_id="_438"> <inState>1</inState> <outState>2</outState> <condition class_id="31" tracking_level="0" version="0"> <id>23</id> <sop class_id="32" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="33" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_439"> <inState>3</inState> <outState>4</outState> <condition> <id>38</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_440"> <inState>4</inState> <outState>5</outState> <condition> <id>39</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_441"> <inState>5</inState> <outState>6</outState> <condition> <id>40</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_442"> <inState>6</inState> <outState>7</outState> <condition> <id>41</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_443"> <inState>7</inState> <outState>8</outState> <condition> <id>42</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_444"> <inState>8</inState> <outState>9</outState> <condition> <id>43</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_445"> <inState>9</inState> <outState>10</outState> <condition> <id>44</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_446"> <inState>10</inState> <outState>2</outState> <condition> <id>45</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>0</count> <item_version>0</item_version> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_447"> <inState>2</inState> <outState>11</outState> <condition> <id>37</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>1</count> <item_version>0</item_version> <item class_id="34" tracking_level="0" version="0"> <first class_id="35" tracking_level="0" version="0"> <first>43</first> <second>0</second> </first> <second>0</second> </item> </item> </sop> </condition> </item> <item class_id_reference="30" object_id="_448"> <inState>2</inState> <outState>3</outState> <condition> <id>46</id> <sop> <count>1</count> <item_version>0</item_version> <item> <count>1</count> <item_version>0</item_version> <item> <first> <first>43</first> <second>0</second> </first> <second>1</second> </item> </item> </sop> </condition> </item> </transitions> </fsm> <res class_id="36" tracking_level="1" version="0" object_id="_449"> <dp_component_resource class_id="37" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_component_resource> <dp_expression_resource> <count>27</count> <item_version>0</item_version> <item class_id="38" tracking_level="0" version="0"> <first>ap_block_pp0_stage0_flag00001001 ( and ) </first> <second class_id="39" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="40" tracking_level="0" version="0"> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>1</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>2</second> </item> </second> </item> <item> <first>ap_block_state1 ( or ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>1</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>2</second> </item> </second> </item> <item> <first>ap_block_state10_pp0_stage0_iter8 ( or ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>1</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>2</second> </item> </second> </item> <item> <first>ap_enable_pp0 ( xor ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>2</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>2</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter1 ( xor ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>2</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>2</second> </item> </second> </item> <item> <first>exitcond_flatten_fu_302_p2 ( icmp ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>32</second> </item> <item> <first>(1P1)</first> <second>32</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>16</second> </item> </second> </item> <item> <first>exitcond_i_i_fu_319_p2 ( icmp ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>16</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>8</second> </item> </second> </item> <item> <first>grp_fu_634_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>16</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>indvar_flatten_next_fu_307_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>32</second> </item> <item> <first>(1P1)</first> <second>1</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>39</second> </item> </second> </item> <item> <first>out_channels_ch1_din ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>5</second> </item> <item> <first>(1P1)</first> <second>8</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>15</second> </item> </second> </item> <item> <first>out_channels_ch2_din ( xor ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>8</second> </item> <item> <first>(1P1)</first> <second>9</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>out_channels_ch3_din ( xor ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>8</second> </item> <item> <first>(1P1)</first> <second>9</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>p_neg_i_i_fu_516_p2 ( - ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>13</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>20</second> </item> </second> </item> <item> <first>start_write ( and ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>1</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>2</second> </item> </second> </item> <item> <first>tmp1_fu_450_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>16</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>tmp3_fu_510_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>16</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>tmp_24_fu_371_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>23</second> </item> <item> <first>(1P1)</first> <second>23</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>tmp_46_i_i_fu_440_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>15</second> </item> <item> <first>(1P1)</first> <second>15</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>22</second> </item> </second> </item> <item> <first>tmp_48_i_i_fu_459_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>16</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>tmp_53_i_i_fu_501_p2 ( - ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>16</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>tmp_61_i_i_fu_537_p2 ( - ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>14</second> </item> <item> <first>(1P1)</first> <second>14</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>21</second> </item> </second> </item> <item> <first>tmp_fu_400_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>8</second> </item> <item> <first>(1P1)</first> <second>10</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>17</second> </item> </second> </item> <item> <first>tmp_i_i_mid2_v_fu_332_p3 ( select ) </first> <second> <count>5</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>(2P2)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>16</second> </item> </second> </item> <item> <first>tmp_s_fu_362_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>23</second> </item> <item> <first>(1P1)</first> <second>23</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>x_fu_313_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>y_fu_377_p2 ( + ) </first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>23</second> </item> </second> </item> <item> <first>y_i_i_mid2_fu_324_p3 ( select ) </first> <second> <count>5</count> <item_version>0</item_version> <item> <first>(0P0)</first> <second>1</second> </item> <item> <first>(1P1)</first> <second>1</second> </item> <item> <first>(2P2)</first> <second>16</second> </item> <item> <first>FF</first> <second>0</second> </item> <item> <first>LUT</first> <second>16</second> </item> </second> </item> </dp_expression_resource> <dp_fifo_resource> <count>0</count> <item_version>0</item_version> </dp_fifo_resource> <dp_memory_resource> <count>0</count> <item_version>0</item_version> </dp_memory_resource> <dp_multiplexer_resource> <count>18</count> <item_version>0</item_version> <item> <first>U_scale_out_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>V_scale_out_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>Y_scale_out_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>ap_NS_fsm</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>4</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>4</second> </item> <item> <first>LUT</first> <second>21</second> </item> </second> </item> <item> <first>ap_done</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter1</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter8</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>indvar_flatten_reg_261</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>32</second> </item> <item> <first>(2Count)</first> <second>64</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>out_channels_ch1_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>out_channels_ch2_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>out_channels_ch3_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>out_height_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>out_width_blk_n</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>real_start</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>1</second> </item> <item> <first>(2Count)</first> <second>2</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>x_i_i_phi_fu_276_p4</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>16</second> </item> <item> <first>(2Count)</first> <second>32</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>x_i_i_reg_272</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>16</second> </item> <item> <first>(2Count)</first> <second>32</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>y_i_i_phi_fu_287_p4</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>16</second> </item> <item> <first>(2Count)</first> <second>32</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> <item> <first>y_i_i_reg_283</first> <second> <count>4</count> <item_version>0</item_version> <item> <first>(0Size)</first> <second>2</second> </item> <item> <first>(1Bits)</first> <second>16</second> </item> <item> <first>(2Count)</first> <second>32</second> </item> <item> <first>LUT</first> <second>9</second> </item> </second> </item> </dp_multiplexer_resource> <dp_register_resource> <count>36</count> <item_version>0</item_version> <item> <first>B_reg_721</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>G_reg_714</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>R_reg_708</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>ap_CS_fsm</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>3</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>3</second> </item> </second> </item> <item> <first>ap_done_reg</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter0</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter1</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter2</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter3</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter4</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter5</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter6</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter7</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_enable_reg_pp0_iter8</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>ap_reg_pp0_iter6_G_reg_714</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>ap_reg_pp0_iter7_tmp_50_i_i_reg_734</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>bound_reg_648</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>32</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>32</second> </item> </second> </item> <item> <first>exitcond_flatten_reg_653</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>indvar_flatten_reg_261</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>32</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>32</second> </item> </second> </item> <item> <first>real_start_status_reg</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>start_control_reg</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>start_once_reg</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>1</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>1</second> </item> </second> </item> <item> <first>tmp3_reg_739</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>16</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>16</second> </item> </second> </item> <item> <first>tmp_22_reg_673</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>13</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>13</second> </item> </second> </item> <item> <first>tmp_23_reg_678</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>15</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>15</second> </item> </second> </item> <item> <first>tmp_24_reg_683</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>23</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>23</second> </item> </second> </item> <item> <first>tmp_50_i_i_reg_734</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>tmp_58_i_i_reg_754</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>tmp_61_i_i_reg_744</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>14</second> </item> <item> <first>(Consts)</first> <second>1</second> </item> <item> <first>FF</first> <second>13</second> </item> </second> </item> <item> <first>tmp_62_i_i_reg_749</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>15</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>15</second> </item> </second> </item> <item> <first>tmp_66_i_i_reg_759</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>8</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>8</second> </item> </second> </item> <item> <first>tmp_i_i_mid2_v_reg_668</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>16</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>16</second> </item> </second> </item> <item> <first>tmp_reg_729</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>10</second> </item> <item> <first>(Consts)</first> <second>1</second> </item> <item> <first>FF</first> <second>9</second> </item> </second> </item> <item> <first>x_i_i_reg_272</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>16</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>16</second> </item> </second> </item> <item> <first>y_i_i_mid2_reg_662</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>16</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>16</second> </item> </second> </item> <item> <first>y_i_i_reg_283</first> <second> <count>3</count> <item_version>0</item_version> <item> <first>(Bits)</first> <second>16</second> </item> <item> <first>(Consts)</first> <second>0</second> </item> <item> <first>FF</first> <second>16</second> </item> </second> </item> </dp_register_resource> <dp_component_map class_id="41" tracking_level="0" version="0"> <count>0</count> <item_version>0</item_version> </dp_component_map> <dp_expression_map> <count>21</count> <item_version>0</item_version> <item class_id="42" tracking_level="0" version="0"> <first>exitcond_flatten_fu_302_p2 ( icmp ) </first> <second> <count>1</count> <item_version>0</item_version> <item>43</item> </second> </item> <item> <first>exitcond_i_i_fu_319_p2 ( icmp ) </first> <second> <count>1</count> <item_version>0</item_version> <item>50</item> </second> </item> <item> <first>grp_fu_634_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>115</item> </second> </item> <item> <first>indvar_flatten_next_fu_307_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> <item> <first>out_channels_ch1_din ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>90</item> </second> </item> <item> <first>out_channels_ch2_din ( xor ) </first> <second> <count>1</count> <item_version>0</item_version> <item>104</item> </second> </item> <item> <first>out_channels_ch3_din ( xor ) </first> <second> <count>1</count> <item_version>0</item_version> <item>118</item> </second> </item> <item> <first>p_neg_i_i_fu_516_p2 ( - ) </first> <second> <count>1</count> <item_version>0</item_version> <item>107</item> </second> </item> <item> <first>tmp1_fu_450_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>85</item> </second> </item> <item> <first>tmp3_fu_510_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>101</item> </second> </item> <item> <first>tmp_24_fu_371_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>62</item> </second> </item> <item> <first>tmp_46_i_i_fu_440_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>83</item> </second> </item> <item> <first>tmp_48_i_i_fu_459_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>88</item> </second> </item> <item> <first>tmp_53_i_i_fu_501_p2 ( - ) </first> <second> <count>1</count> <item_version>0</item_version> <item>98</item> </second> </item> <item> <first>tmp_61_i_i_fu_537_p2 ( - ) </first> <second> <count>1</count> <item_version>0</item_version> <item>111</item> </second> </item> <item> <first>tmp_fu_400_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>81</item> </second> </item> <item> <first>tmp_i_i_mid2_v_fu_332_p3 ( select ) </first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> <item> <first>tmp_s_fu_362_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>57</item> </second> </item> <item> <first>x_fu_313_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>47</item> </second> </item> <item> <first>y_fu_377_p2 ( + ) </first> <second> <count>1</count> <item_version>0</item_version> <item>123</item> </second> </item> <item> <first>y_i_i_mid2_fu_324_p3 ( select ) </first> <second> <count>1</count> <item_version>0</item_version> <item>51</item> </second> </item> </dp_expression_map> <dp_fifo_map> <count>0</count> <item_version>0</item_version> </dp_fifo_map> <dp_memory_map> <count>0</count> <item_version>0</item_version> </dp_memory_map> </res> <node_label_latency class_id="43" tracking_level="0" version="0"> <count>93</count> <item_version>0</item_version> <item class_id="44" tracking_level="0" version="0"> <first>23</first> <second class_id="45" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>24</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>25</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>26</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>28</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>30</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>31</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>32</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>33</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>34</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>35</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>36</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>37</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>38</first> <second> <first>0</first> <second>0</second> </second> </item> <item> <first>40</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>41</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>42</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>43</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>44</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>45</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>47</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>50</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>51</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>52</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>53</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>54</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>55</first> <second> <first>1</first> <second>0</second> </second> </item> <item> <first>56</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>57</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>61</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>62</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>63</first> <second> <first>3</first> <second>0</second> </second> </item> <item> <first>64</first> <second> <first>3</first> <second>0</second> </second> </item> <item> <first>65</first> <second> <first>3</first> <second>0</second> </second> </item> <item> <first>66</first> <second> <first>3</first> <second>0</second> </second> </item> <item> <first>67</first> <second> <first>3</first> <second>3</second> </second> </item> <item> <first>68</first> <second> <first>3</first> <second>3</second> </second> </item> <item> <first>69</first> <second> <first>3</first> <second>3</second> </second> </item> <item> <first>70</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>71</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>72</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>73</first> <second> <first>6</first> <second>0</second> </second> </item> <item> <first>74</first> <second> <first>6</first> <second>0</second> </second> </item> <item> <first>75</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>76</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>77</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>78</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>79</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>80</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>81</first> <second> <first>6</first> <second>0</second> </second> </item> <item> <first>82</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>83</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>84</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>85</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>86</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>87</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>88</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>89</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>90</first> <second> <first>9</first> <second>0</second> </second> </item> <item> <first>91</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>92</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>93</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>94</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>95</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>96</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>97</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>98</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>99</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>100</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>101</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>102</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>103</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>104</first> <second> <first>9</first> <second>0</second> </second> </item> <item> <first>105</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>106</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>107</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>108</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>109</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>110</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>111</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>112</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>113</first> <second> <first>7</first> <second>0</second> </second> </item> <item> <first>114</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>115</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>116</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>117</first> <second> <first>8</first> <second>0</second> </second> </item> <item> <first>118</first> <second> <first>9</first> <second>0</second> </second> </item> <item> <first>119</first> <second> <first>9</first> <second>0</second> </second> </item> <item> <first>120</first> <second> <first>9</first> <second>0</second> </second> </item> <item> <first>121</first> <second> <first>9</first> <second>0</second> </second> </item> <item> <first>123</first> <second> <first>2</first> <second>0</second> </second> </item> <item> <first>124</first> <second> <first>9</first> <second>0</second> </second> </item> <item> <first>126</first> <second> <first>2</first> <second>0</second> </second> </item> </node_label_latency> <bblk_ent_exit class_id="46" tracking_level="0" version="0"> <count>4</count> <item_version>0</item_version> <item class_id="47" tracking_level="0" version="0"> <first>39</first> <second class_id="48" tracking_level="0" version="0"> <first>0</first> <second>0</second> </second> </item> <item> <first>46</first> <second> <first>1</first> <second>1</second> </second> </item> <item> <first>125</first> <second> <first>1</first> <second>9</second> </second> </item> <item> <first>127</first> <second> <first>2</first> <second>2</second> </second> </item> </bblk_ent_exit> <regions class_id="49" tracking_level="0" version="0"> <count>1</count> <item_version>0</item_version> <item class_id="50" tracking_level="1" version="0" object_id="_450"> <region_name>RGB2YUV_LOOP_X_RGB2YUV_LOOP_Y</region_name> <basic_blocks> <count>2</count> <item_version>0</item_version> <item>46</item> <item>125</item> </basic_blocks> <nodes> <count>0</count> <item_version>0</item_version> </nodes> <anchor_node>-1</anchor_node> <region_type>8</region_type> <interval>1</interval> <pipe_depth>9</pipe_depth> </item> </regions> <dp_fu_nodes class_id="51" tracking_level="0" version="0"> <count>84</count> <item_version>0</item_version> <item class_id="52" tracking_level="0" version="0"> <first>134</first> <second> <count>1</count> <item_version>0</item_version> <item>23</item> </second> </item> <item> <first>140</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> <item> <first>146</first> <second> <count>1</count> <item_version>0</item_version> <item>25</item> </second> </item> <item> <first>152</first> <second> <count>1</count> <item_version>0</item_version> <item>26</item> </second> </item> <item> <first>160</first> <second> <count>1</count> <item_version>0</item_version> <item>28</item> </second> </item> <item> <first>168</first> <second> <count>1</count> <item_version>0</item_version> <item>30</item> </second> </item> <item> <first>176</first> <second> <count>1</count> <item_version>0</item_version> <item>31</item> </second> </item> <item> <first>182</first> <second> <count>1</count> <item_version>0</item_version> <item>32</item> </second> </item> <item> <first>188</first> <second> <count>1</count> <item_version>0</item_version> <item>33</item> </second> </item> <item> <first>196</first> <second> <count>1</count> <item_version>0</item_version> <item>34</item> </second> </item> <item> <first>204</first> <second> <count>1</count> <item_version>0</item_version> <item>119</item> </second> </item> <item> <first>211</first> <second> <count>1</count> <item_version>0</item_version> <item>120</item> </second> </item> <item> <first>218</first> <second> <count>1</count> <item_version>0</item_version> <item>121</item> </second> </item> <item> <first>225</first> <second> <count>1</count> <item_version>0</item_version> <item>64</item> </second> </item> <item> <first>232</first> <second> <count>1</count> <item_version>0</item_version> <item>65</item> </second> </item> <item> <first>239</first> <second> <count>1</count> <item_version>0</item_version> <item>66</item> </second> </item> <item> <first>246</first> <second> <count>4</count> <item_version>0</item_version> <item>67</item> <item>67</item> <item>67</item> <item>67</item> </second> </item> <item> <first>251</first> <second> <count>4</count> <item_version>0</item_version> <item>68</item> <item>68</item> <item>68</item> <item>68</item> </second> </item> <item> <first>256</first> <second> <count>4</count> <item_version>0</item_version> <item>69</item> <item>69</item> <item>69</item> <item>69</item> </second> </item> <item> <first>265</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first>276</first> <second> <count>1</count> <item_version>0</item_version> <item>41</item> </second> </item> <item> <first>287</first> <second> <count>1</count> <item_version>0</item_version> <item>42</item> </second> </item> <item> <first>294</first> <second> <count>1</count> <item_version>0</item_version> <item>35</item> </second> </item> <item> <first>298</first> <second> <count>1</count> <item_version>0</item_version> <item>36</item> </second> </item> <item> <first>302</first> <second> <count>1</count> <item_version>0</item_version> <item>43</item> </second> </item> <item> <first>307</first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> <item> <first>313</first> <second> <count>1</count> <item_version>0</item_version> <item>47</item> </second> </item> <item> <first>319</first> <second> <count>1</count> <item_version>0</item_version> <item>50</item> </second> </item> <item> <first>324</first> <second> <count>1</count> <item_version>0</item_version> <item>51</item> </second> </item> <item> <first>332</first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> <item> <first>340</first> <second> <count>1</count> <item_version>0</item_version> <item>53</item> </second> </item> <item> <first>344</first> <second> <count>1</count> <item_version>0</item_version> <item>55</item> </second> </item> <item> <first>348</first> <second> <count>1</count> <item_version>0</item_version> <item>54</item> </second> </item> <item> <first>355</first> <second> <count>1</count> <item_version>0</item_version> <item>56</item> </second> </item> <item> <first>362</first> <second> <count>1</count> <item_version>0</item_version> <item>57</item> </second> </item> <item> <first>368</first> <second> <count>1</count> <item_version>0</item_version> <item>61</item> </second> </item> <item> <first>371</first> <second> <count>1</count> <item_version>0</item_version> <item>62</item> </second> </item> <item> <first>377</first> <second> <count>1</count> <item_version>0</item_version> <item>123</item> </second> </item> <item> <first>382</first> <second> <count>1</count> <item_version>0</item_version> <item>63</item> </second> </item> <item> <first>388</first> <second> <count>1</count> <item_version>0</item_version> <item>73</item> </second> </item> <item> <first>396</first> <second> <count>1</count> <item_version>0</item_version> <item>74</item> </second> </item> <item> <first>400</first> <second> <count>1</count> <item_version>0</item_version> <item>81</item> </second> </item> <item> <first>406</first> <second> <count>1</count> <item_version>0</item_version> <item>70</item> </second> </item> <item> <first>409</first> <second> <count>1</count> <item_version>0</item_version> <item>71</item> </second> </item> <item> <first>416</first> <second> <count>1</count> <item_version>0</item_version> <item>72</item> </second> </item> <item> <first>420</first> <second> <count>1</count> <item_version>0</item_version> <item>76</item> </second> </item> <item> <first>423</first> <second> <count>1</count> <item_version>0</item_version> <item>77</item> </second> </item> <item> <first>430</first> <second> <count>1</count> <item_version>0</item_version> <item>78</item> </second> </item> <item> <first>434</first> <second> <count>1</count> <item_version>0</item_version> <item>79</item> </second> </item> <item> <first>437</first> <second> <count>1</count> <item_version>0</item_version> <item>82</item> </second> </item> <item> <first>440</first> <second> <count>1</count> <item_version>0</item_version> <item>83</item> </second> </item> <item> <first>446</first> <second> <count>1</count> <item_version>0</item_version> <item>84</item> </second> </item> <item> <first>450</first> <second> <count>1</count> <item_version>0</item_version> <item>85</item> </second> </item> <item> <first>456</first> <second> <count>1</count> <item_version>0</item_version> <item>87</item> </second> </item> <item> <first>459</first> <second> <count>1</count> <item_version>0</item_version> <item>88</item> </second> </item> <item> <first>465</first> <second> <count>1</count> <item_version>0</item_version> <item>89</item> </second> </item> <item> <first>475</first> <second> <count>1</count> <item_version>0</item_version> <item>93</item> </second> </item> <item> <first>482</first> <second> <count>1</count> <item_version>0</item_version> <item>94</item> </second> </item> <item> <first>486</first> <second> <count>1</count> <item_version>0</item_version> <item>95</item> </second> </item> <item> <first>493</first> <second> <count>1</count> <item_version>0</item_version> <item>96</item> </second> </item> <item> <first>497</first> <second> <count>1</count> <item_version>0</item_version> <item>97</item> </second> </item> <item> <first>501</first> <second> <count>1</count> <item_version>0</item_version> <item>98</item> </second> </item> <item> <first>507</first> <second> <count>1</count> <item_version>0</item_version> <item>100</item> </second> </item> <item> <first>510</first> <second> <count>1</count> <item_version>0</item_version> <item>101</item> </second> </item> <item> <first>516</first> <second> <count>1</count> <item_version>0</item_version> <item>107</item> </second> </item> <item> <first>522</first> <second> <count>1</count> <item_version>0</item_version> <item>108</item> </second> </item> <item> <first>526</first> <second> <count>1</count> <item_version>0</item_version> <item>109</item> </second> </item> <item> <first>533</first> <second> <count>1</count> <item_version>0</item_version> <item>110</item> </second> </item> <item> <first>537</first> <second> <count>1</count> <item_version>0</item_version> <item>111</item> </second> </item> <item> <first>543</first> <second> <count>1</count> <item_version>0</item_version> <item>75</item> </second> </item> <item> <first>546</first> <second> <count>1</count> <item_version>0</item_version> <item>103</item> </second> </item> <item> <first>555</first> <second> <count>1</count> <item_version>0</item_version> <item>112</item> </second> </item> <item> <first>558</first> <second> <count>1</count> <item_version>0</item_version> <item>114</item> </second> </item> <item> <first>561</first> <second> <count>1</count> <item_version>0</item_version> <item>115</item> </second> </item> <item> <first>567</first> <second> <count>1</count> <item_version>0</item_version> <item>117</item> </second> </item> <item> <first>576</first> <second> <count>1</count> <item_version>0</item_version> <item>90</item> </second> </item> <item> <first>582</first> <second> <count>1</count> <item_version>0</item_version> <item>104</item> </second> </item> <item> <first>588</first> <second> <count>1</count> <item_version>0</item_version> <item>118</item> </second> </item> <item> <first>594</first> <second> <count>1</count> <item_version>0</item_version> <item>37</item> </second> </item> <item> <first>600</first> <second> <count>2</count> <item_version>0</item_version> <item>80</item> <item>86</item> </second> </item> <item> <first>609</first> <second> <count>2</count> <item_version>0</item_version> <item>91</item> <item>99</item> </second> </item> <item> <first>618</first> <second> <count>2</count> <item_version>0</item_version> <item>105</item> <item>113</item> </second> </item> <item> <first>626</first> <second> <count>2</count> <item_version>0</item_version> <item>92</item> <item>102</item> </second> </item> <item> <first>634</first> <second> <count>2</count> <item_version>0</item_version> <item>106</item> <item>116</item> </second> </item> </dp_fu_nodes> <dp_fu_nodes_expression class_id="54" tracking_level="0" version="0"> <count>68</count> <item_version>0</item_version> <item class_id="55" tracking_level="0" version="0"> <first>U_fu_582</first> <second> <count>1</count> <item_version>0</item_version> <item>104</item> </second> </item> <item> <first>V_fu_588</first> <second> <count>1</count> <item_version>0</item_version> <item>118</item> </second> </item> <item> <first>Y_fu_576</first> <second> <count>1</count> <item_version>0</item_version> <item>90</item> </second> </item> <item> <first>bound_fu_594</first> <second> <count>1</count> <item_version>0</item_version> <item>37</item> </second> </item> <item> <first>cast1_fu_298</first> <second> <count>1</count> <item_version>0</item_version> <item>36</item> </second> </item> <item> <first>cast_fu_294</first> <second> <count>1</count> <item_version>0</item_version> <item>35</item> </second> </item> <item> <first>exitcond_flatten_fu_302</first> <second> <count>1</count> <item_version>0</item_version> <item>43</item> </second> </item> <item> <first>exitcond_i_i_fu_319</first> <second> <count>1</count> <item_version>0</item_version> <item>50</item> </second> </item> <item> <first>grp_fu_600</first> <second> <count>2</count> <item_version>0</item_version> <item>80</item> <item>86</item> </second> </item> <item> <first>grp_fu_609</first> <second> <count>2</count> <item_version>0</item_version> <item>91</item> <item>99</item> </second> </item> <item> <first>grp_fu_618</first> <second> <count>2</count> <item_version>0</item_version> <item>105</item> <item>113</item> </second> </item> <item> <first>grp_fu_626</first> <second> <count>2</count> <item_version>0</item_version> <item>92</item> <item>102</item> </second> </item> <item> <first>grp_fu_634</first> <second> <count>2</count> <item_version>0</item_version> <item>106</item> <item>116</item> </second> </item> <item> <first>in_channels_ch1_addr_gep_fu_225</first> <second> <count>1</count> <item_version>0</item_version> <item>64</item> </second> </item> <item> <first>in_channels_ch2_addr_gep_fu_232</first> <second> <count>1</count> <item_version>0</item_version> <item>65</item> </second> </item> <item> <first>in_channels_ch3_addr_gep_fu_239</first> <second> <count>1</count> <item_version>0</item_version> <item>66</item> </second> </item> <item> <first>indvar_flatten_next_fu_307</first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> <item> <first>indvar_flatten_phi_fu_265</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first>p_neg_cast_i_i_fu_522</first> <second> <count>1</count> <item_version>0</item_version> <item>108</item> </second> </item> <item> <first>p_neg_i_i_fu_516</first> <second> <count>1</count> <item_version>0</item_version> <item>107</item> </second> </item> <item> <first>p_shl1_cast_fu_355</first> <second> <count>1</count> <item_version>0</item_version> <item>56</item> </second> </item> <item> <first>p_shl1_cast_i_i_fu_533</first> <second> <count>1</count> <item_version>0</item_version> <item>110</item> </second> </item> <item> <first>p_shl1_i_i_fu_526</first> <second> <count>1</count> <item_version>0</item_version> <item>109</item> </second> </item> <item> <first>p_shl2_cast_i_i_fu_482</first> <second> <count>1</count> <item_version>0</item_version> <item>94</item> </second> </item> <item> <first>p_shl2_i_i_fu_475</first> <second> <count>1</count> <item_version>0</item_version> <item>93</item> </second> </item> <item> <first>p_shl3_cast7_i_i_fu_493</first> <second> <count>1</count> <item_version>0</item_version> <item>96</item> </second> </item> <item> <first>p_shl3_cast_i_i_fu_497</first> <second> <count>1</count> <item_version>0</item_version> <item>97</item> </second> </item> <item> <first>p_shl3_i_i_fu_486</first> <second> <count>1</count> <item_version>0</item_version> <item>95</item> </second> </item> <item> <first>p_shl4_cast_i_i_fu_430</first> <second> <count>1</count> <item_version>0</item_version> <item>78</item> </second> </item> <item> <first>p_shl4_i_i_fu_423</first> <second> <count>1</count> <item_version>0</item_version> <item>77</item> </second> </item> <item> <first>p_shl5_cast_i_i_fu_416</first> <second> <count>1</count> <item_version>0</item_version> <item>72</item> </second> </item> <item> <first>p_shl5_i_i_fu_409</first> <second> <count>1</count> <item_version>0</item_version> <item>71</item> </second> </item> <item> <first>p_shl6_cast_i_i_cast_fu_396</first> <second> <count>1</count> <item_version>0</item_version> <item>74</item> </second> </item> <item> <first>p_shl6_i_i_fu_388</first> <second> <count>1</count> <item_version>0</item_version> <item>73</item> </second> </item> <item> <first>p_shl_cast_fu_348</first> <second> <count>1</count> <item_version>0</item_version> <item>54</item> </second> </item> <item> <first>tmp1_fu_450</first> <second> <count>1</count> <item_version>0</item_version> <item>85</item> </second> </item> <item> <first>tmp2_cast_fu_456</first> <second> <count>1</count> <item_version>0</item_version> <item>87</item> </second> </item> <item> <first>tmp3_fu_510</first> <second> <count>1</count> <item_version>0</item_version> <item>101</item> </second> </item> <item> <first>tmp4_fu_561</first> <second> <count>1</count> <item_version>0</item_version> <item>115</item> </second> </item> <item> <first>tmp_22_fu_340</first> <second> <count>1</count> <item_version>0</item_version> <item>53</item> </second> </item> <item> <first>tmp_23_fu_344</first> <second> <count>1</count> <item_version>0</item_version> <item>55</item> </second> </item> <item> <first>tmp_24_fu_371</first> <second> <count>1</count> <item_version>0</item_version> <item>62</item> </second> </item> <item> <first>tmp_26_cast_fu_382</first> <second> <count>1</count> <item_version>0</item_version> <item>63</item> </second> </item> <item> <first>tmp_40_cast14_i_i_fu_406</first> <second> <count>1</count> <item_version>0</item_version> <item>70</item> </second> </item> <item> <first>tmp_42_cast11_i_i_ca_fu_420</first> <second> <count>1</count> <item_version>0</item_version> <item>76</item> </second> </item> <item> <first>tmp_42_cast11_i_i_fu_543</first> <second> <count>1</count> <item_version>0</item_version> <item>75</item> </second> </item> <item> <first>tmp_44_cast10_i_i_fu_434</first> <second> <count>1</count> <item_version>0</item_version> <item>79</item> </second> </item> <item> <first>tmp_46_cast_i_i_fu_446</first> <second> <count>1</count> <item_version>0</item_version> <item>84</item> </second> </item> <item> <first>tmp_46_i_i_fu_440</first> <second> <count>1</count> <item_version>0</item_version> <item>83</item> </second> </item> <item> <first>tmp_48_i_i_fu_459</first> <second> <count>1</count> <item_version>0</item_version> <item>88</item> </second> </item> <item> <first>tmp_50_i_i_fu_465</first> <second> <count>1</count> <item_version>0</item_version> <item>89</item> </second> </item> <item> <first>tmp_53_i_i_fu_501</first> <second> <count>1</count> <item_version>0</item_version> <item>98</item> </second> </item> <item> <first>tmp_54_cast_i_i_fu_507</first> <second> <count>1</count> <item_version>0</item_version> <item>100</item> </second> </item> <item> <first>tmp_58_i_i_fu_546</first> <second> <count>1</count> <item_version>0</item_version> <item>103</item> </second> </item> <item> <first>tmp_61_cast_i_i_fu_555</first> <second> <count>1</count> <item_version>0</item_version> <item>112</item> </second> </item> <item> <first>tmp_61_i_i_fu_537</first> <second> <count>1</count> <item_version>0</item_version> <item>111</item> </second> </item> <item> <first>tmp_62_cast_i_i_fu_558</first> <second> <count>1</count> <item_version>0</item_version> <item>114</item> </second> </item> <item> <first>tmp_66_i_i_fu_567</first> <second> <count>1</count> <item_version>0</item_version> <item>117</item> </second> </item> <item> <first>tmp_cast_fu_437</first> <second> <count>1</count> <item_version>0</item_version> <item>82</item> </second> </item> <item> <first>tmp_fu_400</first> <second> <count>1</count> <item_version>0</item_version> <item>81</item> </second> </item> <item> <first>tmp_i_i_cast_fu_368</first> <second> <count>1</count> <item_version>0</item_version> <item>61</item> </second> </item> <item> <first>tmp_i_i_mid2_v_fu_332</first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> <item> <first>tmp_s_fu_362</first> <second> <count>1</count> <item_version>0</item_version> <item>57</item> </second> </item> <item> <first>x_fu_313</first> <second> <count>1</count> <item_version>0</item_version> <item>47</item> </second> </item> <item> <first>x_i_i_phi_fu_276</first> <second> <count>1</count> <item_version>0</item_version> <item>41</item> </second> </item> <item> <first>y_fu_377</first> <second> <count>1</count> <item_version>0</item_version> <item>123</item> </second> </item> <item> <first>y_i_i_mid2_fu_324</first> <second> <count>1</count> <item_version>0</item_version> <item>51</item> </second> </item> <item> <first>y_i_i_phi_fu_287</first> <second> <count>1</count> <item_version>0</item_version> <item>42</item> </second> </item> </dp_fu_nodes_expression> <dp_fu_nodes_module> <count>0</count> <item_version>0</item_version> </dp_fu_nodes_module> <dp_fu_nodes_io> <count>13</count> <item_version>0</item_version> <item> <first>StgValue_122_write_fu_204</first> <second> <count>1</count> <item_version>0</item_version> <item>119</item> </second> </item> <item> <first>StgValue_123_write_fu_211</first> <second> <count>1</count> <item_version>0</item_version> <item>120</item> </second> </item> <item> <first>StgValue_124_write_fu_218</first> <second> <count>1</count> <item_version>0</item_version> <item>121</item> </second> </item> <item> <first>StgValue_21_write_fu_152</first> <second> <count>1</count> <item_version>0</item_version> <item>26</item> </second> </item> <item> <first>StgValue_23_write_fu_160</first> <second> <count>1</count> <item_version>0</item_version> <item>28</item> </second> </item> <item> <first>StgValue_25_write_fu_168</first> <second> <count>1</count> <item_version>0</item_version> <item>30</item> </second> </item> <item> <first>StgValue_28_write_fu_188</first> <second> <count>1</count> <item_version>0</item_version> <item>33</item> </second> </item> <item> <first>StgValue_29_write_fu_196</first> <second> <count>1</count> <item_version>0</item_version> <item>34</item> </second> </item> <item> <first>U_scale_read_read_fu_140</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> <item> <first>V_scale_read_read_fu_134</first> <second> <count>1</count> <item_version>0</item_version> <item>23</item> </second> </item> <item> <first>Y_scale_read_read_fu_146</first> <second> <count>1</count> <item_version>0</item_version> <item>25</item> </second> </item> <item> <first>height_read_fu_182</first> <second> <count>1</count> <item_version>0</item_version> <item>32</item> </second> </item> <item> <first>width_read_fu_176</first> <second> <count>1</count> <item_version>0</item_version> <item>31</item> </second> </item> </dp_fu_nodes_io> <return_ports> <count>0</count> <item_version>0</item_version> </return_ports> <dp_mem_port_nodes class_id="56" tracking_level="0" version="0"> <count>3</count> <item_version>0</item_version> <item class_id="57" tracking_level="0" version="0"> <first class_id="58" tracking_level="0" version="0"> <first>in_channels_ch1</first> <second>0</second> </first> <second> <count>4</count> <item_version>0</item_version> <item>67</item> <item>67</item> <item>67</item> <item>67</item> </second> </item> <item> <first> <first>in_channels_ch2</first> <second>0</second> </first> <second> <count>4</count> <item_version>0</item_version> <item>68</item> <item>68</item> <item>68</item> <item>68</item> </second> </item> <item> <first> <first>in_channels_ch3</first> <second>0</second> </first> <second> <count>4</count> <item_version>0</item_version> <item>69</item> <item>69</item> <item>69</item> <item>69</item> </second> </item> </dp_mem_port_nodes> <dp_reg_nodes> <count>26</count> <item_version>0</item_version> <item> <first>261</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first>272</first> <second> <count>1</count> <item_version>0</item_version> <item>41</item> </second> </item> <item> <first>283</first> <second> <count>1</count> <item_version>0</item_version> <item>42</item> </second> </item> <item> <first>643</first> <second> <count>1</count> <item_version>0</item_version> <item>32</item> </second> </item> <item> <first>648</first> <second> <count>1</count> <item_version>0</item_version> <item>37</item> </second> </item> <item> <first>653</first> <second> <count>1</count> <item_version>0</item_version> <item>43</item> </second> </item> <item> <first>657</first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> <item> <first>662</first> <second> <count>1</count> <item_version>0</item_version> <item>51</item> </second> </item> <item> <first>668</first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> <item> <first>673</first> <second> <count>1</count> <item_version>0</item_version> <item>53</item> </second> </item> <item> <first>678</first> <second> <count>1</count> <item_version>0</item_version> <item>55</item> </second> </item> <item> <first>683</first> <second> <count>1</count> <item_version>0</item_version> <item>62</item> </second> </item> <item> <first>688</first> <second> <count>1</count> <item_version>0</item_version> <item>123</item> </second> </item> <item> <first>693</first> <second> <count>1</count> <item_version>0</item_version> <item>64</item> </second> </item> <item> <first>698</first> <second> <count>1</count> <item_version>0</item_version> <item>65</item> </second> </item> <item> <first>703</first> <second> <count>1</count> <item_version>0</item_version> <item>66</item> </second> </item> <item> <first>708</first> <second> <count>1</count> <item_version>0</item_version> <item>67</item> </second> </item> <item> <first>714</first> <second> <count>1</count> <item_version>0</item_version> <item>68</item> </second> </item> <item> <first>721</first> <second> <count>1</count> <item_version>0</item_version> <item>69</item> </second> </item> <item> <first>729</first> <second> <count>1</count> <item_version>0</item_version> <item>81</item> </second> </item> <item> <first>734</first> <second> <count>1</count> <item_version>0</item_version> <item>89</item> </second> </item> <item> <first>739</first> <second> <count>1</count> <item_version>0</item_version> <item>101</item> </second> </item> <item> <first>744</first> <second> <count>1</count> <item_version>0</item_version> <item>111</item> </second> </item> <item> <first>749</first> <second> <count>1</count> <item_version>0</item_version> <item>113</item> </second> </item> <item> <first>754</first> <second> <count>1</count> <item_version>0</item_version> <item>103</item> </second> </item> <item> <first>759</first> <second> <count>1</count> <item_version>0</item_version> <item>117</item> </second> </item> </dp_reg_nodes> <dp_regname_nodes> <count>26</count> <item_version>0</item_version> <item> <first>B_reg_721</first> <second> <count>1</count> <item_version>0</item_version> <item>69</item> </second> </item> <item> <first>G_reg_714</first> <second> <count>1</count> <item_version>0</item_version> <item>68</item> </second> </item> <item> <first>R_reg_708</first> <second> <count>1</count> <item_version>0</item_version> <item>67</item> </second> </item> <item> <first>bound_reg_648</first> <second> <count>1</count> <item_version>0</item_version> <item>37</item> </second> </item> <item> <first>exitcond_flatten_reg_653</first> <second> <count>1</count> <item_version>0</item_version> <item>43</item> </second> </item> <item> <first>height_reg_643</first> <second> <count>1</count> <item_version>0</item_version> <item>32</item> </second> </item> <item> <first>in_channels_ch1_addr_reg_693</first> <second> <count>1</count> <item_version>0</item_version> <item>64</item> </second> </item> <item> <first>in_channels_ch2_addr_reg_698</first> <second> <count>1</count> <item_version>0</item_version> <item>65</item> </second> </item> <item> <first>in_channels_ch3_addr_reg_703</first> <second> <count>1</count> <item_version>0</item_version> <item>66</item> </second> </item> <item> <first>indvar_flatten_next_reg_657</first> <second> <count>1</count> <item_version>0</item_version> <item>44</item> </second> </item> <item> <first>indvar_flatten_reg_261</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first>tmp3_reg_739</first> <second> <count>1</count> <item_version>0</item_version> <item>101</item> </second> </item> <item> <first>tmp_22_reg_673</first> <second> <count>1</count> <item_version>0</item_version> <item>53</item> </second> </item> <item> <first>tmp_23_reg_678</first> <second> <count>1</count> <item_version>0</item_version> <item>55</item> </second> </item> <item> <first>tmp_24_reg_683</first> <second> <count>1</count> <item_version>0</item_version> <item>62</item> </second> </item> <item> <first>tmp_50_i_i_reg_734</first> <second> <count>1</count> <item_version>0</item_version> <item>89</item> </second> </item> <item> <first>tmp_58_i_i_reg_754</first> <second> <count>1</count> <item_version>0</item_version> <item>103</item> </second> </item> <item> <first>tmp_61_i_i_reg_744</first> <second> <count>1</count> <item_version>0</item_version> <item>111</item> </second> </item> <item> <first>tmp_62_i_i_reg_749</first> <second> <count>1</count> <item_version>0</item_version> <item>113</item> </second> </item> <item> <first>tmp_66_i_i_reg_759</first> <second> <count>1</count> <item_version>0</item_version> <item>117</item> </second> </item> <item> <first>tmp_i_i_mid2_v_reg_668</first> <second> <count>1</count> <item_version>0</item_version> <item>52</item> </second> </item> <item> <first>tmp_reg_729</first> <second> <count>1</count> <item_version>0</item_version> <item>81</item> </second> </item> <item> <first>x_i_i_reg_272</first> <second> <count>1</count> <item_version>0</item_version> <item>41</item> </second> </item> <item> <first>y_i_i_mid2_reg_662</first> <second> <count>1</count> <item_version>0</item_version> <item>51</item> </second> </item> <item> <first>y_i_i_reg_283</first> <second> <count>1</count> <item_version>0</item_version> <item>42</item> </second> </item> <item> <first>y_reg_688</first> <second> <count>1</count> <item_version>0</item_version> <item>123</item> </second> </item> </dp_regname_nodes> <dp_reg_phi> <count>3</count> <item_version>0</item_version> <item> <first>261</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first>272</first> <second> <count>1</count> <item_version>0</item_version> <item>41</item> </second> </item> <item> <first>283</first> <second> <count>1</count> <item_version>0</item_version> <item>42</item> </second> </item> </dp_reg_phi> <dp_regname_phi> <count>3</count> <item_version>0</item_version> <item> <first>indvar_flatten_reg_261</first> <second> <count>1</count> <item_version>0</item_version> <item>40</item> </second> </item> <item> <first>x_i_i_reg_272</first> <second> <count>1</count> <item_version>0</item_version> <item>41</item> </second> </item> <item> <first>y_i_i_reg_283</first> <second> <count>1</count> <item_version>0</item_version> <item>42</item> </second> </item> </dp_regname_phi> <dp_port_io_nodes class_id="59" tracking_level="0" version="0"> <count>16</count> <item_version>0</item_version> <item class_id="60" tracking_level="0" version="0"> <first>U_scale</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>24</item> </second> </item> </second> </item> <item> <first>U_scale_out</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>28</item> </second> </item> </second> </item> <item> <first>V_scale</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>23</item> </second> </item> </second> </item> <item> <first>V_scale_out</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>30</item> </second> </item> </second> </item> <item> <first>Y_scale</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>25</item> </second> </item> </second> </item> <item> <first>Y_scale_out</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>26</item> </second> </item> </second> </item> <item> <first>in_channels_ch1(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>load</first> <second> <count>4</count> <item_version>0</item_version> <item>67</item> <item>67</item> <item>67</item> <item>67</item> </second> </item> </second> </item> <item> <first>in_channels_ch2(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>load</first> <second> <count>4</count> <item_version>0</item_version> <item>68</item> <item>68</item> <item>68</item> <item>68</item> </second> </item> </second> </item> <item> <first>in_channels_ch3(p0)</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>load</first> <second> <count>4</count> <item_version>0</item_version> <item>69</item> <item>69</item> <item>69</item> <item>69</item> </second> </item> </second> </item> <item> <first>in_height</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>32</item> </second> </item> </second> </item> <item> <first>in_width</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>read</first> <second> <count>1</count> <item_version>0</item_version> <item>31</item> </second> </item> </second> </item> <item> <first>out_channels_ch1</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>119</item> </second> </item> </second> </item> <item> <first>out_channels_ch2</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>120</item> </second> </item> </second> </item> <item> <first>out_channels_ch3</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>121</item> </second> </item> </second> </item> <item> <first>out_height</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>34</item> </second> </item> </second> </item> <item> <first>out_width</first> <second> <count>1</count> <item_version>0</item_version> <item> <first>write</first> <second> <count>1</count> <item_version>0</item_version> <item>33</item> </second> </item> </second> </item> </dp_port_io_nodes> <port2core class_id="61" tracking_level="0" version="0"> <count>11</count> <item_version>0</item_version> <item class_id="62" tracking_level="0" version="0"> <first>1</first> <second>RAM</second> </item> <item> <first>2</first> <second>RAM</second> </item> <item> <first>3</first> <second>RAM</second> </item> <item> <first>6</first> <second>FIFO_LUTRAM</second> </item> <item> <first>7</first> <second>FIFO_LUTRAM</second> </item> <item> <first>8</first> <second>FIFO_LUTRAM</second> </item> <item> <first>9</first> <second>FIFO_LUTRAM</second> </item> <item> <first>10</first> <second>FIFO_LUTRAM</second> </item> <item> <first>14</first> <second>FIFO_LUTRAM</second> </item> <item> <first>15</first> <second>FIFO_LUTRAM</second> </item> <item> <first>16</first> <second>FIFO_LUTRAM</second> </item> </port2core> <node2core> <count>0</count> <item_version>0</item_version> </node2core> </syndb> </boost_serialization>
-- WORDS, a Latin dictionary, by Colonel William Whitaker (USAF, Retired) -- -- Copyright William A. Whitaker (1936–2010) -- -- This is a free program, which means it is proper to copy it and pass -- it on to your friends. Consider it a developmental item for which -- there is no charge. However, just for form, it is Copyrighted -- (c). Permission is hereby freely given for any and all use of program -- and data. You can sell it as your own, but at least tell me. -- -- This version is distributed without obligation, but the developer -- would appreciate comments and suggestions. -- -- All parts of the WORDS system, source code and data files, are made freely -- available to anyone who wishes to use them, for whatever purpose. --------------------------------------------------------------------------- -- Main package of library-like utilities used all over the WORDS. --------------------------------------------------------------------------- package Latin_Utils is --------------------------------------------------------------------------- pragma Pure (Latin_Utils); --------------------------------------------------------------------------- end Latin_Utils;
-- Copyright (c) 1990 Regents of the University of California. -- All rights reserved. -- -- This software was developed by John Self of the Arcadia project -- at the University of California, Irvine. -- -- Redistribution and use in source and binary forms are permitted -- provided that the above copyright notice and this paragraph are -- duplicated in all such forms and that any documentation, -- advertising materials, and other materials related to such -- distribution and use acknowledge that the software was developed -- by the University of California, Irvine. The name of the -- University may not be used to endorse or promote products derived -- from this software without specific prior written permission. -- THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR -- IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED -- WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. -- TITLE scanner generation -- AUTHOR: John Self (UCI) -- DESCRIPTION -- NOTES does actual generation (writing) of output aflex scanners -- $Header: /co/ua/self/arcadia/aflex/ada/src/RCS/genS.a,v 1.4 90/01/12 15:20:07 self Exp Locker: self $ with misc_defs; use misc_defs; package gen is procedure DO_INDENT; procedure GEN_BACKTRACKING; procedure GEN_BT_ACTION; procedure GEN_FIND_ACTION; procedure GEN_NEXT_COMPRESSED_STATE; procedure GEN_NEXT_MATCH; procedure GEN_NEXT_STATE; procedure GEN_START_STATE; procedure GENECS; procedure GENFTBL; procedure INDENT_PUTS(STR : in STRING); procedure GENTABS; procedure INDENT_DOWN; procedure INDENT_UP; procedure SET_INDENT(INDENT_VAL : in INTEGER); procedure MAKE_TABLES; procedure DO_SECT3_OUT; end gen;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- M A K E U T L -- -- -- -- B o d y -- -- -- -- Copyright (C) 2004-2010, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING3. If not, go to -- -- http://www.gnu.org/licenses for a complete copy of the license. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with ALI; use ALI; with Debug; with Fname; with Hostparm; with Osint; use Osint; with Output; use Output; with Opt; use Opt; with Prj.Ext; with Prj.Util; with Snames; use Snames; with Table; with Tempdir; with Ada.Command_Line; use Ada.Command_Line; with GNAT.Case_Util; use GNAT.Case_Util; with GNAT.Directory_Operations; use GNAT.Directory_Operations; with GNAT.HTable; package body Makeutl is type Mark_Key is record File : File_Name_Type; Index : Int; end record; -- Identify either a mono-unit source (when Index = 0) or a specific unit -- (index = 1's origin index of unit) in a multi-unit source. -- There follow many global undocumented declarations, comments needed ??? Max_Mask_Num : constant := 2048; subtype Mark_Num is Union_Id range 0 .. Max_Mask_Num - 1; function Hash (Key : Mark_Key) return Mark_Num; package Marks is new GNAT.HTable.Simple_HTable (Header_Num => Mark_Num, Element => Boolean, No_Element => False, Key => Mark_Key, Hash => Hash, Equal => "="); -- A hash table to keep tracks of the marked units type Linker_Options_Data is record Project : Project_Id; Options : String_List_Id; end record; Linker_Option_Initial_Count : constant := 20; Linker_Options_Buffer : String_List_Access := new String_List (1 .. Linker_Option_Initial_Count); Last_Linker_Option : Natural := 0; package Linker_Opts is new Table.Table ( Table_Component_Type => Linker_Options_Data, Table_Index_Type => Integer, Table_Low_Bound => 1, Table_Initial => 10, Table_Increment => 100, Table_Name => "Make.Linker_Opts"); procedure Add_Linker_Option (Option : String); --------- -- Add -- --------- procedure Add (Option : String_Access; To : in out String_List_Access; Last : in out Natural) is begin if Last = To'Last then declare New_Options : constant String_List_Access := new String_List (1 .. To'Last * 2); begin New_Options (To'Range) := To.all; -- Set all elements of the original options to null to avoid -- deallocation of copies. To.all := (others => null); Free (To); To := New_Options; end; end if; Last := Last + 1; To (Last) := Option; end Add; procedure Add (Option : String; To : in out String_List_Access; Last : in out Natural) is begin Add (Option => new String'(Option), To => To, Last => Last); end Add; ----------------------- -- Add_Linker_Option -- ----------------------- procedure Add_Linker_Option (Option : String) is begin if Option'Length > 0 then if Last_Linker_Option = Linker_Options_Buffer'Last then declare New_Buffer : constant String_List_Access := new String_List (1 .. Linker_Options_Buffer'Last + Linker_Option_Initial_Count); begin New_Buffer (Linker_Options_Buffer'Range) := Linker_Options_Buffer.all; Linker_Options_Buffer.all := (others => null); Free (Linker_Options_Buffer); Linker_Options_Buffer := New_Buffer; end; end if; Last_Linker_Option := Last_Linker_Option + 1; Linker_Options_Buffer (Last_Linker_Option) := new String'(Option); end if; end Add_Linker_Option; ------------------------- -- Base_Name_Index_For -- ------------------------- function Base_Name_Index_For (Main : String; Main_Index : Int; Index_Separator : Character) return File_Name_Type is Result : File_Name_Type; begin Name_Len := 0; Add_Str_To_Name_Buffer (Base_Name (Main)); -- Remove the extension, if any, that is the last part of the base name -- starting with a dot and following some characters. for J in reverse 2 .. Name_Len loop if Name_Buffer (J) = '.' then Name_Len := J - 1; exit; end if; end loop; -- Add the index info, if index is different from 0 if Main_Index > 0 then Add_Char_To_Name_Buffer (Index_Separator); declare Img : constant String := Main_Index'Img; begin Add_Str_To_Name_Buffer (Img (2 .. Img'Last)); end; end if; Result := Name_Find; return Result; end Base_Name_Index_For; ------------------------------ -- Check_Source_Info_In_ALI -- ------------------------------ function Check_Source_Info_In_ALI (The_ALI : ALI_Id; Tree : Project_Tree_Ref) return Boolean is Unit_Name : Name_Id; begin -- Loop through units for U in ALIs.Table (The_ALI).First_Unit .. ALIs.Table (The_ALI).Last_Unit loop -- Check if the file name is one of the source of the unit Get_Name_String (Units.Table (U).Uname); Name_Len := Name_Len - 2; Unit_Name := Name_Find; if File_Not_A_Source_Of (Unit_Name, Units.Table (U).Sfile) then return False; end if; -- Loop to do same check for each of the withed units for W in Units.Table (U).First_With .. Units.Table (U).Last_With loop declare WR : ALI.With_Record renames Withs.Table (W); begin if WR.Sfile /= No_File then Get_Name_String (WR.Uname); Name_Len := Name_Len - 2; Unit_Name := Name_Find; if File_Not_A_Source_Of (Unit_Name, WR.Sfile) then return False; end if; end if; end; end loop; end loop; -- Loop to check subunits and replaced sources for D in ALIs.Table (The_ALI).First_Sdep .. ALIs.Table (The_ALI).Last_Sdep loop declare SD : Sdep_Record renames Sdep.Table (D); begin Unit_Name := SD.Subunit_Name; if Unit_Name = No_Name then -- Check if this source file has been replaced by a source with -- a different file name. if Tree /= null and then Tree.Replaced_Source_Number > 0 then declare Replacement : constant File_Name_Type := Replaced_Source_HTable.Get (Tree.Replaced_Sources, SD.Sfile); begin if Replacement /= No_File then if Verbose_Mode then Write_Line ("source file" & Get_Name_String (SD.Sfile) & " has been replaced by " & Get_Name_String (Replacement)); end if; return False; end if; end; end if; else -- For separates, the file is no longer associated with the -- unit ("proc-sep.adb" is not associated with unit "proc.sep") -- so we need to check whether the source file still exists in -- the source tree: it will if it matches the naming scheme -- (and then will be for the same unit). if Find_Source (In_Tree => Project_Tree, Project => No_Project, Base_Name => SD.Sfile) = No_Source then -- If this is not a runtime file or if, when gnatmake switch -- -a is used, we are not able to find this subunit in the -- source directories, then recompilation is needed. if not Fname.Is_Internal_File_Name (SD.Sfile) or else (Check_Readonly_Files and then Full_Source_Name (SD.Sfile) = No_File) then if Verbose_Mode then Write_Line ("While parsing ALI file, file " & Get_Name_String (SD.Sfile) & " is indicated as containing subunit " & Get_Name_String (Unit_Name) & " but this does not match what was found while" & " parsing the project. Will recompile"); end if; return False; end if; end if; end if; end; end loop; return True; end Check_Source_Info_In_ALI; -------------------------------- -- Create_Binder_Mapping_File -- -------------------------------- function Create_Binder_Mapping_File return Path_Name_Type is Mapping_Path : Path_Name_Type := No_Path; Mapping_FD : File_Descriptor := Invalid_FD; -- A File Descriptor for an eventual mapping file ALI_Unit : Unit_Name_Type := No_Unit_Name; -- The unit name of an ALI file ALI_Name : File_Name_Type := No_File; -- The file name of the ALI file ALI_Project : Project_Id := No_Project; -- The project of the ALI file Bytes : Integer; OK : Boolean := False; Unit : Unit_Index; Status : Boolean; -- For call to Close begin Tempdir.Create_Temp_File (Mapping_FD, Mapping_Path); Record_Temp_File (Project_Tree, Mapping_Path); if Mapping_FD /= Invalid_FD then OK := True; -- Traverse all units Unit := Units_Htable.Get_First (Project_Tree.Units_HT); while Unit /= No_Unit_Index loop if Unit.Name /= No_Name then -- If there is a body, put it in the mapping if Unit.File_Names (Impl) /= No_Source and then Unit.File_Names (Impl).Project /= No_Project then Get_Name_String (Unit.Name); Add_Str_To_Name_Buffer ("%b"); ALI_Unit := Name_Find; ALI_Name := Lib_File_Name (Unit.File_Names (Impl).Display_File); ALI_Project := Unit.File_Names (Impl).Project; -- Otherwise, if there is a spec, put it in the mapping elsif Unit.File_Names (Spec) /= No_Source and then Unit.File_Names (Spec).Project /= No_Project then Get_Name_String (Unit.Name); Add_Str_To_Name_Buffer ("%s"); ALI_Unit := Name_Find; ALI_Name := Lib_File_Name (Unit.File_Names (Spec).Display_File); ALI_Project := Unit.File_Names (Spec).Project; else ALI_Name := No_File; end if; -- If we have something to put in the mapping then do it now. -- However, if the project is extended, we don't put anything -- in the mapping file, since we don't know where the ALI file -- is: it might be in the extended project object directory as -- well as in the extending project object directory. if ALI_Name /= No_File and then ALI_Project.Extended_By = No_Project and then ALI_Project.Extends = No_Project then -- First check if the ALI file exists. If it does not, do -- not put the unit in the mapping file. declare ALI : constant String := Get_Name_String (ALI_Name); begin -- For library projects, use the library ALI directory, -- for other projects, use the object directory. if ALI_Project.Library then Get_Name_String (ALI_Project.Library_ALI_Dir.Display_Name); else Get_Name_String (ALI_Project.Object_Directory.Display_Name); end if; if not Is_Directory_Separator (Name_Buffer (Name_Len)) then Add_Char_To_Name_Buffer (Directory_Separator); end if; Add_Str_To_Name_Buffer (ALI); Add_Char_To_Name_Buffer (ASCII.LF); declare ALI_Path_Name : constant String := Name_Buffer (1 .. Name_Len); begin if Is_Regular_File (ALI_Path_Name (1 .. ALI_Path_Name'Last - 1)) then -- First line is the unit name Get_Name_String (ALI_Unit); Add_Char_To_Name_Buffer (ASCII.LF); Bytes := Write (Mapping_FD, Name_Buffer (1)'Address, Name_Len); OK := Bytes = Name_Len; exit when not OK; -- Second line it the ALI file name Get_Name_String (ALI_Name); Add_Char_To_Name_Buffer (ASCII.LF); Bytes := Write (Mapping_FD, Name_Buffer (1)'Address, Name_Len); OK := (Bytes = Name_Len); exit when not OK; -- Third line it the ALI path name Bytes := Write (Mapping_FD, ALI_Path_Name (1)'Address, ALI_Path_Name'Length); OK := (Bytes = ALI_Path_Name'Length); -- If OK is False, it means we were unable to -- write a line. No point in continuing with the -- other units. exit when not OK; end if; end; end; end if; end if; Unit := Units_Htable.Get_Next (Project_Tree.Units_HT); end loop; Close (Mapping_FD, Status); OK := OK and Status; end if; -- If the creation of the mapping file was successful, we add the switch -- to the arguments of gnatbind. if OK then return Mapping_Path; else return No_Path; end if; end Create_Binder_Mapping_File; ----------------- -- Create_Name -- ----------------- function Create_Name (Name : String) return File_Name_Type is begin Name_Len := 0; Add_Str_To_Name_Buffer (Name); return Name_Find; end Create_Name; function Create_Name (Name : String) return Name_Id is begin Name_Len := 0; Add_Str_To_Name_Buffer (Name); return Name_Find; end Create_Name; function Create_Name (Name : String) return Path_Name_Type is begin Name_Len := 0; Add_Str_To_Name_Buffer (Name); return Name_Find; end Create_Name; ---------------------- -- Delete_All_Marks -- ---------------------- procedure Delete_All_Marks is begin Marks.Reset; end Delete_All_Marks; ---------------------------- -- Executable_Prefix_Path -- ---------------------------- function Executable_Prefix_Path return String is Exec_Name : constant String := Command_Name; function Get_Install_Dir (S : String) return String; -- S is the executable name preceded by the absolute or relative path, -- e.g. "c:\usr\bin\gcc.exe". Returns the absolute directory where "bin" -- lies (in the example "C:\usr"). If the executable is not in a "bin" -- directory, return "". --------------------- -- Get_Install_Dir -- --------------------- function Get_Install_Dir (S : String) return String is Exec : String := S; Path_Last : Integer := 0; begin for J in reverse Exec'Range loop if Exec (J) = Directory_Separator then Path_Last := J - 1; exit; end if; end loop; if Path_Last >= Exec'First + 2 then To_Lower (Exec (Path_Last - 2 .. Path_Last)); end if; if Path_Last < Exec'First + 2 or else Exec (Path_Last - 2 .. Path_Last) /= "bin" or else (Path_Last - 3 >= Exec'First and then Exec (Path_Last - 3) /= Directory_Separator) then return ""; end if; return Normalize_Pathname (Exec (Exec'First .. Path_Last - 4), Resolve_Links => Opt.Follow_Links_For_Dirs) & Directory_Separator; end Get_Install_Dir; -- Beginning of Executable_Prefix_Path begin -- For VMS, the path returned is always /gnu/ if Hostparm.OpenVMS then return "/gnu/"; end if; -- First determine if a path prefix was placed in front of the -- executable name. for J in reverse Exec_Name'Range loop if Exec_Name (J) = Directory_Separator then return Get_Install_Dir (Exec_Name); end if; end loop; -- If we get here, the user has typed the executable name with no -- directory prefix. declare Path : String_Access := Locate_Exec_On_Path (Exec_Name); begin if Path = null then return ""; else declare Dir : constant String := Get_Install_Dir (Path.all); begin Free (Path); return Dir; end; end if; end; end Executable_Prefix_Path; -------------------------- -- File_Not_A_Source_Of -- -------------------------- function File_Not_A_Source_Of (Uname : Name_Id; Sfile : File_Name_Type) return Boolean is Unit : constant Unit_Index := Units_Htable.Get (Project_Tree.Units_HT, Uname); At_Least_One_File : Boolean := False; begin if Unit /= No_Unit_Index then for F in Unit.File_Names'Range loop if Unit.File_Names (F) /= null then At_Least_One_File := True; if Unit.File_Names (F).File = Sfile then return False; end if; end if; end loop; if not At_Least_One_File then -- The unit was probably created initially for a separate unit -- (which are initially created as IMPL when both suffixes are the -- same). Later on, Override_Kind changed the type of the file, -- and the unit is no longer valid in fact. return False; end if; Verbose_Msg (Uname, "sources do not include ", Name_Id (Sfile)); return True; end if; return False; end File_Not_A_Source_Of; ---------- -- Hash -- ---------- function Hash (Key : Mark_Key) return Mark_Num is begin return Union_Id (Key.File) mod Max_Mask_Num; end Hash; ------------ -- Inform -- ------------ procedure Inform (N : File_Name_Type; Msg : String) is begin Inform (Name_Id (N), Msg); end Inform; procedure Inform (N : Name_Id := No_Name; Msg : String) is begin Osint.Write_Program_Name; Write_Str (": "); if N /= No_Name then Write_Str (""""); declare Name : constant String := Get_Name_String (N); begin if Debug.Debug_Flag_F and then Is_Absolute_Path (Name) then Write_Str (File_Name (Name)); else Write_Str (Name); end if; end; Write_Str (""" "); end if; Write_Str (Msg); Write_Eol; end Inform; ---------------------------- -- Is_External_Assignment -- ---------------------------- function Is_External_Assignment (Tree : Prj.Tree.Project_Node_Tree_Ref; Argv : String) return Boolean is Start : Positive := 3; Finish : Natural := Argv'Last; pragma Assert (Argv'First = 1); pragma Assert (Argv (1 .. 2) = "-X"); begin if Argv'Last < 5 then return False; elsif Argv (3) = '"' then if Argv (Argv'Last) /= '"' or else Argv'Last < 7 then return False; else Start := 4; Finish := Argv'Last - 1; end if; end if; return Prj.Ext.Check (Tree => Tree, Declaration => Argv (Start .. Finish)); end Is_External_Assignment; --------------- -- Is_Marked -- --------------- function Is_Marked (Source_File : File_Name_Type; Index : Int := 0) return Boolean is begin return Marks.Get (K => (File => Source_File, Index => Index)); end Is_Marked; ----------------------------- -- Linker_Options_Switches -- ----------------------------- function Linker_Options_Switches (Project : Project_Id; In_Tree : Project_Tree_Ref) return String_List is procedure Recursive_Add (Proj : Project_Id; Dummy : in out Boolean); -- The recursive routine used to add linker options ------------------- -- Recursive_Add -- ------------------- procedure Recursive_Add (Proj : Project_Id; Dummy : in out Boolean) is pragma Unreferenced (Dummy); Linker_Package : Package_Id; Options : Variable_Value; begin Linker_Package := Prj.Util.Value_Of (Name => Name_Linker, In_Packages => Proj.Decl.Packages, In_Tree => In_Tree); Options := Prj.Util.Value_Of (Name => Name_Ada, Index => 0, Attribute_Or_Array_Name => Name_Linker_Options, In_Package => Linker_Package, In_Tree => In_Tree); -- If attribute is present, add the project with -- the attribute to table Linker_Opts. if Options /= Nil_Variable_Value then Linker_Opts.Increment_Last; Linker_Opts.Table (Linker_Opts.Last) := (Project => Proj, Options => Options.Values); end if; end Recursive_Add; procedure For_All_Projects is new For_Every_Project_Imported (Boolean, Recursive_Add); Dummy : Boolean := False; -- Start of processing for Linker_Options_Switches begin Linker_Opts.Init; For_All_Projects (Project, Dummy, Imported_First => True); Last_Linker_Option := 0; for Index in reverse 1 .. Linker_Opts.Last loop declare Options : String_List_Id; Proj : constant Project_Id := Linker_Opts.Table (Index).Project; Option : Name_Id; Dir_Path : constant String := Get_Name_String (Proj.Directory.Name); begin Options := Linker_Opts.Table (Index).Options; while Options /= Nil_String loop Option := In_Tree.String_Elements.Table (Options).Value; Get_Name_String (Option); -- Do not consider empty linker options if Name_Len /= 0 then Add_Linker_Option (Name_Buffer (1 .. Name_Len)); -- Object files and -L switches specified with relative -- paths must be converted to absolute paths. Test_If_Relative_Path (Switch => Linker_Options_Buffer (Last_Linker_Option), Parent => Dir_Path, Including_L_Switch => True); end if; Options := In_Tree.String_Elements.Table (Options).Next; end loop; end; end loop; return Linker_Options_Buffer (1 .. Last_Linker_Option); end Linker_Options_Switches; ----------- -- Mains -- ----------- package body Mains is type File_And_Loc is record File_Name : File_Name_Type; Index : Int := 0; Location : Source_Ptr := No_Location; end record; package Names is new Table.Table (Table_Component_Type => File_And_Loc, Table_Index_Type => Integer, Table_Low_Bound => 1, Table_Initial => 10, Table_Increment => 100, Table_Name => "Makeutl.Mains.Names"); -- The table that stores the mains Current : Natural := 0; -- The index of the last main retrieved from the table -------------- -- Add_Main -- -------------- procedure Add_Main (Name : String) is begin Name_Len := 0; Add_Str_To_Name_Buffer (Name); Names.Increment_Last; Names.Table (Names.Last) := (Name_Find, 0, No_Location); end Add_Main; ------------ -- Delete -- ------------ procedure Delete is begin Names.Set_Last (0); Mains.Reset; end Delete; --------------- -- Get_Index -- --------------- function Get_Index return Int is begin if Current in Names.First .. Names.Last then return Names.Table (Current).Index; else return 0; end if; end Get_Index; ------------------ -- Get_Location -- ------------------ function Get_Location return Source_Ptr is begin if Current in Names.First .. Names.Last then return Names.Table (Current).Location; else return No_Location; end if; end Get_Location; --------------- -- Next_Main -- --------------- function Next_Main return String is begin if Current >= Names.Last then return ""; else Current := Current + 1; return Get_Name_String (Names.Table (Current).File_Name); end if; end Next_Main; --------------------- -- Number_Of_Mains -- --------------------- function Number_Of_Mains return Natural is begin return Names.Last; end Number_Of_Mains; ----------- -- Reset -- ----------- procedure Reset is begin Current := 0; end Reset; --------------- -- Set_Index -- --------------- procedure Set_Index (Index : Int) is begin if Names.Last > 0 then Names.Table (Names.Last).Index := Index; end if; end Set_Index; ------------------ -- Set_Location -- ------------------ procedure Set_Location (Location : Source_Ptr) is begin if Names.Last > 0 then Names.Table (Names.Last).Location := Location; end if; end Set_Location; ----------------- -- Update_Main -- ----------------- procedure Update_Main (Name : String) is begin if Current in Names.First .. Names.Last then Name_Len := 0; Add_Str_To_Name_Buffer (Name); Names.Table (Current).File_Name := Name_Find; end if; end Update_Main; end Mains; ---------- -- Mark -- ---------- procedure Mark (Source_File : File_Name_Type; Index : Int := 0) is begin Marks.Set (K => (File => Source_File, Index => Index), E => True); end Mark; ----------------------- -- Path_Or_File_Name -- ----------------------- function Path_Or_File_Name (Path : Path_Name_Type) return String is Path_Name : constant String := Get_Name_String (Path); begin if Debug.Debug_Flag_F then return File_Name (Path_Name); else return Path_Name; end if; end Path_Or_File_Name; --------------------------- -- Test_If_Relative_Path -- --------------------------- procedure Test_If_Relative_Path (Switch : in out String_Access; Parent : String; Including_L_Switch : Boolean := True; Including_Non_Switch : Boolean := True; Including_RTS : Boolean := False) is begin if Switch /= null then declare Sw : String (1 .. Switch'Length); Start : Positive; begin Sw := Switch.all; if Sw (1) = '-' then if Sw'Length >= 3 and then (Sw (2) = 'A' or else Sw (2) = 'I' or else (Including_L_Switch and then Sw (2) = 'L')) then Start := 3; if Sw = "-I-" then return; end if; elsif Sw'Length >= 4 and then (Sw (2 .. 3) = "aL" or else Sw (2 .. 3) = "aO" or else Sw (2 .. 3) = "aI") then Start := 4; elsif Including_RTS and then Sw'Length >= 7 and then Sw (2 .. 6) = "-RTS=" then Start := 7; else return; end if; -- Because relative path arguments to --RTS= may be relative -- to the search directory prefix, those relative path -- arguments are converted only when they include directory -- information. if not Is_Absolute_Path (Sw (Start .. Sw'Last)) then if Parent'Length = 0 then Do_Fail ("relative search path switches (""" & Sw & """) are not allowed"); elsif Including_RTS then for J in Start .. Sw'Last loop if Sw (J) = Directory_Separator then Switch := new String' (Sw (1 .. Start - 1) & Parent & Directory_Separator & Sw (Start .. Sw'Last)); return; end if; end loop; else Switch := new String' (Sw (1 .. Start - 1) & Parent & Directory_Separator & Sw (Start .. Sw'Last)); end if; end if; elsif Including_Non_Switch then if not Is_Absolute_Path (Sw) then if Parent'Length = 0 then Do_Fail ("relative paths (""" & Sw & """) are not allowed"); else Switch := new String'(Parent & Directory_Separator & Sw); end if; end if; end if; end; end if; end Test_If_Relative_Path; ------------------- -- Unit_Index_Of -- ------------------- function Unit_Index_Of (ALI_File : File_Name_Type) return Int is Start : Natural; Finish : Natural; Result : Int := 0; begin Get_Name_String (ALI_File); -- First, find the last dot Finish := Name_Len; while Finish >= 1 and then Name_Buffer (Finish) /= '.' loop Finish := Finish - 1; end loop; if Finish = 1 then return 0; end if; -- Now check that the dot is preceded by digits Start := Finish; Finish := Finish - 1; while Start >= 1 and then Name_Buffer (Start - 1) in '0' .. '9' loop Start := Start - 1; end loop; -- If there are no digits, or if the digits are not preceded by the -- character that precedes a unit index, this is not the ALI file of -- a unit in a multi-unit source. if Start > Finish or else Start = 1 or else Name_Buffer (Start - 1) /= Multi_Unit_Index_Character then return 0; end if; -- Build the index from the digit(s) while Start <= Finish loop Result := Result * 10 + Character'Pos (Name_Buffer (Start)) - Character'Pos ('0'); Start := Start + 1; end loop; return Result; end Unit_Index_Of; ----------------- -- Verbose_Msg -- ----------------- procedure Verbose_Msg (N1 : Name_Id; S1 : String; N2 : Name_Id := No_Name; S2 : String := ""; Prefix : String := " -> "; Minimum_Verbosity : Opt.Verbosity_Level_Type := Opt.Low) is begin if not Opt.Verbose_Mode or else Minimum_Verbosity > Opt.Verbosity_Level then return; end if; Write_Str (Prefix); Write_Str (""""); Write_Name (N1); Write_Str (""" "); Write_Str (S1); if N2 /= No_Name then Write_Str (" """); Write_Name (N2); Write_Str (""" "); end if; Write_Str (S2); Write_Eol; end Verbose_Msg; procedure Verbose_Msg (N1 : File_Name_Type; S1 : String; N2 : File_Name_Type := No_File; S2 : String := ""; Prefix : String := " -> "; Minimum_Verbosity : Opt.Verbosity_Level_Type := Opt.Low) is begin Verbose_Msg (Name_Id (N1), S1, Name_Id (N2), S2, Prefix, Minimum_Verbosity); end Verbose_Msg; end Makeutl;
with Ada.Integer_Text_IO; -- Copyright 2021 Melwyn Francis Carlo procedure A023 is use Ada.Integer_Text_IO; Abundant_Numbers : array (Integer range 1 .. 10000) of Integer := (others => 0); N : Integer := 1; Count_Val : Integer := 1; J_Max, K, Count_By_2, Proper_Divisors_Sum : Integer; Abundant_Sum_Found : Boolean; begin for I in 2 .. 28123 loop Proper_Divisors_Sum := 0; J_Max := Integer (Float'Floor (Float (I) / 2.0)); for J in 1 .. J_Max loop if (I mod J) = 0 then Proper_Divisors_Sum := Proper_Divisors_Sum + J; end if; end loop; if Proper_Divisors_Sum > I then Abundant_Numbers (Count_Val) := I; Count_Val := Count_Val + 1; end if; Count_By_2 := Integer (Float'Floor (Float (Count_Val) / 2.0)); Abundant_Sum_Found := False; for J in 1 .. Count_By_2 loop K := J; while (Abundant_Numbers (J) + Abundant_Numbers (K)) < I loop K := K + 1; end loop; if (Abundant_Numbers (J) + Abundant_Numbers (K)) = I then Abundant_Sum_Found := True; exit; end if; end loop; if not Abundant_Sum_Found then N := N + I; end if; end loop; Put (N, Width => 0); end A023;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- XML Processor -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2010-2014, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with Ada.Unchecked_Deallocation; with League.IRIs; with League.Strings.Internals; with Matreshka.Internals.Strings.Operations; with Matreshka.Internals.Unicode.Characters.Latin; with Matreshka.Internals.URI_Utilities; with XML.SAX.Simple_Readers.Callbacks; with XML.SAX.Simple_Readers.Scanner.Actions; with XML.SAX.Simple_Readers.Scanner.Tables; package body XML.SAX.Simple_Readers.Scanner is use type Interfaces.Unsigned_32; use Matreshka.Internals.Unicode; use Matreshka.Internals.Unicode.Characters.Latin; use Matreshka.Internals.Utf16; use Matreshka.Internals.XML; use Matreshka.Internals.XML.Base_Scopes; use Matreshka.Internals.XML.Entity_Tables; use XML.SAX.Simple_Readers.Scanner.Tables; procedure Set_Whitespace_Matched (Self : in out Simple_Reader'Class) with Inline => True; -- Sets "whitespace matched" flag. procedure Free is new Ada.Unchecked_Deallocation (XML.SAX.Input_Sources.SAX_Input_Source'Class, XML.SAX.Input_Sources.SAX_Input_Source_Access); --------------------------- -- Enter_Start_Condition -- --------------------------- procedure Enter_Start_Condition (Self : in out Simple_Reader'Class; State : Interfaces.Unsigned_32) is begin Self.Scanner_State.YY_Start_State := State * 2 + 1; end Enter_Start_Condition; -------------- -- Finalize -- -------------- procedure Finalize (Self : in out Simple_Reader'Class) is use type XML.SAX.Input_Sources.SAX_Input_Source_Access; begin -- Unwind entity stack and release all input sources owned by the -- reader. while not Self.Scanner_Stack.Is_Empty loop if Self.Scanner_State.Source /= null then -- Deallocate input source and replacement text data, because -- it was not yet saved in the entities table. Free (Self.Scanner_State.Source); Matreshka.Internals.Strings.Dereference (Self.Scanner_State.Data); end if; Self.Scanner_State := Self.Scanner_Stack.Last_Element; Self.Scanner_Stack.Delete_Last; end loop; -- Release last token, it can be unused by the parser when fatal error -- occured. Clear (Self.YYLVal); -- Release shared string when scanner's stack is empty, because it is -- buffer for document entity. Matreshka.Internals.Strings.Dereference (Self.Scanner_State.Data); end Finalize; ---------------- -- Initialize -- ---------------- procedure Initialize (Self : in out Simple_Reader'Class) is begin Self.Scanner_State.Start_Condition_Stack.Append (Tables.DOCUMENT_10); end Initialize; ------------------------- -- Pop_Start_Condition -- ------------------------- procedure Pop_Start_Condition (Self : in out Simple_Reader'Class) is begin Enter_Start_Condition (Self, Self.Scanner_State.Start_Condition_Stack.Last_Element); Self.Scanner_State.Start_Condition_Stack.Delete_Last; end Pop_Start_Condition; ------------------------------------ -- Push_And_Enter_Start_Condition -- ------------------------------------ procedure Push_And_Enter_Start_Condition (Self : in out Simple_Reader'Class; Push : Interfaces.Unsigned_32; Enter : Interfaces.Unsigned_32) is begin Self.Scanner_State.Start_Condition_Stack.Append (Push); Self.Scanner_State.YY_Start_State := 1 + 2 * Enter; end Push_And_Enter_Start_Condition; -------------------------------------------- -- Push_Current_And_Enter_Start_Condition -- -------------------------------------------- procedure Push_Current_And_Enter_Start_Condition (Self : in out Simple_Reader'Class; Enter : Interfaces.Unsigned_32) is begin Self.Scanner_State.Start_Condition_Stack.Append (Start_Condition (Self)); Self.Scanner_State.YY_Start_State := 1 + 2 * Enter; end Push_Current_And_Enter_Start_Condition; ----------------- -- Push_Entity -- ----------------- function Push_Entity (Self : in out Simple_Reader'Class; Entity : Matreshka.Internals.XML.Entity_Identifier; In_Document_Type : Boolean; In_Literal : Boolean) return Boolean is use type Matreshka.Internals.Strings.Shared_String_Access; use type League.Strings.Universal_String; Source : XML.SAX.Input_Sources.SAX_Input_Source_Access; Text : Matreshka.Internals.Strings.Shared_String_Access; Last_Match : Boolean; Condition : constant Interfaces.Unsigned_32 := Start_Condition (Self); begin -- Resolve entity when necessary. if not Is_Resolved (Self.Entities, Entity) then Callbacks.Call_Resolve_Entity (Self, Entity, Public_Id (Self.Entities, Entity), Enclosing_Base_URI (Self.Entities, Entity), System_Id (Self.Entities, Entity), Source); Text := Matreshka.Internals.Strings.Shared_Empty'Access; Last_Match := False; if not Self.Continue then Self.Error_Message.Prepend ("unable to resolve external entity: "); Callbacks.Call_Fatal_Error (Self, Self.Error_Message); return False; end if; Set_Is_Resolved (Self.Entities, Entity, True); Set_Entity_Base_URI (Self.Entities, Entity, Matreshka.Internals.URI_Utilities.Directory_Name (Source.System_Id)); case Self.Version is when XML_1_0 => Source.Set_Version (League.Strings.To_Universal_String ("1.0")); when XML_1_1 => Source.Set_Version (League.Strings.To_Universal_String ("1.1")); end case; else Source := null; Text := Replacement_Text (Self.Entities, Entity); Last_Match := True; if Text.Unused = 0 then -- Replacement text is empty string, -- [XML 4.4.8] Included as PE -- -- "Just as with external parsed entities, parameter entities need -- only be included if validating. When a parameter-entity -- reference is recognized in the DTD and included, its -- replacement text MUST be enlarged by the attachment of one -- leading and one following space (#x20) character; the intent is -- to constrain the replacement text of parameter entities to -- contain an integral number of grammatical tokens in the DTD. -- This behavior MUST NOT apply to parameter entity references -- within entity values; these are described in 4.4.5 Included in -- Literal." -- -- Set Whitespace_Matched flag, it is used only while processing -- of DTD, so the place where parameter entity declarations are -- allowed. Self.Whitespace_Matched := True; return True; end if; end if; -- [XML 4.4.8] Included as PE -- -- "Just as with external parsed entities, parameter entities need only -- be included if validating. When a parameter-entity reference is -- recognized in the DTD and included, its replacement text MUST be -- enlarged by the attachment of one leading and one following space -- (#x20) character; the intent is to constrain the replacement text of -- parameter entities to contain an integral number of grammatical -- tokens in the DTD. This behavior MUST NOT apply to parameter entity -- references within entity values; these are described in 4.4.5 -- Included in Literal." -- -- Set Whitespace_Matched flag, it is used only while processing of DTD, -- so the place where parameter entity declarations are allowed. Self.Whitespace_Matched := True; Self.Scanner_Stack.Append (Self.Scanner_State); Self.Scanner_State := (Source => Source, Data => Text, Entity => Entity, In_Literal => In_Literal, Delimiter => 0, others => <>); -- Push base URI into the stack. Entity base URI is used for external -- entities; current base URI is used for internal entities. if Entity_Base_URI (Self.Entities, Entity) = Matreshka.Internals.Strings.Shared_Empty'Access then Matreshka.Internals.XML.Base_Scopes.Push_Scope (Self.Bases); else Matreshka.Internals.XML.Base_Scopes.Push_Scope (Self.Bases, League.IRIs.From_Universal_String (League.Strings.Internals.Create (Entity_Base_URI (Self.Entities, Entity)))); end if; if Last_Match then Self.Scanner_State.YY_Current_Position := First_Position (Self.Entities, Entity); Self.Scanner_State.YY_Current_Index := Integer (First_Position (Self.Entities, Entity)) + 1; if In_Document_Type then -- External subset processed after processing of internal subset -- is completed and scanner returns to DOCTYPE_INT start -- condition; but it must be switched back to -- DOCTYPE_INTSUBSET_10 or DOCTYPE_INTSUBSET_11 start condition. case Self.Version is when XML_1_0 => Enter_Start_Condition (Self, DOCTYPE_INTSUBSET_10); when XML_1_1 => Enter_Start_Condition (Self, DOCTYPE_INTSUBSET_11); end case; else if Condition = DOCUMENT_11 and Is_Internal_General_Entity (Self.Entities, Entity) then -- Character references are resolved when replacement text of -- internal general entity is constructed. In XML 1.1 character -- references can refer to restricted characters which is not -- valid in text, but valid in replacement text. Enter_Start_Condition (Self, DOCUMENT_U11); else Enter_Start_Condition (Self, Condition); end if; end if; else -- Reset scanner to INITIAL state to be able to process text -- declaration at the beginning of the external entity. if In_Document_Type then -- External subset processed after processing of internal subset -- is completed and scanner returns to DOCTYPE_INT start -- condition; but it must be switched back to -- DOCTYPE_INTSUBSET_10 or DOCTYPE_INTSUBSET_11 start condition. case Self.Version is when XML_1_0 => Push_And_Enter_Start_Condition (Self, DOCTYPE_INTSUBSET_10, INITIAL); when XML_1_1 => Push_And_Enter_Start_Condition (Self, DOCTYPE_INTSUBSET_11, INITIAL); end case; else Push_And_Enter_Start_Condition (Self, Condition, INITIAL); end if; end if; return True; end Push_Entity; ------------------------------ -- Reset_Whitespace_Matched -- ------------------------------ procedure Reset_Whitespace_Matched (Self : in out Simple_Reader'Class) is begin Self.Whitespace_Matched := False; end Reset_Whitespace_Matched; --------------------------------------- -- Set_Document_Version_And_Encoding -- --------------------------------------- procedure Set_Document_Version_And_Encoding (Self : in out Simple_Reader'Class; Version : XML_Version; Encoding : League.Strings.Universal_String) is Restart : Boolean; Success : Boolean; End_Of_Source : Boolean; begin Pop_Start_Condition (Self); if Self.Version /= Version then -- [XML1.0 2.8] -- -- "Note: When an XML 1.0 processor encounters a document that -- specifies a 1.x version number other than '1.0', it will process -- it as a 1.0 document. This means that an XML 1.0 processor will -- accept 1.x documents provided they do not use any non-1.0 -- features." -- -- [XML1.1 4.3.4] -- -- "Each entity, including the document entity, can be separately -- declared as XML 1.0 or XML 1.1. The version declaration appearing -- in the document entity determines the version of the document as a -- whole. An XML 1.1 document may invoke XML 1.0 external entities, -- so that otherwise duplicated versions of external entities, -- particularly DTD external subsets, need not be maintained. -- However, in such a case the rules of XML 1.1 are applied to the -- entire document." -- -- So, XML version of the document can be declared only once, in the -- XML declaration at the start of the document entity. All other -- occurrences of version declaration in external subset and -- external entities are ignored. This allows to simplify code of -- the version change subprogram. Self.Version := Version; case Self.Version is when XML_1_0 => Enter_Start_Condition (Self, Tables.DOCUMENT_10); when XML_1_1 => Enter_Start_Condition (Self, Tables.DOCUMENT_11); end case; end if; case Self.Version is when XML_1_0 => Self.Scanner_State.Source.Reset (League.Strings.To_Universal_String ("1.0"), Encoding, Restart, Success); when XML_1_1 => Self.Scanner_State.Source.Reset (League.Strings.To_Universal_String ("1.1"), Encoding, Restart, Success); end case; if not Success then Callbacks.Call_Fatal_Error (Self, League.Strings.To_Universal_String ("invalid or unsupported encoding")); elsif Restart then Matreshka.Internals.Strings.Operations.Reset (Self.Scanner_State.Data); Self.Scanner_State.Source.Next (Self.Scanner_State.Data, End_Of_Source); end if; end Set_Document_Version_And_Encoding; ---------------------------- -- Set_Whitespace_Matched -- ---------------------------- procedure Set_Whitespace_Matched (Self : in out Simple_Reader'Class) is begin Self.Whitespace_Matched := True; end Set_Whitespace_Matched; --------------------- -- Start_Condition -- --------------------- function Start_Condition (Self : Simple_Reader'Class) return Interfaces.Unsigned_32 is begin return (Self.Scanner_State.YY_Start_State - 1) / 2; end Start_Condition; ---------------------- -- YY_Move_Backward -- ---------------------- procedure YY_Move_Backward (Self : in out Simple_Reader'Class) is begin Self.Scanner_State.YY_Current_Position := Self.Scanner_State.YY_Current_Position - 1; Self.Scanner_State.YY_Current_Index := Self.Scanner_State.YY_Current_Index - 1; Self.Scanner_State.YY_Current_Column := Self.Scanner_State.YY_Current_Column - 1; end YY_Move_Backward; ------------- -- YY_Text -- ------------- function YY_Text (Self : Simple_Reader'Class; Trim_Left : Natural := 0; Trim_Right : Natural := 0; Trim_Whitespace : Boolean := False) return Matreshka.Internals.Strings.Shared_String_Access is -- Trailing and leading character as well as whitespace characters -- belongs to BMP and don't require expensive UTF-16 decoding. FP : Utf16_String_Index := Self.Scanner_State.YY_Base_Position + Utf16_String_Index (Trim_Left); FI : Positive := Self.Scanner_State.YY_Base_Index + Trim_Left; LP : constant Utf16_String_Index := Self.Scanner_State.YY_Current_Position - Utf16_String_Index (Trim_Right); LI : constant Positive := Self.Scanner_State.YY_Current_Index - Trim_Right; C : Code_Point; begin if Trim_Whitespace then loop C := Code_Point (Self.Scanner_State.Data.Value (FP)); exit when C /= Space and then C /= Character_Tabulation and then C /= Carriage_Return and then C /= Line_Feed; FP := FP + 1; FI := FI + 1; end loop; end if; return Matreshka.Internals.Strings.Operations.Slice (Self.Scanner_State.Data, FP, LP - FP, LI - FI); end YY_Text; ----------- -- YYLex -- ----------- function YYLex (Self : in out Simple_Reader'Class) return Token is use type XML.SAX.Input_Sources.SAX_Input_Source_Access; type YY_End_Of_Buffer_Actions is (YY_Continue_Scan, -- Continue scanning from the current position. -- It is used to continue processing after pop -- up of entity from the scanner's stack. YY_Report_Entity_End, -- Return end of entity mark. YY_Restart_Scan, -- Restart scanning from the base position. YY_Accept_Last_Match, -- Accept last matched action. YY_End_Of_Chunk, -- End of chunk of data is reached. YY_End_Of_Input); -- End of input is reached. YY_Action : Interfaces.Unsigned_32; YY_C : Interfaces.Unsigned_32; YY_Current_State : Interfaces.Unsigned_32; YY_Current_Code : Code_Point; YY_Last_Accepting_Position : Utf16_String_Index; YY_Last_Accepting_Index : Positive; YY_Last_Accepting_State : Interfaces.Unsigned_32; YY_Last_Accepting_Line : Natural; YY_Last_Accepting_Column : Natural; YY_Last_Accepting_Skip_LF : Boolean; YY_Last_Accepting : Boolean; YY_Next_Position : Utf16_String_Index; YY_Next_Index : Positive; YY_Next_Line : Natural; YY_Next_Column : Natural; YY_Next_Skip_LF : Boolean; YY_Last_Match_Position : Utf16_String_Index; YY_Last_Match_Index : Positive; YY_Last_Match_State : Interfaces.Unsigned_32; YY_Last_Match_Line : Natural; YY_Last_Match_Column : Natural; YY_Last_Match_Skip_LF : Boolean; YY_Last_Match : Boolean; YYLVal : YYSType renames Self.YYLVal; YY_Last : Utf16_String_Index; End_Of_Source : Boolean; YY_End_Of_Buffer_Action : YY_End_Of_Buffer_Actions; YY_Position_Offset : Utf16_String_Index; YY_Index_Offset : Natural; YY_Start_Condition : Interfaces.Unsigned_32; Start_Issued : Boolean; function YY_Text_Internal (Trim_Left : Natural := 0; Trim_Right : Natural := 0; Trim_Whitespace : Boolean := False) return Matreshka.Internals.Strings.Shared_String_Access; ---------------------- -- YY_Text_Internal -- ---------------------- function YY_Text_Internal (Trim_Left : Natural := 0; Trim_Right : Natural := 0; Trim_Whitespace : Boolean := False) return Matreshka.Internals.Strings.Shared_String_Access is -- Trailing and leading character as well as whitespace characters -- belongs to BMP and don't require expensive UTF-16 decoding. FP : Utf16_String_Index := Self.Scanner_State.YY_Base_Position + Utf16_String_Index (Trim_Left); FI : Positive := Self.Scanner_State.YY_Base_Index + Trim_Left; LP : constant Utf16_String_Index := Self.Scanner_State.YY_Current_Position - Utf16_String_Index (Trim_Right); LI : constant Positive := Self.Scanner_State.YY_Current_Index - Trim_Right; C : Code_Point; begin if Trim_Whitespace then loop C := Code_Point (Self.Scanner_State.Data.Value (FP)); exit when C /= Space and then C /= Character_Tabulation and then C /= Carriage_Return and then C /= Line_Feed; FP := FP + 1; FI := FI + 1; end loop; end if; return Matreshka.Internals.Strings.Operations.Slice (Self.Scanner_State.Data, FP, LP - FP, LI - FI); end YY_Text_Internal; begin loop -- Loops until end-of-data is reached. Self.Scanner_State.YY_Base_Position := Self.Scanner_State.YY_Current_Position; Self.Scanner_State.YY_Base_Index := Self.Scanner_State.YY_Current_Index; Self.Scanner_State.YY_Base_Line := Self.Scanner_State.YY_Current_Line; Self.Scanner_State.YY_Base_Column := Self.Scanner_State.YY_Current_Column; Self.Scanner_State.YY_Base_Skip_LF := Self.Scanner_State.YY_Current_Skip_LF; YY_Current_State := Self.Scanner_State.YY_Start_State; YY_Last_Match := False; YY_Last_Accepting := False; loop YY_Next_Position := Self.Scanner_State.YY_Current_Position; YY_Next_Index := Self.Scanner_State.YY_Current_Index; YY_Next_Line := Self.Scanner_State.YY_Current_Line; YY_Next_Column := Self.Scanner_State.YY_Current_Column; YY_Next_Skip_LF := Self.Scanner_State.YY_Current_Skip_LF; if YY_Next_Position < Self.Scanner_State.Data.Unused then Unchecked_Next (Self.Scanner_State.Data.Value, YY_Next_Position, YY_Current_Code); YY_Next_Index := YY_Next_Index + 1; -- Track line/column in entity if YY_Current_Code = Carriage_Return then -- Start of new line. YY_Next_Line := YY_Next_Line + 1; YY_Next_Column := 1; YY_Next_Skip_LF := True; elsif YY_Current_Code = Line_Feed then if YY_Next_Skip_LF then -- Ignore CR after LF. YY_Next_Skip_LF := False; else YY_Next_Line := YY_Next_Line + 1; YY_Next_Column := 1; end if; else -- Move to next column. YY_Next_Column := YY_Next_Column + 1; YY_Next_Skip_LF := False; end if; YY_C := YY_EC_Base (YY_Current_Code / 16#100#) (YY_Current_Code mod 16#100#); else -- End of buffer reached. YY_C := 0; -- Aflex uses character with code point zero to mark end of -- buffer character. This character always has YY_EC zero. YY_Last_Match := YY_Last_Accepting; if YY_Last_Accepting then YY_Last_Match_Position := YY_Last_Accepting_Position; YY_Last_Match_Index := YY_Last_Accepting_Index; YY_Last_Match_State := YY_Last_Accepting_State; YY_Last_Match_Line := YY_Last_Accepting_Line; YY_Last_Match_Column := YY_Last_Accepting_Column; YY_Last_Match_Skip_LF := YY_Last_Accepting_Skip_LF; end if; end if; if YY_Accept (YY_Current_State) /= 0 then -- Accepting state reached, save for possible backtrack. YY_Last_Accepting_Position := Self.Scanner_State.YY_Current_Position; YY_Last_Accepting_Index := Self.Scanner_State.YY_Current_Index; YY_Last_Accepting_Line := Self.Scanner_State.YY_Current_Line; YY_Last_Accepting_Column := Self.Scanner_State.YY_Current_Column; YY_Last_Accepting_Skip_LF := Self.Scanner_State.YY_Current_Skip_LF; YY_Last_Accepting_State := YY_Current_State; YY_Last_Accepting := True; end if; while YY_Chk (YY_Base (YY_Current_State) + YY_C) /= YY_Current_State loop YY_Current_State := YY_Def (YY_Current_State); if YY_Current_State >= YY_First_Template then YY_C := YY_Meta (YY_C); end if; end loop; Self.Scanner_State.YY_Current_Position := YY_Next_Position; Self.Scanner_State.YY_Current_Index := YY_Next_Index; Self.Scanner_State.YY_Current_Line := YY_Next_Line; Self.Scanner_State.YY_Current_Column := YY_Next_Column; Self.Scanner_State.YY_Current_Skip_LF := YY_Next_Skip_LF; YY_Current_State := YY_Nxt (YY_Base (YY_Current_State) + YY_C); exit when YY_Base (YY_Current_State) = YY_Jam_Base; end loop; -- Return back to last accepting state. <<Next_Action>> YY_Action := YY_Accept (YY_Current_State); case YY_Action is when 0 => -- must backtrack if YY_Last_Accepting then Self.Scanner_State.YY_Current_Position := YY_Last_Accepting_Position; Self.Scanner_State.YY_Current_Index := YY_Last_Accepting_Index; Self.Scanner_State.YY_Current_Line := YY_Last_Accepting_Line; Self.Scanner_State.YY_Current_Column := YY_Last_Accepting_Column; Self.Scanner_State.YY_Current_Skip_LF := YY_Last_Accepting_Skip_LF; YY_Current_State := YY_Last_Accepting_State; YY_Last_Accepting := False; goto Next_Action; else raise Program_Error; end if; pragma Style_Checks ("M127"); when 1 => -- Open of XML declaration or text declaration, rules [23], [77]. return Actions.On_Open_Of_XML_Or_Text_Declaration (Self); when 2 => -- Any character except literal "<?xml" means there is no XML declaration -- in this document/external parsed entity. Actions.On_No_XML_Declaration (Self); when 3 => -- Open of processing instruction, rule [16]. Rule [17] is implemented -- implicitly by ordering of open of XMLDecl and open of PI. return Actions.On_Open_Of_Processing_Instruction (Self); when 4 => -- Open tag of document type declaration and name of root element, -- rule [28]. return Actions.On_Open_Of_Document_Type_Declaration (Self); when 5 => -- Open of start tag, rule [40], or empty element, rule [44]. return Actions.On_Open_Of_Start_Tag (Self); when 6 => -- Open of end tag, rule [42]. return Actions.On_Open_Of_End_Tag (Self); when 7 => -- Segment of whitespaces. if Actions.On_Whitespace_In_Document (Self) then return Token_String_Segment; end if; when 8 => -- Segment of character data, rule [14]. return Actions.On_Character_Data (Self); when 9 => -- Segment of character data, rule [14]. return Actions.On_Character_Data (Self); when 10 => -- Segment of character data, rule [14]. return Actions.On_Character_Data (Self); when 11 => -- Start of CDATA section, production [19]. return Actions.On_Open_Of_CDATA (Self); when 12 => -- Start of CDATA section, production [19]. return Actions.On_Open_Of_CDATA (Self); when 13 => -- Start of CDATA section, production [19]. return Actions.On_Open_Of_CDATA (Self); when 14 => -- Text data of CDATA section, production [20]. return Actions.On_CDATA (Self); when 15 => -- Text data of CDATA section, production [20]. return Actions.On_CDATA (Self); when 16 => -- Text data of CDATA section, production [20]. return Actions.On_CDATA (Self); when 17 => -- End of CDATA section, production [21]. return Actions.On_Close_Of_CDATA (Self); when 18 => -- End of CDATA section, production [21]. return Actions.On_Close_Of_CDATA (Self); when 19 => -- End of CDATA section, production [21]. return Actions.On_Close_Of_CDATA (Self); when 20 => -- General entity reference rule [68] in document content. declare Aux : constant Token := Actions.On_General_Entity_Reference_In_Document_Content (Self); begin -- By convention, End_Of_Input means that replacement text of the -- referenced entity is empty and it is not pushed into the scanner -- stack. if Aux /= End_Of_Input then return Aux; end if; end; when 21 => -- [24] VersionInfo return Actions.On_Version_Keyword (Self); when 22 => -- [80] EncodingDecl return Actions.On_Encoding_Keyword (Self); when 23 => -- [32] SDDecl return Actions.On_Standalone_Keyword (Self); when 24 => -- Synthetic rule. XMLDECL_ATTRIBUTE_CHAR is a union of characters allowed -- by [26] VersionNum, [81] EncName, [32] SDDecl. Precise check is -- processed while parsing. return Actions.On_Attribute_Value_In_XML_Declaration (Self); when 25 => -- Close of XML declaration (production [23]) or text declaration -- (production [77]). return Actions.On_Close_Of_XML_Or_Text_Declaration (Self); when 26 => -- Close of processing instruction (rule [16]). return Actions.On_Close_Of_Processing_Instruction (Self, True); when 27 => -- Ignore all whitespaces is followed by processing insturction's name, -- rule [16]. Actions.On_Whitespace_In_Processing_Instruction (Self); when 28 => -- Segment of data and close delimiter of the processing instruction, rule -- [16]. return Actions.On_Close_Of_Processing_Instruction (Self, False); when 29 => -- Segment of data and close delimiter of the processing instruction, rule -- [16]. return Actions.On_Close_Of_Processing_Instruction (Self, False); when 30 => -- Keyword SYSTEM, rule [75]. return Actions.On_System_Keyword_In_Document_Type (Self); when 31 => -- System literal, rule [11], used in rule [75]. return Actions.On_System_Literal (Self); when 32 => -- Productions [82], [83] allows absence of system literal in -- notation declaration. Pop_Start_Condition (Self); if Start_Condition (Self) = NOTATION_DECL then Pop_Start_Condition (Self); end if; return Token_Close; when 33 => -- Keyword PUBLIC, rule [75]. Reset_Whitespace_Matched (Self); Push_And_Enter_Start_Condition (Self, DOCTYPE_INT, EXTERNAL_ID_PUB); return Token_Public; when 34 => -- Public id literal, rule [12], used in rule [75]. return Actions.On_Public_Literal (Self); when 35 => -- Open of internal subset declaration, rule [28]. return Actions.On_Open_Of_Internal_Subset (Self); when 36 => -- Close of internal subset declaration, rule [28]. Enter_Start_Condition (Self, DOCTYPE_INT); return Token_Internal_Subset_Close; when 37 => -- Text of comment, rule [15]. Set_String_Internal (Item => YYLVal, String => YY_Text_Internal (4, 3), Is_Whitespace => False); return Token_Comment; when 38 => -- Text of comment, rule [15]. Set_String_Internal (Item => YYLVal, String => YY_Text_Internal (4, 3), Is_Whitespace => False); return Token_Comment; when 39 => -- Parameter entity reference rule [69] in document type declaration. return Actions.On_Parameter_Entity_Reference_In_Document_Declaration (Self); when 40 => -- Open of entity declaration, rules [71], [72]. Enter_Start_Condition (Self, ENTITY_DECL); Reset_Whitespace_Matched (Self); return Token_Entity_Decl_Open; when 41 => -- Open of element declaration and name of the element, rule [45]. return Actions.On_Open_Of_Element_Declaration (Self); when 42 => -- Open of attribute list declaration, rule [52]. return Actions.On_Open_Of_Attribute_List_Declaration (Self); when 43 => -- Open of notation declaration, production [82]. return Actions.On_Open_Of_Notation_Declaration (Self); when 44 => -- Start of conditional section. return Actions.On_Open_Of_Conditional_Section (Self); when 45 => -- Close of conditional section. return Actions.On_Close_Of_Conditional_Section (Self); when 46 => -- Close of notation declaration, production [82]. Pop_Start_Condition (Self); return Token_Close; when 47 => -- Name in entity declaration, rules [71], [72]. return Actions.On_Name_In_Entity_Declaration (Self); when 48 => -- Percent mark in parameter entity declaration, rule [72]. return Actions.On_Percent_Sign (Self); when 49 => -- Entity value, rule [9]. return Actions.On_Entity_Value_Open_Delimiter (Self); when 50 => -- Entity value as ExternalID, rule [75], used by rules [73], [74]. return Actions.On_System_Keyword_In_Entity_Or_Notation (Self); when 51 => -- Entity value as ExternalID, rule [75], used by rules [73], [74]. -- Notation as ExternalID or Public_ID (productions [75], [82], [83]). Reset_Whitespace_Matched (Self); Push_Current_And_Enter_Start_Condition (Self, EXTERNAL_ID_PUB); return Token_Public; when 52 => -- NDATA keyword, rule [76]. return Actions.On_NDATA (Self); when 53 => -- Name of NDATA, rule [76]. return Actions.On_Name_In_Entity_Declaration_Notation (Self); when 54 => Set_String_Internal (Item => YYLVal, String => YY_Text_Internal, Is_Whitespace => False); return Token_String_Segment; when 55 => Set_String_Internal (Item => YYLVal, String => YY_Text_Internal, Is_Whitespace => False); return Token_String_Segment; when 56 => -- Close of entity value, rule [9]. return Actions.On_Entity_Value_Close_Delimiter (Self); when 57 => -- Decimal form of character reference rule [66] in entity value rule [9]; -- or content of element, rule [43]. return Actions.On_Character_Reference (Self, False); when 58 => -- Decimal form of character reference rule [66] in attribute value, -- rule [10]. if not Actions.On_Character_Reference_In_Attribute_Value (Self, False) then return Error; end if; when 59 => -- Hexadecimal form of character reference rule [66] in entity value rule -- [9] or content of element, rule [43]. return Actions.On_Character_Reference (Self, True); when 60 => -- Hexadecimal form of character reference rule [66] in attribute value, -- rule [10]. if not Actions.On_Character_Reference_In_Attribute_Value (Self, True) then return Error; end if; when 61 => -- General entity reference rule [68] in entity value rule [9]. return Actions.On_General_Entity_Reference_In_Entity_Value (Self); when 62 => -- Parameter entity reference rule [69] in entity value rule [9]. -- -- Processing of parameter entity uses separate scanner's state, thus -- after processing current state is restored automatically. This allows -- to reuse code for three modes: parsing of entity value delimited by -- quotation; parsing of entity value delimited by apostrophe; and -- parsing of parameter entity replacement text when it is referenced -- in any of two form of entity value. if not Actions.On_Parameter_Entity_Reference_In_Entity_Value (Self) then return Error; end if; when 63 => -- Name of the element in element declaration. return Actions.On_Name_In_Element_Declaration (Self); when 64 => -- EMPTY keyword, rule [46]. return Token_Empty; when 65 => -- ANY keyword, rule [46]. return Token_Any; when 66 => -- Open parenthesis, rules [49], [50], [51]. return Actions.On_Open_Parenthesis_In_Content_Declaration (Self); when 67 => -- Close parenthesis, rules [49], [50], [51]. return Actions.On_Close_Parenthesis_In_Content_Declaration (Self); when 68 => -- Question mark in rules [47], [48]. return Actions.On_Question_Mark_In_Content_Declaration (Self); when 69 => -- Asterisk in rules [47], [48], [51]. return Actions.On_Asterisk_In_Content_Declaration (Self); when 70 => -- Plus sign in rules [47], [48]. return Actions.On_Plus_In_Content_Declaration (Self); when 71 => -- Vertical bar in rule [49]. return Token_Vertical_Bar; when 72 => -- Comma in rule [50]. return Token_Comma; when 73 => -- #PCDATA in rule [51]. return Token_Pcdata; when 74 => -- Name in element's children declaration, rules [48], [51]. return Actions.On_Name_In_Element_Declaration_Children (Self); when 75 => -- Close token of entity declaration, rules [71], [72]. -- Close of element declaration, rule [45]. -- Close of attribute list declaration, rule [52]. return Actions.On_Close_Of_Declaration (Self); when 76 => -- Element's name in attribute list declaration, rule [52]. return Actions.On_Element_Name_In_Attribute_List_Declaration (Self); when 77 => -- Name of the attribute, rule [53]. return Actions.On_Attribute_Name_In_Attribute_List_Declaration (Self); when 78 => -- CDATA keyword, rule [55]. return Actions.On_Attribute_Type (Self, Token_Cdata); when 79 => -- ID keyword, rule [56]. return Actions.On_Attribute_Type (Self, Token_Id); when 80 => -- IDREF keyword, rule [56]. return Actions.On_Attribute_Type (Self, Token_Idref); when 81 => -- IDREFS keyword, rule [56]. return Actions.On_Attribute_Type (Self, Token_Idrefs); when 82 => -- ENTITY keyword, rule [56]. return Actions.On_Attribute_Type (Self, Token_Entity); when 83 => -- ENTITIES keyword, rule [56]. return Actions.On_Attribute_Type (Self, Token_Entities); when 84 => -- NMTOKEN keyword, rule [56]. return Actions.On_Attribute_Type (Self, Token_Nmtoken); when 85 => -- NMTOKENS keyword, rule [56]. return Actions.On_Attribute_Type (Self, Token_Nmtokens); when 86 => -- NOTATION keyword, rule [58]. return Actions.On_Attribute_Type (Self, Token_Notation); when 87 => -- #REQUIRED keyword, rule [60]. return Actions.On_Default_Declaration (Self, ATTLIST_DECL, Token_Required); when 88 => -- #IMPLIED keyword, rule [60]. return Actions.On_Default_Declaration (Self, ATTLIST_DECL, Token_Implied); when 89 => -- #FIXED keyword, rule [60]. return Actions.On_Default_Declaration (Self, ATTLIST_TYPE, Token_Fixed); when 90 => -- Open parenthesis, rules [58], [59]. return Actions.On_Open_Parenthesis_In_Notation_Attribute (Self); when 91 => -- Close parenthesis, rules [58], [59]. return Actions.On_Close_Parenthesis_In_Notation_Attribute (Self); when 92 => -- Vertical bar, rules [58], [59]. return Token_Vertical_Bar; when 93 => -- Name in the rule [58]. return Actions.On_Name_In_Attribute_List_Declaration_Notation (Self); when 94 => -- Nmtoken in the rule [59]. Set_String_Internal (Item => YYLVal, String => YY_Text_Internal, Is_Whitespace => False); -- XXX Need to add flag to mark Nmtoken. return Token_Name; when 95 => -- Open delimiter of attribute value, rule [10]. if not Actions.On_Attribute_Value_Open_Delimiter (Self, ATTLIST_DECL) then return Error; end if; when 96 => -- Parameter entity reference rule [69] in attribute declaration. -- Parameter entity reference in element's children declaration, [51]. if not Actions.On_Parameter_Entity_Reference_In_Markup_Declaration (Self) then return Error; end if; when 97 => -- All white spaces from rules [28] are ignored. -- Whitespace before name in rule [76] is ignored. null; when 98 => -- IGNORE directive of the conditional section. Actions.On_Conditional_Section_Directive (Self, False); when 99 => -- INCLUDE directive of the conditional section. Actions.On_Conditional_Section_Directive (Self, True); when 100 => -- Start of content of conditional section. if not Actions.On_Open_Of_Conditional_Section_Content (Self) then return Error; end if; when 101 => -- Content of ignore conditional section. It ends with "]]>" or "<![". null; when 102 => -- Content of ignore conditional section. It ends with "]]>" or "<![". null; when 103 => -- White spaces in entity declaration are not optional, rules [71], [72], -- [75], [76]. -- -- White spaces in start tag, rule [40], are ignored, but white space -- between attribute value and name of the next attribute are must be -- present. -- -- All white spaces from rules [23], [24], [25], [32], [80], [82] are -- ignored, but white space between attribute value and name of the -- next attribute are must be present. -- -- Production [45] requires whitespace after the name and before -- content specification. -- -- Productions [47], [48] don't allow spaces before multiplicity -- indicator. Set_Whitespace_Matched (Self); when 104 => -- Name of the attribute, rule [41]. return Actions.On_Name_In_Element_Start_Tag (Self); when 105 => -- Equal sign as attribute's name value delimiter, rule [25] in rules [41], -- [24], [32], [80]. return Token_Equal; when 106 => -- Close of empty element tag, rule [44]. return Actions.On_Close_Of_Empty_Element_Tag (Self); when 107 => -- Close tag of document type declaration, rule [28]. if Actions.On_Close_Of_Document_Type_Declaration (Self) then return Token_Close; end if; when 108 => -- Close of tag, rule [40]. -- Close tag of document type declaration, rule [28]. return Actions.On_Close_Of_Tag (Self); when 109 => -- Open delimiter of attribute value, rule [10]. Actions.On_Attribute_Value_Open_Delimiter (Self, ELEMENT_START); when 110 => -- Close delimiter of attribute value, rule [10]. if Actions.On_Attribute_Value_Close_Delimiter (Self) then return Token_String_Segment; end if; when 111 => -- Value of attribute, rule [10]. Actions.On_Attribute_Value_Character_Data (Self); when 112 => -- Value of attribute, rule [10]. Actions.On_Attribute_Value_Character_Data (Self); when 113 => -- Less-than sign can't be used in the attribute value. return Actions.On_Less_Than_Sign_In_Attribute_Value (Self); when 114 => -- General entity reference rule [68] in attribute value, rule [10]. if not Actions.On_General_Entity_Reference_In_Attribute_Value (Self) then return Error; end if; when 115 => -- Unexpected character. return Actions.On_Unexpected_Character (Self); pragma Style_Checks ("M79"); -- when YY_END_OF_BUFFER + INITIAL + 1 -- => -- return End_Of_Input; -- when YY_End_Of_Buffer => if Self.Scanner_State.Source /= null then -- Input source is used to retrieve data. if Is_Document_Entity (Self.Entities, Self.Scanner_State.Entity) and Self.Scanner_State.YY_Base_Position /= 0 then -- For document entity, remove already scanned data. -- Construct slice only when we actually need to move -- data. Matreshka.Internals.Strings.Operations.Slice (Self.Scanner_State.Data, Self.Scanner_State.YY_Base_Position, Self.Scanner_State.Data.Unused - Self.Scanner_State.YY_Base_Position, Self.Scanner_State.Data.Length - Self.Scanner_State.YY_Base_Index + 1); YY_Position_Offset := Self.Scanner_State.YY_Base_Position; YY_Index_Offset := Self.Scanner_State.YY_Base_Index - 1; Self.Scanner_State.YY_Base_Position := Self.Scanner_State.YY_Base_Position - YY_Position_Offset; Self.Scanner_State.YY_Base_Index := Self.Scanner_State.YY_Base_Index - YY_Index_Offset; Self.Scanner_State.YY_Current_Position := Self.Scanner_State.YY_Current_Position - YY_Position_Offset; Self.Scanner_State.YY_Current_Index := Self.Scanner_State.YY_Current_Index - YY_Index_Offset; if YY_Last_Match then YY_Last_Match_Position := YY_Last_Match_Position - YY_Position_Offset; YY_Last_Match_Index := YY_Last_Match_Index - YY_Index_Offset; end if; end if; -- Obtain next portion of data from the input source. YY_Last := Self.Scanner_State.Data.Unused; Self.Scanner_State.Source.Next (Self.Scanner_State.Data, End_Of_Source); YY_End_Of_Buffer_Action := YY_Restart_Scan; if YY_Last = Self.Scanner_State.Data.Unused then -- There is no new data retrieved, handle end of source -- state. It is possible to not reach end of source and -- retrieve no new data at the same time, for example -- when source data is mailformed and decoder unable to -- convert data. The same situtation is possible when -- some kind of filter is inserted between input source -- and actual stream (SSL/TLS encription, for example). if End_Of_Source then -- Replacement text of the entity is loaded from input -- source and need to be stored in the entities table, -- except replacement text of the document entity. -- Input source can be deallocated. if not Is_Document_Entity (Self.Entities, Self.Scanner_State.Entity) then Set_Replacement_Text (Self.Entities, Self.Scanner_State.Entity, Self.Scanner_State.Data); Free (Self.Scanner_State.Source); -- XXX Input source should not be deallocated, it -- can be needed later to reread entity when XML -- version (document entity only) or encoding is -- changed. else Self.Scanner_State.Source := null; -- Input source of document entity is managed by -- application. end if; elsif Self.Scanner_State.Incremental then YY_End_Of_Buffer_Action := YY_End_Of_Chunk; end if; end if; else -- Input source is not used, complete replacement text of -- the entity is in the scanner's buffer. This covers two -- cases: (1) entity is internal or predefined entity, and -- (2) text of the entity is loaded completely. if Self.Scanner_State.Data.Unused /= Self.Scanner_State.YY_Base_Position then -- Continue processing till end of buffer will be -- reached. YY_End_Of_Buffer_Action := YY_Accept_Last_Match; else -- Replacement text of the entity is completely scanned, -- pop scanner's entity stack. When scanner's stack is -- empty returns End_Of_Input token. if not Self.Scanner_Stack.Is_Empty then if Is_Parameter_Entity (Self.Entities, Self.Scanner_State.Entity) then -- For parameter entities start condition need to -- be propagated to previous state, otherwise -- scanner can start from the wrong condition. -- For non-parameter entities it is not needed, -- because their processing doesn't use stack of -- start conditions. YY_Start_Condition := Start_Condition (Self); -- Save flag whether or not Token_Entity_Start was -- issued. Start_Issued := Self.Scanner_State.Start_Issued; -- When entity's replacement text is empty and -- there are no text declaration, then scanner is -- in the initial state and actual state must be -- retrieved from the state stack. if YY_Start_Condition = INITIAL then Pop_Start_Condition (Self); YY_Start_Condition := Start_Condition (Self); end if; Free (Self.Scanner_State.Source); Self.Scanner_State := Self.Scanner_Stack.Last_Element; Self.Scanner_Stack.Delete_Last; Pop_Scope (Self.Bases); Enter_Start_Condition (Self, YY_Start_Condition); -- [XML 4.4.8] Included as PE -- -- "Just as with external parsed entities, -- parameter entities need only be included if -- validating. When a parameter-entity reference is -- recognized in the DTD and included, its -- replacement text MUST be enlarged by the -- attachment of one leading and one following -- space (#x20) character; the intent is to -- constrain the replacement text of parameter -- entities to contain an integral number of -- grammatical tokens in the DTD. This behavior -- MUST NOT apply to parameter entity references -- within entity values; these are described in -- 4.4.5 Included in Literal." -- -- Set Whitespace_Matched flag, it is used only -- while processing of DTD, so the place where -- parameter entity declarations are allowed. Self.Whitespace_Matched := True; -- [XML WFC: PE Between Declarations] -- -- "The replacement text of a parameter entity -- reference in a DeclSep MUST match the production -- extSubsetDecl." -- -- To check this constraint special rule is added -- in parser. To pass this rule Token_Entity_End -- must be returned when handling of parameter -- entity reference between markup declaration is -- completed. if Start_Issued then YY_End_Of_Buffer_Action := YY_Report_Entity_End; else YY_End_Of_Buffer_Action := YY_Continue_Scan; end if; elsif Self.In_Document_Content and not Self.Scanner_State.In_Literal then -- For entity references in the document content -- we need to track start/end of entity. Free (Self.Scanner_State.Source); Self.Scanner_State := Self.Scanner_Stack.Last_Element; Self.Scanner_Stack.Delete_Last; Pop_Scope (Self.Bases); YY_End_Of_Buffer_Action := YY_Report_Entity_End; else Free (Self.Scanner_State.Source); Self.Scanner_State := Self.Scanner_Stack.Last_Element; Self.Scanner_Stack.Delete_Last; Pop_Scope (Self.Bases); YY_End_Of_Buffer_Action := YY_Continue_Scan; end if; else YY_End_Of_Buffer_Action := YY_End_Of_Input; end if; end if; end if; case YY_End_Of_Buffer_Action is when YY_Continue_Scan => null; when YY_Report_Entity_End => return Token_Entity_End; when YY_Restart_Scan | YY_End_Of_Chunk => -- Back current position to base position. Self.Scanner_State.YY_Current_Position := Self.Scanner_State.YY_Base_Position; Self.Scanner_State.YY_Current_Index := Self.Scanner_State.YY_Base_Index; Self.Scanner_State.YY_Current_Line := Self.Scanner_State.YY_Base_Line; Self.Scanner_State.YY_Current_Column := Self.Scanner_State.YY_Base_Column; Self.Scanner_State.YY_Current_Skip_LF := Self.Scanner_State.YY_Base_Skip_LF; if YY_End_Of_Buffer_Action = YY_End_Of_Chunk then return End_Of_Chunk; end if; when YY_Accept_Last_Match => -- Replace current position to last matched position and -- process matched action. -- XXX: Other cases handle line/column numbers and -- "skip LF" flag also, should they be handled here? if YY_Last_Match then Self.Scanner_State.YY_Current_Position := YY_Last_Match_Position; Self.Scanner_State.YY_Current_Index := YY_Last_Match_Index; Self.Scanner_State.YY_Current_Line := YY_Last_Match_Line; Self.Scanner_State.YY_Current_Column := YY_Last_Match_Column; Self.Scanner_State.YY_Current_Skip_LF := YY_Last_Match_Skip_LF; YY_Current_State := YY_Last_Match_State; YY_Last_Match := False; else raise Program_Error; end if; goto Next_Action; when YY_End_Of_Input => return End_Of_Input; end case; when others => raise Program_Error with "Unhandled action" & Interfaces.Unsigned_32'Image (YY_Action) & " in scanner"; end case; end loop; -- end of loop waiting for end of file end YYLex; end XML.SAX.Simple_Readers.Scanner;
----------------------------------------------------------------------- -- keystore-files -- Ada keystore files -- Copyright (C) 2019, 2020 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Log.Loggers; with Keystore.IO.Refs; with Keystore.IO.Files; package body Keystore.Files is Log : constant Util.Log.Loggers.Logger := Util.Log.Loggers.Create ("Keystore.Files"); -- ------------------------------ -- Open the keystore file using the given password. -- Raises the Bad_Password exception if no key slot match the password. -- ------------------------------ procedure Open (Container : in out Wallet_File; Password : in Secret_Key; Path : in String; Data_Path : in String := ""; Config : in Wallet_Config := Secure_Config) is procedure Process (Provider : in out Keystore.Passwords.Provider'Class); procedure Process (Provider : in out Keystore.Passwords.Provider'Class) is Slot : Key_Slot; begin Container.Container.Unlock (Provider, Slot); end Process; Info : Wallet_Info; begin Container.Open (Path, Data_Path, Config, Info); Keystore.Passwords.To_Provider (Password, Process'Access); Log.Info ("Keystore {0} is opened", Path); end Open; -- ------------------------------ -- Open the keystore file without unlocking the wallet but get some information -- from the header section. -- ------------------------------ procedure Open (Container : in out Wallet_File; Path : in String; Data_Path : in String := ""; Config : in Wallet_Config := Secure_Config; Info : out Wallet_Info) is use IO.Files; Block : IO.Storage_Block; Wallet_Stream : IO.Files.Wallet_Stream_Access; Stream : IO.Refs.Stream_Ref; begin Log.Debug ("Open keystore {0}", Path); Block.Storage := IO.DEFAULT_STORAGE_ID; Block.Block := 1; Wallet_Stream := new IO.Files.Wallet_Stream; Stream := IO.Refs.Create (Wallet_Stream.all'Access); Wallet_Stream.Open (Path, Data_Path); Container.Container.Open (Config, 1, Block, Stream); Info := Wallet_Stream.Get_Info; Log.Info ("Keystore {0} is opened", Path); end Open; -- ------------------------------ -- Create the keystore file and protect it with the given password. -- The key slot #1 is used. -- ------------------------------ procedure Create (Container : in out Wallet_File; Password : in Secret_Key; Path : in String; Data_Path : in String := ""; Config : in Wallet_Config := Secure_Config) is procedure Process (Provider : in out Keystore.Passwords.Provider'Class); procedure Process (Provider : in out Keystore.Passwords.Provider'Class) is begin Container.Create (Provider, Path, Data_Path, Config); end Process; begin Keystore.Passwords.To_Provider (Password, Process'Access); end Create; procedure Create (Container : in out Wallet_File; Password : in out Keystore.Passwords.Provider'Class; Path : in String; Data_Path : in String := ""; Config : in Wallet_Config := Secure_Config) is Block : IO.Storage_Block; Wallet_Stream : IO.Files.Wallet_Stream_Access; Stream : IO.Refs.Stream_Ref; begin Log.Debug ("Create keystore {0}", Path); Wallet_Stream := new IO.Files.Wallet_Stream; Stream := IO.Refs.Create (Wallet_Stream.all'Access); Block.Storage := IO.DEFAULT_STORAGE_ID; Block.Block := 1; Wallet_Stream.Create (Path, Data_Path, Config); Wallet_Stream.Allocate (IO.MASTER_BLOCK, Block); Container.Container.Create (Password, Config, Block, 1, Stream); end Create; -- ------------------------------ -- Set the keystore master key before creating or opening the keystore. -- ------------------------------ procedure Set_Master_Key (Container : in out Wallet_File; Password : in out Keystore.Passwords.Keys.Key_Provider'Class) is begin Container.Container.Set_Master_Key (Password); end Set_Master_Key; -- ------------------------------ -- Unlock the wallet with the password. -- Raises the Bad_Password exception if no key slot match the password. -- ------------------------------ procedure Unlock (Container : in out Wallet_File; Password : in Secret_Key) is procedure Process (Provider : in out Keystore.Passwords.Provider'Class); procedure Process (Provider : in out Keystore.Passwords.Provider'Class) is Slot : Key_Slot; begin Container.Container.Unlock (Provider, Slot); end Process; begin Keystore.Passwords.To_Provider (Password, Process'Access); end Unlock; procedure Unlock (Container : in out Wallet_File; Password : in out Keystore.Passwords.Provider'Class; Slot : out Key_Slot) is begin Container.Container.Unlock (Password, Slot); end Unlock; -- ------------------------------ -- Close the keystore file. -- ------------------------------ procedure Close (Container : in out Wallet_File) is begin Container.Container.Close; end Close; -- ------------------------------ -- Set some header data in the keystore file. -- ------------------------------ procedure Set_Header_Data (Container : in out Wallet_File; Index : in Header_Slot_Index_Type; Kind : in Header_Slot_Type; Data : in Ada.Streams.Stream_Element_Array) is begin Container.Container.Set_Header_Data (Index, Kind, Data); end Set_Header_Data; -- ------------------------------ -- Get the header data information from the keystore file. -- ------------------------------ procedure Get_Header_Data (Container : in out Wallet_File; Index : in Header_Slot_Index_Type; Kind : out Header_Slot_Type; Data : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset) is begin Container.Container.Get_Header_Data (Index, Kind, Data, Last); end Get_Header_Data; -- Add in the wallet the named entry and associate it the children wallet. -- The children wallet meta data is protected by the container. -- The children wallet has its own key to protect the named entries it manages. procedure Add (Container : in out Wallet_File; Name : in String; Password : in out Keystore.Passwords.Provider'Class; Wallet : in out Wallet_File'Class) is begin null; Keystore.Containers.Add_Wallet (Container.Container, Name, Password, Wallet.Container); end Add; procedure Add (Container : in out Wallet_File; Name : in String; Password : in Keystore.Secret_Key; Wallet : in out Wallet_File'Class) is procedure Process (Provider : in out Keystore.Passwords.Provider'Class); procedure Process (Provider : in out Keystore.Passwords.Provider'Class) is begin Container.Add (Name, Provider, Wallet); end Process; begin Keystore.Passwords.To_Provider (Password, Process'Access); end Add; -- Load from the container the named children wallet. procedure Open (Container : in out Wallet_File; Name : in String; Password : in out Keystore.Passwords.Provider'Class; Wallet : in out Wallet_File'Class) is begin Keystore.Containers.Open_Wallet (Container.Container, Name, Password, Wallet.Container); end Open; procedure Open (Container : in out Wallet_File; Name : in String; Password : in Keystore.Secret_Key; Wallet : in out Wallet_File'Class) is procedure Process (Provider : in out Keystore.Passwords.Provider'Class); procedure Process (Provider : in out Keystore.Passwords.Provider'Class) is begin Container.Open (Name, Provider, Wallet); end Process; begin Keystore.Passwords.To_Provider (Password, Process'Access); end Open; -- ------------------------------ -- Return True if the container was configured. -- ------------------------------ overriding function Is_Configured (Container : in Wallet_File) return Boolean is begin return Container.Container.Get_State = S_PROTECTED; end Is_Configured; -- ------------------------------ -- Return True if the container can be accessed. -- ------------------------------ overriding function Is_Open (Container : in Wallet_File) return Boolean is begin return Container.Container.Get_State = S_OPEN; end Is_Open; -- ------------------------------ -- Get the wallet state. -- ------------------------------ overriding function State (Container : in Wallet_File) return State_Type is begin return Container.Container.Get_State; end State; -- ------------------------------ -- Set the key to encrypt and decrypt the container meta data. -- ------------------------------ overriding procedure Set_Key (Container : in out Wallet_File; Password : in Secret_Key; New_Password : in Secret_Key; Config : in Wallet_Config; Mode : in Mode_Type) is procedure Process (Provider : in out Keystore.Passwords.Provider'Class); procedure Process (Provider : in out Keystore.Passwords.Provider'Class) is procedure Process_New (New_Provider : in out Keystore.Passwords.Provider'Class); procedure Process_New (New_Provider : in out Keystore.Passwords.Provider'Class) is begin Container.Container.Set_Key (Provider, New_Provider, Config, Mode); end Process_New; begin Keystore.Passwords.To_Provider (New_Password, Process_New'Access); end Process; begin Keystore.Passwords.To_Provider (Password, Process'Access); end Set_Key; procedure Set_Key (Container : in out Wallet_File; Password : in out Keystore.Passwords.Provider'Class; New_Password : in out Keystore.Passwords.Provider'Class; Config : in Wallet_Config := Secure_Config; Mode : in Mode_Type := KEY_REPLACE) is begin Container.Container.Set_Key (Password, New_Password, Config, Mode); end Set_Key; -- ------------------------------ -- Remove the key from the key slot identified by `Slot`. The password is necessary to -- make sure a valid password is available. The `Remove_Current` must be set to remove -- the slot when it corresponds to the used password. -- ------------------------------ procedure Remove_Key (Container : in out Wallet_File; Password : in out Keystore.Passwords.Provider'Class; Slot : in Key_Slot; Force : in Boolean) is begin Container.Container.Remove_Key (Password, Slot, Force); end Remove_Key; -- ------------------------------ -- Return True if the container contains the given named entry. -- ------------------------------ overriding function Contains (Container : in Wallet_File; Name : in String) return Boolean is begin return Container.Container.Contains (Name); end Contains; -- ------------------------------ -- Add in the wallet the named entry and associate it the content. -- The content is encrypted in AES-CBC with a secret key and an IV vector -- that is created randomly for the new named entry. -- ------------------------------ overriding procedure Add (Container : in out Wallet_File; Name : in String; Kind : in Entry_Type := T_BINARY; Content : in Ada.Streams.Stream_Element_Array) is begin Container.Container.Add (Name, Kind, Content); end Add; overriding procedure Add (Container : in out Wallet_File; Name : in String; Kind : in Entry_Type := T_BINARY; Input : in out Util.Streams.Input_Stream'Class) is begin Container.Container.Add (Name, Kind, Input); end Add; -- ------------------------------ -- Add or update in the wallet the named entry and associate it the content. -- The content is encrypted in AES-CBC with a secret key and an IV vector -- that is created randomly for the new or updated named entry. -- ------------------------------ overriding procedure Set (Container : in out Wallet_File; Name : in String; Kind : in Entry_Type := T_BINARY; Content : in Ada.Streams.Stream_Element_Array) is begin Container.Container.Set (Name, Kind, Content); end Set; -- ------------------------------ -- Add or update in the wallet the named entry and associate it the content. -- The content is encrypted in AES-CBC with a secret key and an IV vector -- that is created randomly for the new or updated named entry. -- ------------------------------ overriding procedure Set (Container : in out Wallet_File; Name : in String; Kind : in Entry_Type := T_BINARY; Input : in out Util.Streams.Input_Stream'Class) is begin Container.Container.Set (Name, Kind, Input); end Set; -- ------------------------------ -- Update in the wallet the named entry and associate it the new content. -- The secret key and IV vectors are not changed. -- ------------------------------ procedure Update (Container : in out Wallet_File; Name : in String; Kind : in Entry_Type := T_BINARY; Content : in Ada.Streams.Stream_Element_Array) is begin Container.Container.Update (Name, Kind, Content); end Update; -- ------------------------------ -- Read from the wallet the named entry starting at the given position. -- Upon successful completion, Last will indicate the last valid position of -- the Content array. -- ------------------------------ overriding procedure Read (Container : in out Wallet_File; Name : in String; Offset : in Ada.Streams.Stream_Element_Offset; Content : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset) is begin Container.Container.Read (Name, Offset, Content, Last); end Read; -- ------------------------------ -- Write in the wallet the named entry starting at the given position. -- The existing content is overwritten or new content is appended. -- ------------------------------ overriding procedure Write (Container : in out Wallet_File; Name : in String; Offset : in Ada.Streams.Stream_Element_Offset; Content : in Ada.Streams.Stream_Element_Array) is begin Container.Container.Write (Name, Offset, Content); end Write; -- ------------------------------ -- Delete from the wallet the named entry. -- ------------------------------ overriding procedure Delete (Container : in out Wallet_File; Name : in String) is begin Container.Container.Delete (Name); end Delete; overriding procedure Get (Container : in out Wallet_File; Name : in String; Info : out Entry_Info; Content : out Ada.Streams.Stream_Element_Array) is begin Container.Container.Get_Data (Name, Info, Content); end Get; -- ------------------------------ -- Write in the output stream the named entry value from the wallet. -- ------------------------------ overriding procedure Get (Container : in out Wallet_File; Name : in String; Output : in out Util.Streams.Output_Stream'Class) is begin Container.Container.Get_Data (Name, Output); end Get; -- ------------------------------ -- Get the list of entries contained in the wallet that correspond to the optional filter. -- ------------------------------ overriding procedure List (Container : in out Wallet_File; Filter : in Filter_Type := (others => True); Content : out Entry_Map) is begin Container.Container.List (Filter, Content); end List; -- ------------------------------ -- Get the list of entries contained in the wallet that correspond to the optiona filter -- and whose name matches the pattern. -- ------------------------------ procedure List (Container : in out Wallet_File; Pattern : in GNAT.Regpat.Pattern_Matcher; Filter : in Filter_Type := (others => True); Content : out Entry_Map) is begin Container.Container.List (Pattern, Filter, Content); end List; overriding function Find (Container : in out Wallet_File; Name : in String) return Entry_Info is Result : Entry_Info; begin Container.Container.Find (Name, Result); return Result; end Find; -- ------------------------------ -- Get wallet file information and statistics. -- ------------------------------ procedure Get_Stats (Container : in out Wallet_File; Stats : out Wallet_Stats) is begin Container.Container.Get_Stats (Stats); end Get_Stats; procedure Set_Work_Manager (Container : in out Wallet_File; Workers : in Keystore.Task_Manager_Access) is begin Container.Container.Set_Work_Manager (Workers); end Set_Work_Manager; overriding procedure Initialize (Wallet : in out Wallet_File) is begin Wallet.Container.Initialize; end Initialize; overriding procedure Finalize (Wallet : in out Wallet_File) is begin if Wallet.Is_Open then Wallet.Container.Close; end if; end Finalize; end Keystore.Files;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- G N A T . S O C K E T S . C O N S T A N T S -- -- -- -- S p e c -- -- -- -- Copyright (C) 2000-2005, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- -- Boston, MA 02110-1301, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package provides target dependent definitions of constant for use -- by the GNAT.Sockets package (g-socket.ads). This package should not be -- directly with'ed by an applications program. -- This is the version for powerpc-wrs-vxworks -- This file is generated automatically, do not modify it by hand! Instead, -- make changes to gen-soccon.c and re-run it on each target. package GNAT.Sockets.Constants is -------------- -- Families -- -------------- AF_INET : constant := 2; -- IPv4 address family AF_INET6 : constant := -1; -- IPv6 address family ----------- -- Modes -- ----------- SOCK_STREAM : constant := 1; -- Stream socket SOCK_DGRAM : constant := 2; -- Datagram socket ------------------- -- Socket errors -- ------------------- EACCES : constant := 13; -- Permission denied EADDRINUSE : constant := 48; -- Address already in use EADDRNOTAVAIL : constant := 49; -- Cannot assign address EAFNOSUPPORT : constant := 47; -- Addr family not supported EALREADY : constant := 69; -- Operation in progress EBADF : constant := 9; -- Bad file descriptor ECONNABORTED : constant := 53; -- Connection aborted ECONNREFUSED : constant := 61; -- Connection refused ECONNRESET : constant := 54; -- Connection reset by peer EDESTADDRREQ : constant := 40; -- Destination addr required EFAULT : constant := 14; -- Bad address EHOSTDOWN : constant := 67; -- Host is down EHOSTUNREACH : constant := 65; -- No route to host EINPROGRESS : constant := 68; -- Operation now in progress EINTR : constant := 4; -- Interrupted system call EINVAL : constant := 22; -- Invalid argument EIO : constant := 5; -- Input output error EISCONN : constant := 56; -- Socket already connected ELOOP : constant := 64; -- Too many symbolic lynks EMFILE : constant := 24; -- Too many open files EMSGSIZE : constant := 36; -- Message too long ENAMETOOLONG : constant := 26; -- Name too long ENETDOWN : constant := 62; -- Network is down ENETRESET : constant := 52; -- Disconn. on network reset ENETUNREACH : constant := 51; -- Network is unreachable ENOBUFS : constant := 55; -- No buffer space available ENOPROTOOPT : constant := 42; -- Protocol not available ENOTCONN : constant := 57; -- Socket not connected ENOTSOCK : constant := 50; -- Operation on non socket EOPNOTSUPP : constant := 45; -- Operation not supported EPFNOSUPPORT : constant := 46; -- Unknown protocol family EPROTONOSUPPORT : constant := 43; -- Unknown protocol EPROTOTYPE : constant := 41; -- Unknown protocol type ESHUTDOWN : constant := 58; -- Cannot send once shutdown ESOCKTNOSUPPORT : constant := 44; -- Socket type not supported ETIMEDOUT : constant := 60; -- Connection timed out ETOOMANYREFS : constant := 59; -- Too many references EWOULDBLOCK : constant := 70; -- Operation would block ----------------- -- Host errors -- ----------------- HOST_NOT_FOUND : constant := 1; -- Unknown host TRY_AGAIN : constant := 2; -- Host name lookup failure NO_DATA : constant := 4; -- No data record for name NO_RECOVERY : constant := 3; -- Non recoverable errors ------------------- -- Control flags -- ------------------- FIONBIO : constant := 16; -- Set/clear non-blocking io FIONREAD : constant := 1; -- How many bytes to read -------------------- -- Shutdown modes -- -------------------- SHUT_RD : constant := 0; -- No more recv SHUT_WR : constant := 1; -- No more send SHUT_RDWR : constant := 2; -- No more recv/send --------------------- -- Protocol levels -- --------------------- SOL_SOCKET : constant := 65535; -- Options for socket level IPPROTO_IP : constant := 0; -- Dummy protocol for IP IPPROTO_UDP : constant := 17; -- UDP IPPROTO_TCP : constant := 6; -- TCP ------------------- -- Request flags -- ------------------- MSG_OOB : constant := 1; -- Process out-of-band data MSG_PEEK : constant := 2; -- Peek at incoming data MSG_EOR : constant := 8; -- Send end of record MSG_WAITALL : constant := 64; -- Wait for full reception MSG_NOSIGNAL : constant := -1; -- No SIGPIPE on send MSG_Forced_Flags : constant := 0; -- Flags set on all send(2) calls -------------------- -- Socket options -- -------------------- TCP_NODELAY : constant := 1; -- Do not coalesce packets SO_REUSEADDR : constant := 4; -- Bind reuse local address SO_KEEPALIVE : constant := 8; -- Enable keep-alive msgs SO_LINGER : constant := 128; -- Defer close to flush data SO_BROADCAST : constant := 32; -- Can send broadcast msgs SO_SNDBUF : constant := 4097; -- Set/get send buffer size SO_RCVBUF : constant := 4098; -- Set/get recv buffer size SO_SNDTIMEO : constant := 4101; -- Emission timeout SO_RCVTIMEO : constant := 4102; -- Reception timeout SO_ERROR : constant := 4103; -- Get/clear error status IP_MULTICAST_IF : constant := 9; -- Set/get mcast interface IP_MULTICAST_TTL : constant := 10; -- Set/get multicast TTL IP_MULTICAST_LOOP : constant := 11; -- Set/get mcast loopback IP_ADD_MEMBERSHIP : constant := 12; -- Join a multicast group IP_DROP_MEMBERSHIP : constant := 13; -- Leave a multicast group ------------------- -- System limits -- ------------------- IOV_MAX : constant := 2147483647; -- Maximum writev iovcnt ---------------------- -- Type definitions -- ---------------------- -- Sizes (in bytes) of the components of struct timeval SIZEOF_tv_sec : constant := 4; -- tv_sec SIZEOF_tv_usec : constant := 4; -- tv_usec -------------------------------- -- VxWorks-specific constants -- -------------------------------- -- These constants may be used only within the VxWorks version of -- GNAT.Sockets.Thin. OK : constant := 0; -- VxWorks generic success ERROR : constant := -1; -- VxWorks generic error end GNAT.Sockets.Constants;
pragma Ada_2012; package body AdaCar.Parametros is --------------------------- -- Convertidor_Distancia -- --------------------------- function Convertidor_Distancia (Valor : Unidades_AI) return Unidades_Distancia is begin return Valor*Factor_Distancia; end Convertidor_Distancia; end AdaCar.Parametros;
with Ada.Command_Line; use Ada.Command_Line; with Ada.Text_IO; use Ada.Text_IO; with Ada.Exceptions; use Ada.Exceptions; with STL; use STL; with Parser_Svg; use Parser_Svg; with Normalisation; use Normalisation; with Courbes; use Courbes; with Interpolations_Lineaires; use Interpolations_Lineaires; with Vecteurs; use Vecteurs; with Helper; use Helper; procedure BezierToSTL is Courbes : Liste_Courbes.Liste; Segments : Liste_Points.Liste; Facettes : Liste_Facettes.Liste; -- Active l'affichage de la sortie Debug Activer_Debug : constant Boolean := True; -- Nombre de points à utiliser pour la discretisation Nombre_Points_Interpolation : constant Positive := 50; -- Faut il interpoler les droites -- ou laisser cette tâche à l'affichage ? -- WARNING: Ne pas activer avec De Casteljau -- Sinon risque de trop grand nombre de points -- rendant stlviewer inutilisable Interpoler_Droites : constant Boolean := false; -- Utiliser l'algorithme de De Casteljau -- pour interpoler les courbes de Bezier cubiques -- => Courbes plus jolies/lisses -- => Le nombre de point est ignoré pour les courbes concernées -- => car il est déterminé automatiquement -- WARNING: Ne pas activer avec Interpoler_Droites -- Sinon risque de trop grand nombre de points -- rendant stlviewer inutilisable Utiliser_DeCasteljau : constant Boolean := true; -- Tolérance utilisée si Utiliser_DeCasteljau -- Définit une tolérance pour -- savoir quand une courbe peut être -- considérée "droite" -- Plus petit = tolérance plus strict -- => Approximation plus précise -- et inversement. -- A valeur entre 0.01 et 1.0. Tolerance_DeCasteljau : constant Tolerance := 0.1; -- Permet de libérer la mémoire allouée pour -- toutes les courbes d'une liste procedure Liberer_Liste_Courbes is new Liste_Courbes.Parcourir(Liberer_Courbe); -- Nombre de facette à générer pendant la rotation Nombre_Facettes : constant Positive := 200; begin if Argument_Count /= 2 then Put_Line(Standard_Error, "usage : " & Command_Name & " fichier_entree.svg fichier_sortie.stl"); Set_Exit_Status(Failure); return; end if; Afficher_Debug (Activer_Debug); Put_Line("Chargement de la figure..."); -- On charge la figure contenue dans le SVG Charger_SVG(Argument(1), Courbes); Put_Line("Interpolation linéaire..."); -- Approximation des courbes par des segments Interpolation_Lineaire ( Courbes => Courbes, Segments => Segments, Nombre_Points => Nombre_Points_Interpolation, Interpoler_Droites => Interpoler_Droites, Utiliser_DeCasteljau => Utiliser_DeCasteljau, Tolerance_DeCasteljau => Tolerance_DeCasteljau); Put_Line("Normalisation..."); -- On normalise la figure -- (centrage en x, raccordage extremités) Normaliser(Segments); Put_Line("Projection en 3D..."); -- On convertit en facettes par rotation Creation(Segments, Facettes, Nombre_Facettes); Put_Line("Export..."); -- On sauvegarde le modele obtenu Sauvegarder(Argument(2), Facettes); -- Libère la mémoire allouée pour chaque courbe Liberer_Liste_Courbes (Courbes); -- Libère la mémoire allouée pour les listes Liste_Courbes.Vider(Courbes); Liste_Points.Vider(Segments); Liste_Facettes.Vider(Facettes); exception when Courbe_Abs => Put_Line (Standard_Error, "Le fichier source ne contenait pas de courbe."); Set_Exit_Status (Failure); when e: Courbe_Illisible => Put_Line (Standard_Error, "Le fichier source est mal formé: " & exception_message (e)); Set_Exit_Status (Failure); when e: Erreur_Lecture => Put_Line (Standard_Error, "Le fichier source est mal formé: " & exception_message (e)); Set_Exit_Status (Failure); when e: Name_Error => Put_Line (Standard_Error, "Le fichier n'a pas pu être ouvert: " & exception_message(e)); Set_Exit_Status (Failure); end;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- A D A . T E X T _ I O . F I X E D _ I O -- -- -- -- S p e c -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- -- -- ------------------------------------------------------------------------------ -- In Ada 95, the package Ada.Text_IO.Fixed_IO is a subpackage of Text_IO. -- This is for compatibility with Ada 83. In GNAT we make it a child package -- to avoid loading the necessary code if Fixed_IO is not instantiated. See -- routine Rtsfind.Check_Text_IO_Special_Unit for a description of how we -- patch up the difference in semantics so that it is invisible to the Ada -- programmer. private generic type Num is delta <>; package Ada.Text_IO.Fixed_IO is Default_Fore : Field := Num'Fore; Default_Aft : Field := Num'Aft; Default_Exp : Field := 0; procedure Get (File : File_Type; Item : out Num; Width : Field := 0) with Pre => Is_Open (File) and then Mode (File) = In_File, Global => (In_Out => File_System); procedure Get (Item : out Num; Width : Field := 0) with Post => Line_Length'Old = Line_Length and Page_Length'Old = Page_Length, Global => (In_Out => File_System); procedure Put (File : File_Type; Item : Num; Fore : Field := Default_Fore; Aft : Field := Default_Aft; Exp : Field := Default_Exp) with Pre => Is_Open (File) and then Mode (File) /= In_File, Post => Line_Length (File)'Old = Line_Length (File) and Page_Length (File)'Old = Page_Length (File), Global => (In_Out => File_System); procedure Put (Item : Num; Fore : Field := Default_Fore; Aft : Field := Default_Aft; Exp : Field := Default_Exp) with Post => Line_Length'Old = Line_Length and Page_Length'Old = Page_Length, Global => (In_Out => File_System); procedure Get (From : String; Item : out Num; Last : out Positive) with Global => null; procedure Put (To : out String; Item : Num; Aft : Field := Default_Aft; Exp : Field := Default_Exp) with Global => null; private pragma Inline (Get); pragma Inline (Put); end Ada.Text_IO.Fixed_IO;
package openGL.Model.box -- -- Provides an abstract model of a box. -- is type Item is abstract new openGL.Model.item with private; type Side is (Front, Rear, Upper, Lower, Left, Right); function Size (Self : in Item) return Vector_3; private type Item is abstract new openGL.Model.item with record Size : Vector_3; end record; type site_Id is ( Left_Lower_Front, Right_Lower_Front, Right_Upper_Front, Left_Upper_Front, Right_Lower_Rear, Left_Lower_Rear, Left_Upper_Rear, Right_Upper_Rear); type Sites is array (site_Id) of Vector_3; front_Normal : constant Vector_3 := ( 0.0, 0.0, 1.0); rear_Normal : constant Vector_3 := ( 0.0, 0.0, -1.0); upper_Normal : constant Vector_3 := ( 0.0, 1.0, 0.0); lower_Normal : constant Vector_3 := ( 0.0, -1.0, 0.0); left_Normal : constant Vector_3 := (-1.0, 0.0, 0.0); right_Normal : constant Vector_3 := ( 1.0, 0.0, 0.0); function vertex_Sites (Self : in Item'Class) return Sites; end openGL.Model.box;
-- Copyright (c) 2019 Maxim Reznik <reznikmm@gmail.com> -- -- SPDX-License-Identifier: MIT -- License-Filename: LICENSE ------------------------------------------------------------- with Program.Compilation_Unit_Vectors; with Program.Contexts; with Program.Source_Buffers; with Program.Symbols; with Program.Visibility; private with Ada.Containers.Hashed_Maps; private with Ada.Containers.Vectors; private with Program.Compilation_Units; private with Program.Compilations; private with Program.Symbols.Tables; package Program.Plain_Contexts is pragma Preelaborate; type Context is limited new Program.Contexts.Context with private; procedure Initialize (Self : in out Context'Class); procedure Find_Or_Create_Symbol (Self : in out Context'Class; Buffer : not null Program.Source_Buffers.Source_Buffer_Access; Span : Program.Source_Buffers.Span; Result : out Program.Symbols.Symbol); function Find (Self : Context'Class; Value : Program.Text) return Program.Symbols.Symbol; procedure Parse_File (Self : aliased in out Context'Class; Text_Name : Text; Env : aliased in out Program.Visibility.Context); overriding function Library_Unit_Declarations (Self : Context) return Program.Compilation_Unit_Vectors.Compilation_Unit_Vector_Access; overriding function Compilation_Unit_Bodies (Self : Context) return Program.Compilation_Unit_Vectors.Compilation_Unit_Vector_Access; private type Symbol_List_Index is range 0 .. Integer'Last; function Hash (Value : Symbol_List_Index) return Ada.Containers.Hash_Type is (Ada.Containers.Hash_Type'Mod (Value)); type Symbol_List_Item is record Prefix : Symbol_List_Index; Symbol : Program.Symbols.Symbol; end record; function Hash (Value : Symbol_List_Item) return Ada.Containers.Hash_Type; package Symbol_List_Maps is new Ada.Containers.Hashed_Maps (Key_Type => Symbol_List_Item, Element_Type => Symbol_List_Index, Hash => Hash, Equivalent_Keys => "="); package Unit_Maps is new Ada.Containers.Hashed_Maps (Key_Type => Symbol_List_Index, Element_Type => Program.Compilation_Units.Compilation_Unit_Access, Hash => Hash, Equivalent_Keys => "=", "=" => Program.Compilation_Units."="); package Unit_Vectors is new Ada.Containers.Vectors (Index_Type => Positive, Element_Type => Program.Compilation_Units.Compilation_Unit_Access, "=" => Program.Compilation_Units."="); type Unit_Vector (Context : access Program.Plain_Contexts.Context) is limited new Program.Compilation_Unit_Vectors.Compilation_Unit_Vector with record Map : Unit_Maps.Map; List : Unit_Vectors.Vector; end record; overriding function Get_Length (Self : Unit_Vector) return Positive; overriding function Element (Self : Unit_Vector; Index : Positive) return not null Program.Compilation_Units.Compilation_Unit_Access; overriding function Find_Unit (Self : Unit_Vector; Name : Text) return Program.Compilation_Units.Compilation_Unit_Access; package Compilation_Vectors is new Ada.Containers.Vectors (Index_Type => Positive, Element_Type => Program.Compilations.Compilation_Access, "=" => Program.Compilations."="); type Context is limited new Program.Contexts.Context with record Symbols : Program.Symbols.Tables.Symbol_Table; Symbol_Lists : Symbol_List_Maps.Map; Declarations : aliased Unit_Vector (Context'Unchecked_Access); Bodies : aliased Unit_Vector (Context'Unchecked_Access); Compilations : Compilation_Vectors.Vector; end record; end Program.Plain_Contexts;
-- Copyright 2015-2021 Free Software Foundation, Inc. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. procedure Foo is type New_Integer is new Integer; type Integer_Access is access Integer; function F (I : Integer; A : Integer_Access) return Boolean is begin return True; end F; function F (I : New_Integer; A : Integer_Access) return Boolean is begin return False; end F; procedure P (I : Integer; A : Integer_Access) is begin null; end P; procedure P (I : New_Integer; A : Integer_Access) is begin null; end P; B1 : constant Boolean := F (Integer'(1), null); -- BREAK B2 : constant Boolean := F (New_Integer'(2), null); begin P (Integer'(3), null); P (New_Integer'(4), null); end Foo;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- E X P _ D B U G -- -- -- -- B o d y -- -- -- -- Copyright (C) 1996-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- -- Boston, MA 02110-1301, USA. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Alloc; use Alloc; with Atree; use Atree; with Debug; use Debug; with Einfo; use Einfo; with Namet; use Namet; with Nlists; use Nlists; with Nmake; use Nmake; with Opt; use Opt; with Output; use Output; with Sem_Eval; use Sem_Eval; with Sem_Util; use Sem_Util; with Sinfo; use Sinfo; with Snames; use Snames; with Stand; use Stand; with Stringt; use Stringt; with Table; with Urealp; use Urealp; package body Exp_Dbug is -- The following table is used to queue up the entities passed as -- arguments to Qualify_Entity_Names for later processing when -- Qualify_All_Entity_Names is called. package Name_Qualify_Units is new Table.Table ( Table_Component_Type => Node_Id, Table_Index_Type => Nat, Table_Low_Bound => 1, Table_Initial => Alloc.Name_Qualify_Units_Initial, Table_Increment => Alloc.Name_Qualify_Units_Increment, Table_Name => "Name_Qualify_Units"); -------------------------------- -- Use of Qualification Flags -- -------------------------------- -- There are two flags used to keep track of qualification of entities -- Has_Fully_Qualified_Name -- Has_Qualified_Name -- The difference between these is as follows. Has_Qualified_Name is -- set to indicate that the name has been qualified as required by the -- spec of this package. As described there, this may involve the full -- qualification for the name, but for some entities, notably procedure -- local variables, this full qualification is not required. -- The flag Has_Fully_Qualified_Name is set if indeed the name has been -- fully qualified in the Ada sense. If Has_Fully_Qualified_Name is set, -- then Has_Qualified_Name is also set, but the other way round is not -- the case. -- Consider the following example: -- with ... -- procedure X is -- B : Ddd.Ttt; -- procedure Y is .. -- Here B is a procedure local variable, so it does not need fully -- qualification. The flag Has_Qualified_Name will be set on the -- first attempt to qualify B, to indicate that the job is done -- and need not be redone. -- But Y is qualified as x__y, since procedures are always fully -- qualified, so the first time that an attempt is made to qualify -- the name y, it will be replaced by x__y, and both flags are set. -- Why the two flags? Well there are cases where we derive type names -- from object names. As noted in the spec, type names are always -- fully qualified. Suppose for example that the backend has to build -- a padded type for variable B. then it will construct the PAD name -- from B, but it requires full qualification, so the fully qualified -- type name will be x__b___PAD. The two flags allow the circuit for -- building this name to realize efficiently that b needs further -- qualification. -------------------- -- Homonym_Suffix -- -------------------- -- The string defined here (and its associated length) is used to -- gather the homonym string that will be appended to Name_Buffer -- when the name is complete. Strip_Suffixes appends to this string -- as does Append_Homonym_Number, and Output_Homonym_Numbers_Suffix -- appends the string to the end of Name_Buffer. Homonym_Numbers : String (1 .. 256); Homonym_Len : Natural := 0; ---------------------- -- Local Procedures -- ---------------------- procedure Add_Uint_To_Buffer (U : Uint); -- Add image of universal integer to Name_Buffer, updating Name_Len procedure Add_Real_To_Buffer (U : Ureal); -- Add nnn_ddd to Name_Buffer, where nnn and ddd are integer values of -- the normalized numerator and denominator of the given real value. procedure Append_Homonym_Number (E : Entity_Id); -- If the entity E has homonyms in the same scope, then make an entry -- in the Homonym_Numbers array, bumping Homonym_Count accordingly. function Bounds_Match_Size (E : Entity_Id) return Boolean; -- Determine whether the bounds of E match the size of the type. This is -- used to determine whether encoding is required for a discrete type. procedure Output_Homonym_Numbers_Suffix; -- If homonym numbers are stored, then output them into Name_Buffer procedure Prepend_String_To_Buffer (S : String); -- Prepend given string to the contents of the string buffer, updating -- the value in Name_Len (i.e. string is added at start of buffer). procedure Prepend_Uint_To_Buffer (U : Uint); -- Prepend image of universal integer to Name_Buffer, updating Name_Len procedure Qualify_Entity_Name (Ent : Entity_Id); -- If not already done, replaces the Chars field of the given entity -- with the appropriate fully qualified name. procedure Strip_Suffixes (BNPE_Suffix_Found : in out Boolean); -- Given an qualified entity name in Name_Buffer, remove any plain X or -- X{nb} qualification suffix. The contents of Name_Buffer is not changed -- but Name_Len may be adjusted on return to remove the suffix. If a -- BNPE suffix is found and stripped, then BNPE_Suffix_Found is set to -- True. If no suffix is found, then BNPE_Suffix_Found is not modified. -- This routine also searches for a homonym suffix, and if one is found -- it is also stripped, and the entries are added to the global homonym -- list (Homonym_Numbers) so that they can later be put back. ------------------------ -- Add_Real_To_Buffer -- ------------------------ procedure Add_Real_To_Buffer (U : Ureal) is begin Add_Uint_To_Buffer (Norm_Num (U)); Add_Str_To_Name_Buffer ("_"); Add_Uint_To_Buffer (Norm_Den (U)); end Add_Real_To_Buffer; ------------------------ -- Add_Uint_To_Buffer -- ------------------------ procedure Add_Uint_To_Buffer (U : Uint) is begin if U < 0 then Add_Uint_To_Buffer (-U); Add_Char_To_Name_Buffer ('m'); else UI_Image (U, Decimal); Add_Str_To_Name_Buffer (UI_Image_Buffer (1 .. UI_Image_Length)); end if; end Add_Uint_To_Buffer; --------------------------- -- Append_Homonym_Number -- --------------------------- procedure Append_Homonym_Number (E : Entity_Id) is procedure Add_Nat_To_H (Nr : Nat); -- Little procedure to append Nr to Homonym_Numbers ------------------ -- Add_Nat_To_H -- ------------------ procedure Add_Nat_To_H (Nr : Nat) is begin if Nr >= 10 then Add_Nat_To_H (Nr / 10); end if; Homonym_Len := Homonym_Len + 1; Homonym_Numbers (Homonym_Len) := Character'Val (Nr mod 10 + Character'Pos ('0')); end Add_Nat_To_H; -- Start of processing for Append_Homonym_Number begin if Has_Homonym (E) then declare H : Entity_Id := Homonym (E); Nr : Nat := 1; begin while Present (H) loop if Scope (H) = Scope (E) then Nr := Nr + 1; end if; H := Homonym (H); end loop; if Homonym_Len > 0 then Homonym_Len := Homonym_Len + 1; Homonym_Numbers (Homonym_Len) := '_'; end if; Add_Nat_To_H (Nr); end; end if; end Append_Homonym_Number; ----------------------- -- Bounds_Match_Size -- ----------------------- function Bounds_Match_Size (E : Entity_Id) return Boolean is Siz : Uint; begin if not Is_OK_Static_Subtype (E) then return False; elsif Is_Integer_Type (E) and then Subtypes_Statically_Match (E, Base_Type (E)) then return True; -- Here we check if the static bounds match the natural size, which is -- the size passed through with the debugging information. This is the -- Esize rounded up to 8, 16, 32 or 64 as appropriate. else declare Umark : constant Uintp.Save_Mark := Uintp.Mark; Result : Boolean; begin if Esize (E) <= 8 then Siz := Uint_8; elsif Esize (E) <= 16 then Siz := Uint_16; elsif Esize (E) <= 32 then Siz := Uint_32; else Siz := Uint_64; end if; if Is_Modular_Integer_Type (E) or else Is_Enumeration_Type (E) then Result := Expr_Rep_Value (Type_Low_Bound (E)) = 0 and then 2 ** Siz - Expr_Rep_Value (Type_High_Bound (E)) = 1; else Result := Expr_Rep_Value (Type_Low_Bound (E)) + 2 ** (Siz - 1) = 0 and then 2 ** (Siz - 1) - Expr_Rep_Value (Type_High_Bound (E)) = 1; end if; Release (Umark); return Result; end; end if; end Bounds_Match_Size; -------------------------------- -- Debug_Renaming_Declaration -- -------------------------------- function Debug_Renaming_Declaration (N : Node_Id) return Node_Id is Loc : constant Source_Ptr := Sloc (N); Ent : constant Node_Id := Defining_Entity (N); Nam : constant Node_Id := Name (N); Rnm : Name_Id; Ren : Node_Id; Lit : Entity_Id; Typ : Entity_Id; Res : Node_Id; Def : Entity_Id; function Output_Subscript (N : Node_Id; S : String) return Boolean; -- Outputs a single subscript value as ?nnn (subscript is compile time -- known value with value nnn) or as ?e (subscript is local constant -- with name e), where S supplies the proper string to use for ?. -- Returns False if the subscript is not of an appropriate type to -- output in one of these two forms. The result is prepended to the -- name stored in Name_Buffer. ---------------------- -- Output_Subscript -- ---------------------- function Output_Subscript (N : Node_Id; S : String) return Boolean is begin if Compile_Time_Known_Value (N) then Prepend_Uint_To_Buffer (Expr_Value (N)); elsif Nkind (N) = N_Identifier and then Scope (Entity (N)) = Scope (Ent) and then Ekind (Entity (N)) = E_Constant then Prepend_String_To_Buffer (Get_Name_String (Chars (Entity (N)))); else return False; end if; Prepend_String_To_Buffer (S); return True; end Output_Subscript; -- Start of processing for Debug_Renaming_Declaration begin if not Comes_From_Source (N) and then not Needs_Debug_Info (Ent) then return Empty; end if; -- Prepare entity name for type declaration Get_Name_String (Chars (Ent)); case Nkind (N) is when N_Object_Renaming_Declaration => Add_Str_To_Name_Buffer ("___XR"); when N_Exception_Renaming_Declaration => Add_Str_To_Name_Buffer ("___XRE"); when N_Package_Renaming_Declaration => Add_Str_To_Name_Buffer ("___XRP"); -- If it is a child unit create a fully qualified name, to -- disambiguate multiple child units with the same name and -- different parents. if Is_Child_Unit (Ent) then Prepend_String_To_Buffer ("__"); Prepend_String_To_Buffer (Get_Name_String (Chars (Scope (Ent)))); end if; when others => return Empty; end case; Rnm := Name_Find; -- Get renamed entity and compute suffix Name_Len := 0; Ren := Nam; loop case Nkind (Ren) is when N_Identifier => exit; when N_Expanded_Name => -- The entity field for an N_Expanded_Name is on the expanded -- name node itself, so we are done here too. exit; when N_Selected_Component => Prepend_String_To_Buffer (Get_Name_String (Chars (Selector_Name (Ren)))); Prepend_String_To_Buffer ("XR"); Ren := Prefix (Ren); when N_Indexed_Component => declare X : Node_Id := Last (Expressions (Ren)); begin while Present (X) loop if not Output_Subscript (X, "XS") then Set_Materialize_Entity (Ent); return Empty; end if; Prev (X); end loop; end; Ren := Prefix (Ren); when N_Slice => Typ := Etype (First_Index (Etype (Nam))); if not Output_Subscript (Type_High_Bound (Typ), "XS") then Set_Materialize_Entity (Ent); return Empty; end if; if not Output_Subscript (Type_Low_Bound (Typ), "XL") then Set_Materialize_Entity (Ent); return Empty; end if; Ren := Prefix (Ren); when N_Explicit_Dereference => Set_Materialize_Entity (Ent); Prepend_String_To_Buffer ("XA"); Ren := Prefix (Ren); -- For now, anything else simply results in no translation when others => Set_Materialize_Entity (Ent); return Empty; end case; end loop; Prepend_String_To_Buffer ("___XE"); -- For now, the literal name contains only the suffix. The Entity_Id -- value for the name is used to create a link from this literal name -- to the renamed entity using the Debug_Renaming_Link field. Then the -- Qualify_Entity_Name procedure uses this link to create the proper -- fully qualified name. -- The reason we do things this way is that we really need to copy the -- qualification of the renamed entity, and it is really much easier to -- do this after the renamed entity has itself been fully qualified. Lit := Make_Defining_Identifier (Loc, Chars => Name_Enter); Set_Debug_Renaming_Link (Lit, Entity (Ren)); -- Return the appropriate enumeration type Def := Make_Defining_Identifier (Loc, Chars => Rnm); Res := Make_Full_Type_Declaration (Loc, Defining_Identifier => Def, Type_Definition => Make_Enumeration_Type_Definition (Loc, Literals => New_List (Lit))); Set_Needs_Debug_Info (Def); Set_Needs_Debug_Info (Lit); Set_Discard_Names (Defining_Identifier (Res)); return Res; -- If we get an exception, just figure it is a case that we cannot -- successfully handle using our current approach, since this is -- only for debugging, no need to take the compilation with us! exception when others => return Make_Null_Statement (Loc); end Debug_Renaming_Declaration; ---------------------- -- Get_Encoded_Name -- ---------------------- -- Note: see spec for details on encodings procedure Get_Encoded_Name (E : Entity_Id) is Has_Suffix : Boolean; begin -- If not generating code, there is no need to create encoded -- names, and problems when the back-end is called to annotate -- types without full code generation. See comments at beginning -- of Get_External_Name_With_Suffix for additional details. if Operating_Mode /= Generate_Code then return; end if; Get_Name_String (Chars (E)); -- Nothing to do if we do not have a type if not Is_Type (E) -- Or if this is an enumeration base type or else (Is_Enumeration_Type (E) and then E = Base_Type (E)) -- Or if this is a dummy type for a renaming or else (Name_Len >= 3 and then Name_Buffer (Name_Len - 2 .. Name_Len) = "_XR") or else (Name_Len >= 4 and then (Name_Buffer (Name_Len - 3 .. Name_Len) = "_XRE" or else Name_Buffer (Name_Len - 3 .. Name_Len) = "_XRP")) -- For all these cases, just return the name unchanged then Name_Buffer (Name_Len + 1) := ASCII.Nul; return; end if; Has_Suffix := True; -- Fixed-point case if Is_Fixed_Point_Type (E) then Get_External_Name_With_Suffix (E, "XF_"); Add_Real_To_Buffer (Delta_Value (E)); if Small_Value (E) /= Delta_Value (E) then Add_Str_To_Name_Buffer ("_"); Add_Real_To_Buffer (Small_Value (E)); end if; -- Vax floating-point case elsif Vax_Float (E) then if Digits_Value (Base_Type (E)) = 6 then Get_External_Name_With_Suffix (E, "XFF"); elsif Digits_Value (Base_Type (E)) = 9 then Get_External_Name_With_Suffix (E, "XFF"); else pragma Assert (Digits_Value (Base_Type (E)) = 15); Get_External_Name_With_Suffix (E, "XFG"); end if; -- Discrete case where bounds do not match size elsif Is_Discrete_Type (E) and then not Bounds_Match_Size (E) then declare Lo : constant Node_Id := Type_Low_Bound (E); Hi : constant Node_Id := Type_High_Bound (E); Lo_Con : constant Boolean := Compile_Time_Known_Value (Lo); Hi_Con : constant Boolean := Compile_Time_Known_Value (Hi); Lo_Discr : constant Boolean := Nkind (Lo) = N_Identifier and then Ekind (Entity (Lo)) = E_Discriminant; Hi_Discr : constant Boolean := Nkind (Hi) = N_Identifier and then Ekind (Entity (Hi)) = E_Discriminant; Lo_Encode : constant Boolean := Lo_Con or Lo_Discr; Hi_Encode : constant Boolean := Hi_Con or Hi_Discr; Biased : constant Boolean := Has_Biased_Representation (E); begin if Biased then Get_External_Name_With_Suffix (E, "XB"); else Get_External_Name_With_Suffix (E, "XD"); end if; if Lo_Encode or Hi_Encode then if Biased then Add_Str_To_Name_Buffer ("_"); else if Lo_Encode then if Hi_Encode then Add_Str_To_Name_Buffer ("LU_"); else Add_Str_To_Name_Buffer ("L_"); end if; else Add_Str_To_Name_Buffer ("U_"); end if; end if; if Lo_Con then Add_Uint_To_Buffer (Expr_Rep_Value (Lo)); elsif Lo_Discr then Get_Name_String_And_Append (Chars (Entity (Lo))); end if; if Lo_Encode and Hi_Encode then Add_Str_To_Name_Buffer ("__"); end if; if Hi_Con then Add_Uint_To_Buffer (Expr_Rep_Value (Hi)); elsif Hi_Discr then Get_Name_String_And_Append (Chars (Entity (Hi))); end if; end if; end; -- For all other cases, the encoded name is the normal type name else Has_Suffix := False; Get_External_Name (E, Has_Suffix); end if; if Debug_Flag_B and then Has_Suffix then Write_Str ("**** type "); Write_Name (Chars (E)); Write_Str (" is encoded as "); Write_Str (Name_Buffer (1 .. Name_Len)); Write_Eol; end if; Name_Buffer (Name_Len + 1) := ASCII.NUL; end Get_Encoded_Name; ----------------------- -- Get_External_Name -- ----------------------- procedure Get_External_Name (Entity : Entity_Id; Has_Suffix : Boolean) is E : Entity_Id := Entity; Kind : Entity_Kind; procedure Get_Qualified_Name_And_Append (Entity : Entity_Id); -- Appends fully qualified name of given entity to Name_Buffer ----------------------------------- -- Get_Qualified_Name_And_Append -- ----------------------------------- procedure Get_Qualified_Name_And_Append (Entity : Entity_Id) is begin -- If the entity is a compilation unit, its scope is Standard, -- there is no outer scope, and the no further qualification -- is required. -- If the front end has already computed a fully qualified name, -- then it is also the case that no further qualification is -- required if Present (Scope (Scope (Entity))) and then not Has_Fully_Qualified_Name (Entity) then Get_Qualified_Name_And_Append (Scope (Entity)); Add_Str_To_Name_Buffer ("__"); Get_Name_String_And_Append (Chars (Entity)); Append_Homonym_Number (Entity); else Get_Name_String_And_Append (Chars (Entity)); end if; end Get_Qualified_Name_And_Append; -- Start of processing for Get_External_Name begin Name_Len := 0; -- If this is a child unit, we want the child if Nkind (E) = N_Defining_Program_Unit_Name then E := Defining_Identifier (Entity); end if; Kind := Ekind (E); -- Case of interface name being used if (Kind = E_Procedure or else Kind = E_Function or else Kind = E_Constant or else Kind = E_Variable or else Kind = E_Exception) and then Present (Interface_Name (E)) and then No (Address_Clause (E)) and then not Has_Suffix then Add_String_To_Name_Buffer (Strval (Interface_Name (E))); -- All other cases besides the interface name case else -- If this is a library level subprogram (i.e. a subprogram that is a -- compilation unit other than a subunit), then we prepend _ada_ to -- ensure distinctions required as described in the spec. -- Check explicitly for child units, because those are not flagged -- as Compilation_Units by lib. Should they be ??? if Is_Subprogram (E) and then (Is_Compilation_Unit (E) or Is_Child_Unit (E)) and then not Has_Suffix then Add_Str_To_Name_Buffer ("_ada_"); end if; -- If the entity is a subprogram instance that is not a compilation -- unit, generate the name of the original Ada entity, which is the -- one gdb needs. if Is_Generic_Instance (E) and then Is_Subprogram (E) and then not Is_Compilation_Unit (Scope (E)) and then (Ekind (Scope (E)) = E_Package or else Ekind (Scope (E)) = E_Package_Body) and then Present (Related_Instance (Scope (E))) then E := Related_Instance (Scope (E)); end if; Get_Qualified_Name_And_Append (E); end if; Name_Buffer (Name_Len + 1) := ASCII.Nul; end Get_External_Name; ----------------------------------- -- Get_External_Name_With_Suffix -- ----------------------------------- procedure Get_External_Name_With_Suffix (Entity : Entity_Id; Suffix : String) is Has_Suffix : constant Boolean := (Suffix /= ""); begin -- If we are not in code generation mode, this procedure may still be -- called from Back_End (more specifically - from gigi for doing type -- representation annotation or some representation-specific checks). -- But in this mode there is no need to mess with external names. -- Furthermore, the call causes difficulties in this case because the -- string representing the homonym number is not correctly reset as a -- part of the call to Output_Homonym_Numbers_Suffix (which is not -- called in gigi). if Operating_Mode /= Generate_Code then return; end if; Get_External_Name (Entity, Has_Suffix); if Has_Suffix then Add_Str_To_Name_Buffer ("___"); Add_Str_To_Name_Buffer (Suffix); Name_Buffer (Name_Len + 1) := ASCII.Nul; end if; end Get_External_Name_With_Suffix; -------------------------- -- Get_Variant_Encoding -- -------------------------- procedure Get_Variant_Encoding (V : Node_Id) is Choice : Node_Id; procedure Choice_Val (Typ : Character; Choice : Node_Id); -- Output encoded value for a single choice value. Typ is the key -- character ('S', 'F', or 'T') that precedes the choice value. ---------------- -- Choice_Val -- ---------------- procedure Choice_Val (Typ : Character; Choice : Node_Id) is begin if Nkind (Choice) = N_Integer_Literal then Add_Char_To_Name_Buffer (Typ); Add_Uint_To_Buffer (Intval (Choice)); -- Character literal with no entity present (this is the case -- Standard.Character or Standard.Wide_Character as root type) elsif Nkind (Choice) = N_Character_Literal and then No (Entity (Choice)) then Add_Char_To_Name_Buffer (Typ); Add_Uint_To_Buffer (Char_Literal_Value (Choice)); else declare Ent : constant Entity_Id := Entity (Choice); begin if Ekind (Ent) = E_Enumeration_Literal then Add_Char_To_Name_Buffer (Typ); Add_Uint_To_Buffer (Enumeration_Rep (Ent)); else pragma Assert (Ekind (Ent) = E_Constant); Choice_Val (Typ, Constant_Value (Ent)); end if; end; end if; end Choice_Val; -- Start of processing for Get_Variant_Encoding begin Name_Len := 0; Choice := First (Discrete_Choices (V)); while Present (Choice) loop if Nkind (Choice) = N_Others_Choice then Add_Char_To_Name_Buffer ('O'); elsif Nkind (Choice) = N_Range then Choice_Val ('R', Low_Bound (Choice)); Choice_Val ('T', High_Bound (Choice)); elsif Is_Entity_Name (Choice) and then Is_Type (Entity (Choice)) then Choice_Val ('R', Type_Low_Bound (Entity (Choice))); Choice_Val ('T', Type_High_Bound (Entity (Choice))); elsif Nkind (Choice) = N_Subtype_Indication then declare Rang : constant Node_Id := Range_Expression (Constraint (Choice)); begin Choice_Val ('R', Low_Bound (Rang)); Choice_Val ('T', High_Bound (Rang)); end; else Choice_Val ('S', Choice); end if; Next (Choice); end loop; Name_Buffer (Name_Len + 1) := ASCII.NUL; if Debug_Flag_B then declare VP : constant Node_Id := Parent (V); -- Variant_Part CL : constant Node_Id := Parent (VP); -- Component_List RD : constant Node_Id := Parent (CL); -- Record_Definition FT : constant Node_Id := Parent (RD); -- Full_Type_Declaration begin Write_Str ("**** variant for type "); Write_Name (Chars (Defining_Identifier (FT))); Write_Str (" is encoded as "); Write_Str (Name_Buffer (1 .. Name_Len)); Write_Eol; end; end if; end Get_Variant_Encoding; ------------------------------------ -- Get_Secondary_DT_External_Name -- ------------------------------------ procedure Get_Secondary_DT_External_Name (Typ : Entity_Id; Ancestor_Typ : Entity_Id; Suffix_Index : Int) is begin Get_External_Name (Typ, Has_Suffix => False); if Ancestor_Typ /= Typ then declare Len : constant Natural := Name_Len; Save_Str : constant String (1 .. Name_Len) := Name_Buffer (1 .. Name_Len); begin Get_External_Name (Ancestor_Typ, Has_Suffix => False); -- Append the extended name of the ancestor to the -- extended name of Typ Name_Buffer (Len + 2 .. Len + Name_Len + 1) := Name_Buffer (1 .. Name_Len); Name_Buffer (1 .. Len) := Save_Str; Name_Buffer (Len + 1) := '_'; Name_Len := Len + Name_Len + 1; end; end if; Add_Nat_To_Name_Buffer (Suffix_Index); end Get_Secondary_DT_External_Name; --------------------------------- -- Make_Packed_Array_Type_Name -- --------------------------------- function Make_Packed_Array_Type_Name (Typ : Entity_Id; Csize : Uint) return Name_Id is begin Get_Name_String (Chars (Typ)); Add_Str_To_Name_Buffer ("___XP"); Add_Uint_To_Buffer (Csize); return Name_Find; end Make_Packed_Array_Type_Name; ----------------------------------- -- Output_Homonym_Numbers_Suffix -- ----------------------------------- procedure Output_Homonym_Numbers_Suffix is J : Natural; begin if Homonym_Len > 0 then -- Check for all 1's, in which case we do not output J := 1; loop exit when Homonym_Numbers (J) /= '1'; -- If we reached end of string we do not output if J = Homonym_Len then Homonym_Len := 0; return; end if; exit when Homonym_Numbers (J + 1) /= '_'; J := J + 2; end loop; -- If we exit the loop then suffix must be output Add_Str_To_Name_Buffer ("__"); Add_Str_To_Name_Buffer (Homonym_Numbers (1 .. Homonym_Len)); Homonym_Len := 0; end if; end Output_Homonym_Numbers_Suffix; ------------------------------ -- Prepend_String_To_Buffer -- ------------------------------ procedure Prepend_String_To_Buffer (S : String) is N : constant Integer := S'Length; begin Name_Buffer (1 + N .. Name_Len + N) := Name_Buffer (1 .. Name_Len); Name_Buffer (1 .. N) := S; Name_Len := Name_Len + N; end Prepend_String_To_Buffer; ---------------------------- -- Prepend_Uint_To_Buffer -- ---------------------------- procedure Prepend_Uint_To_Buffer (U : Uint) is begin if U < 0 then Prepend_String_To_Buffer ("m"); Prepend_Uint_To_Buffer (-U); else UI_Image (U, Decimal); Prepend_String_To_Buffer (UI_Image_Buffer (1 .. UI_Image_Length)); end if; end Prepend_Uint_To_Buffer; ------------------------------ -- Qualify_All_Entity_Names -- ------------------------------ procedure Qualify_All_Entity_Names is E : Entity_Id; Ent : Entity_Id; begin for J in Name_Qualify_Units.First .. Name_Qualify_Units.Last loop E := Defining_Entity (Name_Qualify_Units.Table (J)); Qualify_Entity_Name (E); Ent := First_Entity (E); while Present (Ent) loop Qualify_Entity_Name (Ent); Next_Entity (Ent); -- There are odd cases where Last_Entity (E) = E. This happens -- in the case of renaming of packages. This test avoids getting -- stuck in such cases. exit when Ent = E; end loop; end loop; end Qualify_All_Entity_Names; ------------------------- -- Qualify_Entity_Name -- ------------------------- procedure Qualify_Entity_Name (Ent : Entity_Id) is Full_Qualify_Name : String (1 .. Name_Buffer'Length); Full_Qualify_Len : Natural := 0; -- Used to accumulate fully qualified name of subprogram procedure Fully_Qualify_Name (E : Entity_Id); -- Used to qualify a subprogram or type name, where full -- qualification up to Standard is always used. Name is set -- in Full_Qualify_Name with the length in Full_Qualify_Len. -- Note that this routine does not prepend the _ada_ string -- required for library subprograms (this is done in the back end). function Is_BNPE (S : Entity_Id) return Boolean; -- Determines if S is a BNPE, i.e. Body-Nested Package Entity, which -- is defined to be a package which is immediately nested within a -- package body. function Qualify_Needed (S : Entity_Id) return Boolean; -- Given a scope, determines if the scope is to be included in the -- fully qualified name, True if so, False if not. procedure Set_BNPE_Suffix (E : Entity_Id); -- Recursive routine to append the BNPE qualification suffix. Works -- from right to left with E being the current entity in the list. -- The result does NOT have the trailing n's and trailing b stripped. -- The caller must do this required stripping. procedure Set_Entity_Name (E : Entity_Id); -- Internal recursive routine that does most of the work. This routine -- leaves the result sitting in Name_Buffer and Name_Len. BNPE_Suffix_Needed : Boolean := False; -- Set true if a body-nested package entity suffix is required Save_Chars : constant Name_Id := Chars (Ent); -- Save original name ------------------------ -- Fully_Qualify_Name -- ------------------------ procedure Fully_Qualify_Name (E : Entity_Id) is Discard : Boolean := False; begin -- Ignore empty entry (can happen in error cases) if No (E) then return; -- If this we are qualifying entities local to a generic -- instance, use the name of the original instantiation, -- not that of the anonymous subprogram in the wrapper -- package, so that gdb doesn't have to know about these. elsif Is_Generic_Instance (E) and then Is_Subprogram (E) and then not Comes_From_Source (E) and then not Is_Compilation_Unit (Scope (E)) then Fully_Qualify_Name (Related_Instance (Scope (E))); return; end if; -- If we reached fully qualified name, then just copy it if Has_Fully_Qualified_Name (E) then Get_Name_String (Chars (E)); Strip_Suffixes (Discard); Full_Qualify_Name (1 .. Name_Len) := Name_Buffer (1 .. Name_Len); Full_Qualify_Len := Name_Len; Set_Has_Fully_Qualified_Name (Ent); -- Case of non-fully qualified name else if Scope (E) = Standard_Standard then Set_Has_Fully_Qualified_Name (Ent); else Fully_Qualify_Name (Scope (E)); Full_Qualify_Name (Full_Qualify_Len + 1) := '_'; Full_Qualify_Name (Full_Qualify_Len + 2) := '_'; Full_Qualify_Len := Full_Qualify_Len + 2; end if; if Has_Qualified_Name (E) then Get_Unqualified_Name_String (Chars (E)); else Get_Name_String (Chars (E)); end if; -- A special check here, we never add internal block or loop -- names, since they intefere with debugging. We identify these -- by the fact that they start with an upper case B or L. -- But do add these if what we are qualifying is a __clean -- procedure since those need to be made unique. if (Name_Buffer (1) = 'B' or else Name_Buffer (1) = 'L') and then (not Debug_Flag_VV) and then Full_Qualify_Len > 2 and then Chars (Ent) /= Name_uClean then Full_Qualify_Len := Full_Qualify_Len - 2; else Full_Qualify_Name (Full_Qualify_Len + 1 .. Full_Qualify_Len + Name_Len) := Name_Buffer (1 .. Name_Len); Full_Qualify_Len := Full_Qualify_Len + Name_Len; Append_Homonym_Number (E); end if; end if; if Is_BNPE (E) then BNPE_Suffix_Needed := True; end if; end Fully_Qualify_Name; ------------- -- Is_BNPE -- ------------- function Is_BNPE (S : Entity_Id) return Boolean is begin return Ekind (S) = E_Package and then Is_Package_Body_Entity (S); end Is_BNPE; -------------------- -- Qualify_Needed -- -------------------- function Qualify_Needed (S : Entity_Id) return Boolean is begin -- If we got all the way to Standard, then we have certainly -- fully qualified the name, so set the flag appropriately, -- and then return False, since we are most certainly done! if S = Standard_Standard then Set_Has_Fully_Qualified_Name (Ent, True); return False; -- Otherwise figure out if further qualification is required else return Is_Subprogram (Ent) or else Ekind (Ent) = E_Subprogram_Body or else (Ekind (S) /= E_Block and then not Is_Dynamic_Scope (S)); end if; end Qualify_Needed; --------------------- -- Set_BNPE_Suffix -- --------------------- procedure Set_BNPE_Suffix (E : Entity_Id) is S : constant Entity_Id := Scope (E); begin if Qualify_Needed (S) then Set_BNPE_Suffix (S); if Is_BNPE (E) then Add_Char_To_Name_Buffer ('b'); else Add_Char_To_Name_Buffer ('n'); end if; else Add_Char_To_Name_Buffer ('X'); end if; end Set_BNPE_Suffix; --------------------- -- Set_Entity_Name -- --------------------- procedure Set_Entity_Name (E : Entity_Id) is S : constant Entity_Id := Scope (E); begin -- If we reach an already qualified name, just take the encoding -- except that we strip the package body suffixes, since these -- will be separately put on later. if Has_Qualified_Name (E) then Get_Name_String_And_Append (Chars (E)); Strip_Suffixes (BNPE_Suffix_Needed); -- If the top level name we are adding is itself fully -- qualified, then that means that the name that we are -- preparing for the Fully_Qualify_Name call will also -- generate a fully qualified name. if Has_Fully_Qualified_Name (E) then Set_Has_Fully_Qualified_Name (Ent); end if; -- Case where upper level name is not encoded yet else -- Recurse if further qualification required if Qualify_Needed (S) then Set_Entity_Name (S); Add_Str_To_Name_Buffer ("__"); end if; -- Otherwise get name and note if it is a NPBE Get_Name_String_And_Append (Chars (E)); if Is_BNPE (E) then BNPE_Suffix_Needed := True; end if; Append_Homonym_Number (E); end if; end Set_Entity_Name; -- Start of processing for Qualify_Entity_Name begin if Has_Qualified_Name (Ent) then return; -- Here is where we create the proper link for renaming elsif Ekind (Ent) = E_Enumeration_Literal and then Present (Debug_Renaming_Link (Ent)) then Name_Len := 0; Qualify_Entity_Name (Debug_Renaming_Link (Ent)); Get_Name_String (Chars (Ent)); Prepend_String_To_Buffer (Get_Name_String (Chars (Debug_Renaming_Link (Ent)))); Set_Chars (Ent, Name_Enter); Set_Has_Qualified_Name (Ent); return; elsif Is_Subprogram (Ent) or else Ekind (Ent) = E_Subprogram_Body or else Is_Type (Ent) then Fully_Qualify_Name (Ent); Name_Len := Full_Qualify_Len; Name_Buffer (1 .. Name_Len) := Full_Qualify_Name (1 .. Name_Len); elsif Qualify_Needed (Scope (Ent)) then Name_Len := 0; Set_Entity_Name (Ent); else Set_Has_Qualified_Name (Ent); return; end if; -- Fall through with a fully qualified name in Name_Buffer/Name_Len Output_Homonym_Numbers_Suffix; -- Add body-nested package suffix if required if BNPE_Suffix_Needed and then Ekind (Ent) /= E_Enumeration_Literal then Set_BNPE_Suffix (Ent); -- Strip trailing n's and last trailing b as required. note that -- we know there is at least one b, or no suffix would be generated. while Name_Buffer (Name_Len) = 'n' loop Name_Len := Name_Len - 1; end loop; Name_Len := Name_Len - 1; end if; Set_Chars (Ent, Name_Enter); Set_Has_Qualified_Name (Ent); if Debug_Flag_BB then Write_Str ("*** "); Write_Name (Save_Chars); Write_Str (" qualified as "); Write_Name (Chars (Ent)); Write_Eol; end if; end Qualify_Entity_Name; -------------------------- -- Qualify_Entity_Names -- -------------------------- procedure Qualify_Entity_Names (N : Node_Id) is begin Name_Qualify_Units.Append (N); end Qualify_Entity_Names; -------------------- -- Strip_Suffixes -- -------------------- procedure Strip_Suffixes (BNPE_Suffix_Found : in out Boolean) is SL : Natural; begin -- Search for and strip BNPE suffix for J in reverse 2 .. Name_Len loop if Name_Buffer (J) = 'X' then Name_Len := J - 1; BNPE_Suffix_Found := True; exit; end if; exit when Name_Buffer (J) /= 'b' and then Name_Buffer (J) /= 'n'; end loop; -- Search for and strip homonym numbers suffix for J in reverse 2 .. Name_Len - 2 loop if Name_Buffer (J) = '_' and then Name_Buffer (J + 1) = '_' then if Name_Buffer (J + 2) in '0' .. '9' then if Homonym_Len > 0 then Homonym_Len := Homonym_Len + 1; Homonym_Numbers (Homonym_Len) := '-'; end if; SL := Name_Len - (J + 1); Homonym_Numbers (Homonym_Len + 1 .. Homonym_Len + SL) := Name_Buffer (J + 2 .. Name_Len); Name_Len := J - 1; Homonym_Len := Homonym_Len + SL; end if; exit; end if; end loop; end Strip_Suffixes; end Exp_Dbug;
with impact.d2.Fixture; package impact.d2.Contact.circle -- -- -- is type b2CircleContact is new b2Contact with null record; type View is access all b2CircleContact'Class; function to_b2CircleContact (fixtureA, fixtureB : access fixture.b2Fixture'Class) return b2CircleContact; overriding procedure Evaluate (Self : in out b2CircleContact; manifold : access collision.b2Manifold; xfA, xfB : in b2Transform); function Create (fixtureA, fixtureB : access Fixture.b2Fixture) return access b2Contact'Class; procedure Destroy (contact : in out impact.d2.Contact.view); end impact.d2.Contact.circle;
with Glib, glib.Error, gtk.Builder, gtk.Handlers, AdaM.context_Line, aIDE.Editor.of_context_line; package body aIDE.Editor.of_context is use gtk.Builder, Glib, Glib.Error; function on_context_Label_clicked (the_Label : access Gtk_Label_Record'Class; Self : in aIDE.Editor.of_context.view) return Boolean is pragma Unreferenced (the_Label); use AdaM; the_Line : constant AdaM.context_Line .view := AdaM.context_Line.new_context_Line ("anon"); the_Line_Editor : constant aIDE.Editor.of_context_line.view := Editor.of_context_line.Forge.to_context_line_Editor (Self.Context, the_Line); begin the_Line_Editor.top_Widget.reparent (Self.context_lines_Box); Self.Context.add (the_Line); return False; end on_context_Label_clicked; package Label_return_Callbacks is new Gtk.Handlers.User_Return_Callback (Gtk_Label_Record, Boolean, aIDE.Editor.of_context.view); package body Forge is function to_context_Editor (the_Context : in AdaM.Context.view) return View is Self : constant Editor.of_context.view := new Editor.of_context.item; the_Builder : Gtk_Builder; Error : aliased GError; Result : Guint; pragma Unreferenced (Result); begin Gtk_New (the_Builder); Result := the_Builder.Add_From_File ("glade/editor/context_editor.glade", Error'Access); if Error /= null then Error_Free (Error); end if; Self.Top := gtk_Frame (the_Builder.get_Object ("top_Frame")); Self.context_Label := gtk_Label (the_Builder.get_Object ("context_Label")); Self.context_lines_Box := gtk_Box (the_Builder.get_Object ("context_lines_Box")); Label_return_Callbacks.Connect (Self.context_Label, "button-release-event", on_context_Label_clicked'Access, Self); Self.Context := the_Context; Self.freshen; return Self; end to_context_Editor; end Forge; procedure Context_is (Self : in out Item; Now : in AdaM.Context.view) is begin Self.Context := Now; Self.freshen; end Context_is; overriding function top_Widget (Self : in Item) return gtk.Widget.Gtk_Widget is begin return gtk.Widget.Gtk_Widget (Self.Top); end top_Widget; overriding procedure freshen (Self : in out Item) is the_Lines : constant AdaM.context_Line.Vector := Self.Context.Lines; begin loop declare the_Child : constant gtk_Widget := Self.context_lines_Box.Get_Child (0); begin exit when the_Child = null; the_Child.destroy; end; end loop; for i in 1 .. Integer (the_Lines.Length) loop declare the_Line : AdaM.context_line .view renames the_Lines.Element (i); the_Line_Editor : constant aIDE.Editor.of_context_line.view := Editor.of_context_line.Forge.to_context_line_Editor (Self.Context, the_Line); begin the_Line_Editor.top_Widget.reparent (Self.context_lines_Box); end; end loop; end freshen; end aIDE.Editor.of_context;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . S A M 4 S -- -- -- -- S p e c -- -- -- -- Copyright (C) 2019, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This file provides register definitions for the SAM4S (ARM Cortex M4) -- microcontrollers from Atmel. Definitions are taken from 'SAM4S Series' -- datasheet (document 11100E-ATARM-24-Jul-13). package System.SAM4S is pragma No_Elaboration_Code_All; -- Allow user code with pragma No_Elaboration_Code_All to use this package pragma Preelaborate (System.SAM4S); pragma Suppress (Alignment_Check); -- Avoid any warnings for address clauses on variables of type record. type Word is mod 2**32; -- Define address bases for various peripherals Peripheral_Base : constant := 16#4000_0000#; SPI_Base : constant := Peripheral_Base + 16#8000#; System_Controller_Base : constant := Peripheral_Base + 16#e_0000#; PMC_Base : constant := System_Controller_Base + 16#0400#; UART0_Base : constant := System_Controller_Base + 16#0600#; UART1_Base : constant := System_Controller_Base + 16#0800#; EFC0_Base : constant := System_Controller_Base + 16#0A00#; EFC1_Base : constant := System_Controller_Base + 16#0C00#; PIOA_Base : constant := System_Controller_Base + 16#0e00#; PIOB_Base : constant := System_Controller_Base + 16#1000#; PIOC_Base : constant := System_Controller_Base + 16#1200#; WDT_Base : constant := System_Controller_Base + 16#1450#; --------------------------------- -- Power Management Controller -- --------------------------------- type PMC_Registers is record PMC_SCER : Word; PMC_SCDR : Word; PMC_SCSR : Word; Pad0 : Word; PMC_PCER0 : Word; PMC_PCDR0 : Word; PMC_PCSR0 : Word; Pad1 : Word; CKGR_MOR : Word; CKGR_MCFR : Word; CKGR_PLLAR : Word; CKGR_PLLBR : Word; PMC_MCKR : Word; Pad3_4 : Word; PMC_USB : Word; Pad3_C : Word; PMC_PCK0 : Word; PMC_PCK1 : Word; PMC_PCK2 : Word; Pad4_C : Word; Pad5_0 : Word; Pad5_4 : Word; Pad5_8 : Word; Pad5_C : Word; PMC_IER : Word; PMC_IDR : Word; PMC_SR : Word; PMC_IMR : Word; PMC_FSMR : Word; PMC_FSPR : Word; PMC_FOCR : Word; Pad7_C : Word; -- Not complete end record; PMC : PMC_Registers with Volatile, Import, Address => System'To_Address (PMC_Base); -- Constants for the CKGR MOR register package CKGR_MOR is CFDEN : constant := 2 ** 25; MOSCSEL : constant := 2 ** 24; KEY : constant := 16#37# * 2 ** 16; MOSCXTST : constant := 2 ** 8; MOSCRCEN : constant := 2 ** 3; WAITMODE : constant := 2 ** 2; MOSCXTBY : constant := 2 ** 1; MOSCXTEN : constant := 2 ** 0; end CKGR_MOR; -- Constants for the PMC SR register package PMC_SR is MCKRDY : constant := 2 ** 3; LOCKB : constant := 2 ** 2; LOCKA : constant := 2 ** 1; MOSCXTS : constant := 2 ** 0; end PMC_SR; -- Constants for the CKGR PLLAR and PLLBR registers package CKGR_PLLxR is DIV : constant := 2 ** 0; PLLCOUNT : constant := 2 ** 8; MUL : constant := 2 ** 16; ONE : constant := 2 ** 29; end CKGR_PLLxR; -- Constants for the PMC MCKR register package PMC_MCKR is PLLBDIV2 : constant := 2 ** 13; PLLADIV2 : constant := 2 ** 12; PRES_Mask : constant := 2#111# * 2 ** 4; CLK_1 : constant := 0 * 2 ** 4; CLK_2 : constant := 1 * 2 ** 4; CLK_4 : constant := 2 * 2 ** 4; CLK_8 : constant := 3 * 2 ** 4; CLK_16 : constant := 4 * 2 ** 4; CLK_32 : constant := 5 * 2 ** 4; CLK_64 : constant := 6 * 2 ** 4; CLK_3 : constant := 7 * 2 ** 4; CSS_Mask : constant := 2#11# * 2 ** 0; SLOW_CLK : constant := 0 * 2 ** 0; MAIN_CLK : constant := 1 * 2 ** 0; PLLA_CLK : constant := 2 * 2 ** 0; PLLB_CLK : constant := 3 * 2 ** 0; end PMC_MCKR; ---------------------------------------- -- Enhanced Embedded Flash Controller -- ---------------------------------------- type EEFC_Registers is record EEFC_FMR : Word; EEFC_FCR : Word; EEFC_FSR : Word; EEFC_FFR : Word; end record; -- Constants for the EEFC FMR register package EEFC_FMR is FRDY : constant := 2 ** 0; FWS : constant := 2 ** 8; SCOD : constant := 2 ** 16; FAM : constant := 2 ** 24; CLOE : constant := 2 ** 26; end EEFC_FMR; EFC0 : EEFC_Registers with Volatile, Import, Address => System'To_Address (EFC0_Base); -------------------------------------- -- Parallel Input/Output Controller -- -------------------------------------- type PIO_Registers is record PER : Word; PDR : Word; PSR : Word; Pad0 : Word; OER : Word; ODR : Word; OSR : Word; Pad1 : Word; IFER : Word; IFDR : Word; IFSR : Word; Pad2 : Word; SODR : Word; CODR : Word; ODSR : Word; PDSR : Word; IER : Word; IDR : Word; IMR : Word; ISR : Word; MDER : Word; MDDR : Word; MDSR : Word; Pad5 : Word; PUDR : Word; PUER : Word; PUSR : Word; Pad6 : Word; ABCDSR1 : Word; ABCDSR2 : Word; Pad7_8 : Word; Pad7_C : Word; IFSCDR : Word; IFSCER : Word; IFSCSR : Word; SCDR : Word; PPDDR : Word; PPDER : Word; PPDSR : Word; Pad9 : Word; OWER : Word; OWDR : Word; OWSR : Word; Pada : Word; AIMER : Word; AIMDR : Word; AIMMR : Word; Padb : Word; ESR : Word; LSR : Word; ELSR : Word; Padc : Word; FELLSR : Word; REHLSR : Word; FRLHSR : Word; Padd : Word; LOCKSR : Word; WPMR : Word; WPSR : Word; PadE_C : Word; end record; PIOA : PIO_Registers with Volatile, Import, Address => System'To_Address (PIOA_Base); PIOB : PIO_Registers with Volatile, Import, Address => System'To_Address (PIOB_Base); PIOC : PIO_Registers with Volatile, Import, Address => System'To_Address (PIOC_Base); PIOA_ID : constant := 11; PIOB_ID : constant := 12; PIOC_ID : constant := 13; ---------------------------------- -- Serial Peripheral Interface -- ---------------------------------- type SPI_Registers is record SPI_CR : Word; SPI_MR : Word; SPI_RDR : Word; SPI_TDR : Word; SPI_SR : Word; SPI_IER : Word; SPI_IDR : Word; SPI_IMR : Word; Pad_20 : Word; Pad_24 : Word; Pad_28 : Word; Pad_2c : Word; SPI_CSR0 : Word; SPI_CSR1 : Word; SPI_CSR2 : Word; SPI_CSR3 : Word; -- ... end record; -- Constants for the SPI CR register package SPI_CR is SPIEN : constant := 2 ** 0; SPIDIS : constant := 2 ** 1; SWRST : constant := 2 ** 7; LASTXFER : constant := 2 ** 24; end SPI_CR; -- Constants for the SPI MR register package SPI_MR is MSTR : constant := 2 ** 0; PS : constant := 2 ** 1; PCSDEC : constant := 2 ** 2; MODFDIS : constant := 2 ** 4; WDRBT : constant := 2 ** 5; LLB : constant := 2 ** 7; PCS : constant := 2 ** 16; PCS_Mask : constant := 2#1111# * PCS; DLYBCS : constant := 2 ** 16; DLYBCS_Mask : constant := 16#ff# * DLYBCS; end SPI_MR; -- Constants for the SPI TDR register package SPI_TDR is TD : constant := 2 ** 0; PCS : constant := 2 ** 16; LASTXFER : constant := 2 ** 24; end SPI_TDR; -- Constants for the SPI SR register; also used by the SPI IER, IDR and -- IMR registers. package SPI_SR is RDRF : constant := 2 ** 0; TDRE : constant := 2 ** 1; MODF : constant := 2 ** 2; OVRES : constant := 2 ** 3; ENDRX : constant := 2 ** 4; ENDTX : constant := 2 ** 5; RXBUFF : constant := 2 ** 6; TXBUFE : constant := 2 ** 7; NSSR : constant := 2 ** 8; TXEMPTY : constant := 2 ** 9; UNDES : constant := 2 ** 10; SPIENS : constant := 2 ** 16; end SPI_SR; -- Constants for the SPI CSR register package SPI_CSR is CPOL : constant := 2 ** 0; NCPHA : constant := 2 ** 1; CSNAAT : constant := 2 ** 2; CSAAT : constant := 2 ** 3; BITS : constant := 2 ** 4; SCBR : constant := 2 ** 8; DLYBS : constant := 2 ** 16; DLYBCT : constant := 2 ** 24; end SPI_CSR; SPI : SPI_Registers with Volatile, Import, Address => System'To_Address (SPI_Base); SPI_ID : constant := 21; -------------------- -- Watchdog Timer -- -------------------- type WDT_Registers is record WDT_CR : Word; WDT_MR : Word; WDT_SR : Word; end record; -- Constants for the WDT CR register package WDT_CR is KEY : constant := 16#a5_00_00_00#; WDRSTT : constant := 2 ** 0; end WDT_CR; -- Constants for the WDT MR register package WDT_MR is WDV : constant := 2 ** 0; WDFIEN : constant := 2 ** 2; WDRSTEN : constant := 2 ** 13; WDDPROC : constant := 2 ** 14; WDDIS : constant := 2 ** 15; WDD : constant := 2 ** 16; WDDBGHLT : constant := 2 ** 13; WDIDLEHLT : constant := 2 ** 13; end WDT_MR; WDT : WDT_Registers with Volatile, Import, Address => System'To_Address (WDT_Base); ------------------------------------------------- -- Universal Asynchronous Receiver Transmitter -- ------------------------------------------------- type UART_Registers is record UART_CR : Word; UART_MR : Word; UART_IER : Word; UART_IDR : Word; UART_IMR : Word; UART_SR : Word; UART_RHR : Word; UART_THR : Word; UART_BRGR : Word; end record; -- Constants for the UART CR register package UART_CR is RSTRX : constant := 2 ** 2; RSTTX : constant := 2 ** 3; RXEN : constant := 2 ** 4; RXDIS : constant := 2 ** 5; TXEN : constant := 2 ** 6; TXDIS : constant := 2 ** 7; RSTSTA : constant := 2 ** 8; end UART_CR; -- Constants for the UART MR register package UART_MR is CHMODE_NORMAL : constant := 0 * 2 ** 14; CHMODE_AUTOMATIC : constant := 1 * 2 ** 14; CHMODE_LOCAL_LOOPBACK : constant := 2 * 2 ** 14; CHMODE_REMOTE_LOOPBACK : constant := 3 * 2 ** 14; PAR_EVEN : constant := 0 * 2 ** 9; PAR_ODD : constant := 1 * 2 ** 9; PAR_SPACE : constant := 2 * 2 ** 9; PAR_MARK : constant := 3 * 2 ** 9; PAR_NO : constant := 4 * 2 ** 9; end UART_MR; -- Constants for the UART SR register package UART_SR is RXRDY : constant := 2 ** 0; TXRDY : constant := 2 ** 1; ENDRX : constant := 2 ** 3; ENDTX : constant := 2 ** 4; OVRE : constant := 2 ** 5; FRAME : constant := 2 ** 6; PARE : constant := 2 ** 7; TXEMPTY : constant := 2 ** 9; TXBUFE : constant := 2 ** 11; RXBUFF : constant := 2 ** 12; end UART_SR; UART0 : UART_Registers with Volatile, Import, Address => System'To_Address (UART0_Base); UART1 : UART_Registers with Volatile, Import, Address => System'To_Address (UART1_Base); UART0_ID : constant := 8; UART1_ID : constant := 9; end System.SAM4S;
pragma License (Unrestricted); -- implementation unit required by compiler with Ada.Streams; package System.Shared_Storage is -- no-operation procedure Nop (Key : String) is null; function Nop (Key : String) return access Ada.Streams.Root_Stream_Type'Class is (null); type Lock_Handler is access procedure (Key : String); Lock_Hook : not null Lock_Handler := Nop'Access; type Unlock_Handler is access procedure (Key : String); Unlock_Hook : not null Unlock_Handler := Nop'Access; type Read_Handler is access function (Key : String) return access Ada.Streams.Root_Stream_Type'Class; Read_Hook : not null Read_Handler := Nop'Access; type Write_Handler is access function (Key : String) return access Ada.Streams.Root_Stream_Type'Class; Write_Hook : not null Write_Handler := Nop'Access; -- required for a protected in a package with pragma Shared_Passive -- by compiler (s-shasto.ads) procedure Shared_Var_Lock (Var : String); procedure Shared_Var_Unlock (Var : String); -- required for a variable in a package with pragma Shared_Passive -- by compiler (s-shasto.ads) generic type Typ is limited private; V : in out Typ; Full_Name : String; package Shared_Var_Procs is procedure Read; procedure Write; end Shared_Var_Procs; end System.Shared_Storage;
-- Copyright 2017-2019 Free Software Foundation, Inc. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. package body Pck is procedure Inspect (Obj: access Top_T'Class) is begin null; end Inspect; end Pck;
-- Copyright (c) 2019 Maxim Reznik <reznikmm@gmail.com> -- -- SPDX-License-Identifier: MIT -- License-Filename: LICENSE ------------------------------------------------------------- with Slim.Message_Visiters; package body Slim.Messages.cont is List : constant Field_Description_Array := ((Uint_32_Field, 1), -- Metaint (Uint_8_Field, 1), -- Loop (Uint_16_Field, 1)); -- Guids count ---------- -- Read -- ---------- overriding function Read (Data : not null access League.Stream_Element_Vectors .Stream_Element_Vector) return Cont_Message is begin return Result : Cont_Message do Read_Fields (Result, List, Data.all); end return; end Read; ----------------- -- Set_Metaint -- ----------------- not overriding procedure Set_Metaint (Self : in out Cont_Message; Value : Natural) is begin Self.Data_32 := (1 => Interfaces.Unsigned_32 (Value)); Self.Data_16 := (1 => 0); -- No guids Self.Data_8 := (1 => 0); -- No loop end Set_Metaint; ----------- -- Visit -- ----------- overriding procedure Visit (Self : not null access Cont_Message; Visiter : in out Slim.Message_Visiters.Visiter'Class) is begin Visiter.cont (Self); end Visit; ----------- -- Write -- ----------- overriding procedure Write (Self : Cont_Message; Tag : out Message_Tag; Data : out League.Stream_Element_Vectors.Stream_Element_Vector) is begin Tag := "cont"; Write_Fields (Self, List, Data); end Write; end Slim.Messages.cont;
with Ada.Exceptions.Finally; with Ada.Unchecked_Conversion; with Ada.Unchecked_Deallocation; with System; package body Ada.Containers.Indefinite_Doubly_Linked_Lists is use type Base.Node_Access; use type Copy_On_Write.Data_Access; use type System.Address; function Upcast is new Unchecked_Conversion (Cursor, Base.Node_Access); function Downcast is new Unchecked_Conversion (Base.Node_Access, Cursor); function Upcast is new Unchecked_Conversion (Data_Access, Copy_On_Write.Data_Access); function Downcast is new Unchecked_Conversion (Copy_On_Write.Data_Access, Data_Access); procedure Free is new Unchecked_Deallocation (Node, Cursor); procedure Free is new Unchecked_Deallocation (Element_Type, Element_Access); type Context_Type is limited record Left : not null access Element_Type; end record; pragma Suppress_Initialization (Context_Type); function Equivalent_Element ( Right : not null Base.Node_Access; Params : System.Address) return Boolean; function Equivalent_Element ( Right : not null Base.Node_Access; Params : System.Address) return Boolean is Context : Context_Type; for Context'Address use Params; begin return Context.Left.all = Downcast (Right).Element.all; end Equivalent_Element; procedure Allocate_Element ( Item : out not null Element_Access; New_Item : Element_Type); procedure Allocate_Element ( Item : out not null Element_Access; New_Item : Element_Type) is begin Item := new Element_Type'(New_Item); end Allocate_Element; procedure Allocate_Node (Item : out Cursor; New_Item : Element_Type); procedure Allocate_Node (Item : out Cursor; New_Item : Element_Type) is package Holder is new Exceptions.Finally.Scoped_Holder (Cursor, Free); X : aliased Cursor := new Node; begin Holder.Assign (X); Allocate_Element (X.Element, New_Item); Holder.Clear; Item := X; end Allocate_Node; procedure Copy_Node ( Target : out Base.Node_Access; Source : not null Base.Node_Access); procedure Copy_Node ( Target : out Base.Node_Access; Source : not null Base.Node_Access) is New_Node : Cursor; begin Allocate_Node (New_Node, Downcast (Source).Element.all); Target := Upcast (New_Node); end Copy_Node; procedure Free_Node (Object : in out Base.Node_Access); procedure Free_Node (Object : in out Base.Node_Access) is X : Cursor := Downcast (Object); begin Free (X.Element); Free (X); Object := null; end Free_Node; procedure Allocate_Data ( Target : out not null Copy_On_Write.Data_Access; New_Length : Count_Type; Capacity : Count_Type); procedure Allocate_Data ( Target : out not null Copy_On_Write.Data_Access; New_Length : Count_Type; Capacity : Count_Type) is pragma Unreferenced (New_Length); pragma Unreferenced (Capacity); New_Data : constant Data_Access := new Data'(Super => <>, First => null, Last => null, Length => 0); begin Target := Upcast (New_Data); end Allocate_Data; procedure Copy_Data ( Target : out not null Copy_On_Write.Data_Access; Source : not null Copy_On_Write.Data_Access; Length : Count_Type; New_Length : Count_Type; Capacity : Count_Type); procedure Copy_Data ( Target : out not null Copy_On_Write.Data_Access; Source : not null Copy_On_Write.Data_Access; Length : Count_Type; New_Length : Count_Type; Capacity : Count_Type) is pragma Unreferenced (Length); pragma Unreferenced (New_Length); pragma Unreferenced (Capacity); begin Allocate_Data (Target, 0, 0); Base.Copy ( Downcast (Target).First, Downcast (Target).Last, Downcast (Target).Length, Source_Last => Downcast (Source).Last, Copy => Copy_Node'Access); end Copy_Data; procedure Free is new Unchecked_Deallocation (Data, Data_Access); procedure Free_Data (Data : in out Copy_On_Write.Data_Access); procedure Free_Data (Data : in out Copy_On_Write.Data_Access) is X : Data_Access := Downcast (Data); begin Base.Free (X.First, X.Last, X.Length, Free => Free_Node'Access); Free (X); Data := null; end Free_Data; procedure Unique (Container : in out List; To_Update : Boolean); procedure Unique (Container : in out List; To_Update : Boolean) is begin if Copy_On_Write.Shared (Container.Super.Data) then Copy_On_Write.Unique ( Target => Container.Super'Access, To_Update => To_Update, Allocate => Allocate_Data'Access, Move => Copy_Data'Access, Copy => Copy_Data'Access, Free => Free_Data'Access); end if; end Unique; -- implementation function Empty_List return List is begin return (Finalization.Controlled with Super => (null, null)); end Empty_List; function Has_Element (Position : Cursor) return Boolean is begin return Position /= null; end Has_Element; overriding function "=" (Left, Right : List) return Boolean is function Equivalent (Left, Right : not null Base.Node_Access) return Boolean; function Equivalent (Left, Right : not null Base.Node_Access) return Boolean is begin return Downcast (Left).Element.all = Downcast (Right).Element.all; end Equivalent; Left_Length : constant Count_Type := Length (Left); Right_Length : constant Count_Type := Length (Right); begin if Left_Length /= Right_Length then return False; elsif Left_Length = 0 or else Left.Super.Data = Right.Super.Data then return True; else Unique (Left'Unrestricted_Access.all, False); -- private Unique (Right'Unrestricted_Access.all, False); -- private return Base.Equivalent ( Downcast (Left.Super.Data).Last, Downcast (Right.Super.Data).Last, Equivalent => Equivalent'Access); end if; end "="; function Length (Container : List) return Count_Type is Data : constant Data_Access := Downcast (Container.Super.Data); begin if Data = null then return 0; else return Data.Length; end if; end Length; function Is_Empty (Container : List) return Boolean is Data : constant Data_Access := Downcast (Container.Super.Data); begin return Data = null or else Data.Last = null; end Is_Empty; procedure Clear (Container : in out List) is begin Copy_On_Write.Clear (Container.Super'Access, Free => Free_Data'Access); end Clear; function Element (Position : Cursor) return Element_Type is begin return Position.Element.all; end Element; procedure Replace_Element ( Container : in out List; Position : Cursor; New_Item : Element_Type) is begin Unique (Container, True); Free (Position.Element); Allocate_Element (Position.Element, New_Item); end Replace_Element; procedure Query_Element ( Position : Cursor; Process : not null access procedure (Element : Element_Type)) is begin Process (Position.Element.all); end Query_Element; procedure Update_Element ( Container : in out List'Class; Position : Cursor; Process : not null access procedure (Element : in out Element_Type)) is begin Process (Reference (List (Container), Position).Element.all); end Update_Element; function Constant_Reference (Container : aliased List; Position : Cursor) return Constant_Reference_Type is pragma Unreferenced (Container); begin return (Element => Position.Element.all'Access); end Constant_Reference; function Reference (Container : aliased in out List; Position : Cursor) return Reference_Type is begin -- diff Unique (Container, True); return (Element => Position.Element.all'Access); end Reference; procedure Assign (Target : in out List; Source : List) is begin Copy_On_Write.Assign ( Target.Super'Access, Source.Super'Access, Free => Free_Data'Access); end Assign; function Copy (Source : List) return List is begin return Result : List do Copy_On_Write.Copy ( Result.Super'Access, Source.Super'Access, Allocate => Allocate_Data'Access, Copy => Copy_Data'Access); end return; end Copy; procedure Move (Target : in out List; Source : in out List) is begin Copy_On_Write.Move ( Target.Super'Access, Source.Super'Access, Free => Free_Data'Access); -- diff -- diff -- diff -- diff -- diff end Move; procedure Insert ( Container : in out List; Before : Cursor; New_Item : Element_Type; Count : Count_Type := 1) is Position : Cursor; begin Insert (Container, Before, New_Item, Position, Count); end Insert; procedure Insert ( Container : in out List; Before : Cursor; New_Item : Element_Type; Position : out Cursor; Count : Count_Type := 1) is begin Position := Before; if Count > 0 then Unique (Container, True); for I in 1 .. Count loop declare Data : constant Data_Access := Downcast (Container.Super.Data); -- diff New_Node : Cursor; begin Allocate_Node (New_Node, New_Item); -- diff -- diff Base.Insert ( Data.First, Data.Last, Data.Length, Before => Upcast (Position), New_Item => Upcast (New_Node)); Position := New_Node; end; end loop; end if; end Insert; -- diff (Insert) -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- procedure Prepend ( Container : in out List; New_Item : Element_Type; Count : Count_Type := 1) is begin Insert (Container, First (Container), New_Item, Count); end Prepend; procedure Append ( Container : in out List; New_Item : Element_Type; Count : Count_Type := 1) is begin Insert (Container, null, New_Item, Count); end Append; procedure Delete ( Container : in out List; Position : in out Cursor; Count : Count_Type := 1) is begin if Count > 0 then Unique (Container, True); for I in 1 .. Count loop declare Data : constant Data_Access := Downcast (Container.Super.Data); X : Base.Node_Access; Next : Base.Node_Access; begin X := Upcast (Position); Next := Base.Next (Upcast (Position)); Base.Remove ( Data.First, Data.Last, Data.Length, Position => X, Next => Next); Free_Node (X); Position := Downcast (Next); end; end loop; Position := No_Element; end if; end Delete; procedure Delete_First ( Container : in out List'Class; Count : Count_Type := 1) is Position : Cursor := First (List (Container)); begin Delete (List (Container), Position, Count); end Delete_First; procedure Delete_Last ( Container : in out List'Class; Count : Count_Type := 1) is Position : Cursor := Last (List (Container)); begin for I in 1 .. Count loop declare Previous_Position : constant Cursor := Previous (Position); begin Delete (List (Container), Position); Position := Previous_Position; end; end loop; end Delete_Last; procedure Reverse_Elements (Container : in out List) is begin if Length (Container) > 1 then Unique (Container, True); declare Data : constant Data_Access := Downcast (Container.Super.Data); begin Base.Reverse_Elements ( Data.First, Data.Last, Data.Length); end; end if; end Reverse_Elements; procedure Swap (Container : in out List; I, J : Cursor) is begin Unique (Container, True); declare Temp : constant Element_Access := I.Element; begin I.Element := J.Element; J.Element := Temp; end; end Swap; procedure Swap_Links (Container : in out List; I, J : Cursor) is begin Unique (Container, True); declare Data : constant Data_Access := Downcast (Container.Super.Data); begin Base.Swap_Links ( Data.First, Data.Last, Upcast (I), Upcast (J)); end; end Swap_Links; procedure Splice ( Target : in out List; Before : Cursor; Source : in out List) is begin if Target'Address /= Source'Address then Unique (Target, True); Unique (Source, True); declare Target_Data : constant Data_Access := Downcast (Target.Super.Data); Source_Data : constant Data_Access := Downcast (Source.Super.Data); begin Base.Splice ( Target_Data.First, Target_Data.Last, Target_Data.Length, Upcast (Before), Source_Data.First, Source_Data.Last, Source_Data.Length); end; end if; end Splice; procedure Splice ( Target : in out List; Before : Cursor; Source : in out List; Position : in out Cursor) is begin if Before /= Position then -- RM A.18.3(114/3) Unique (Target, True); Unique (Source, True); declare Target_Data : constant Data_Access := Downcast (Target.Super.Data); Source_Data : constant Data_Access := Downcast (Source.Super.Data); begin Base.Remove ( Source_Data.First, Source_Data.Last, Source_Data.Length, Upcast (Position), Base.Next (Upcast (Position))); Base.Insert ( Target_Data.First, Target_Data.Last, Target_Data.Length, Upcast (Before), Upcast (Position)); end; end if; end Splice; procedure Splice ( Container : in out List; Before : Cursor; Position : Cursor) is begin if Before /= Position then -- RM A.18.3(116/3) Unique (Container, True); declare Data : constant Data_Access := Downcast (Container.Super.Data); begin Base.Remove ( Data.First, Data.Last, Data.Length, Upcast (Position), Base.Next (Upcast (Position))); Base.Insert ( Data.First, Data.Last, Data.Length, Upcast (Before), Upcast (Position)); end; end if; end Splice; function First (Container : List) return Cursor is begin if Is_Empty (Container) then return null; else Unique (Container'Unrestricted_Access.all, False); return Downcast (Downcast (Container.Super.Data).First); end if; end First; function First_Element (Container : List'Class) return Element_Type is begin return Element (First (List (Container))); end First_Element; function Last (Container : List) return Cursor is begin if Is_Empty (Container) then return null; else Unique (Container'Unrestricted_Access.all, False); return Downcast (Downcast (Container.Super.Data).Last); end if; end Last; function Last_Element (Container : List'Class) return Element_Type is begin return Element (Last (List (Container))); end Last_Element; function Next (Position : Cursor) return Cursor is begin return Downcast (Base.Next (Upcast (Position))); end Next; function Previous (Position : Cursor) return Cursor is begin return Downcast (Base.Previous (Upcast (Position))); end Previous; procedure Next (Position : in out Cursor) is begin Position := Downcast (Base.Next (Upcast (Position))); end Next; procedure Previous (Position : in out Cursor) is begin Position := Downcast (Base.Previous (Upcast (Position))); end Previous; function Find ( Container : List; Item : Element_Type) return Cursor is begin if Is_Empty (Container) then return null; else Unique (Container'Unrestricted_Access.all, False); declare Context : aliased Context_Type := (Left => Item'Unrestricted_Access); begin return Downcast (Base.Find ( Downcast (Container.Super.Data).First, Context'Address, Equivalent => Equivalent_Element'Access)); end; end if; end Find; function Find ( Container : List; Item : Element_Type; Position : Cursor) return Cursor is pragma Check (Pre, Check => (not Is_Empty (Container) and then Position /= No_Element) or else (Is_Empty (Container) and then Position = No_Element) or else raise Constraint_Error); Context : aliased Context_Type := (Left => Item'Unrestricted_Access); begin return Downcast (Base.Find ( Upcast (Position), Context'Address, Equivalent => Equivalent_Element'Access)); end Find; function Reverse_Find ( Container : List; Item : Element_Type) return Cursor is begin if Is_Empty (Container) then return null; else Unique (Container'Unrestricted_Access.all, False); declare Context : aliased Context_Type := (Left => Item'Unrestricted_Access); begin return Downcast ( Base.Reverse_Find ( Downcast (Container.Super.Data).Last, Context'Address, Equivalent => Equivalent_Element'Access)); end; end if; end Reverse_Find; function Reverse_Find ( Container : List; Item : Element_Type; Position : Cursor) return Cursor is pragma Check (Pre, Check => (not Is_Empty (Container) and then Position /= No_Element) or else (Is_Empty (Container) and then Position = No_Element) or else raise Constraint_Error); Context : aliased Context_Type := (Left => Item'Unrestricted_Access); begin return Downcast ( Base.Reverse_Find ( Upcast (Position), Context'Address, Equivalent => Equivalent_Element'Access)); end Reverse_Find; function Contains (Container : List; Item : Element_Type) return Boolean is begin return Find (Container, Item) /= null; end Contains; function "<" (Left, Right : Cursor) return Boolean is begin return Base.Is_Before (Upcast (Left), Upcast (Right)); end "<"; procedure Iterate ( Container : List'Class; Process : not null access procedure (Position : Cursor)) is type P1 is access procedure (Position : Cursor); type P2 is access procedure (Position : Base.Node_Access); function Cast is new Unchecked_Conversion (P1, P2); begin if not Is_Empty (List (Container)) then Unique (List (Container)'Unrestricted_Access.all, False); Base.Iterate ( Downcast (Container.Super.Data).First, Cast (Process)); end if; end Iterate; procedure Reverse_Iterate ( Container : List'Class; Process : not null access procedure (Position : Cursor)) is type P1 is access procedure (Position : Cursor); type P2 is access procedure (Position : Base.Node_Access); function Cast is new Unchecked_Conversion (P1, P2); begin if not Is_Empty (List (Container)) then Unique (List (Container)'Unrestricted_Access.all, False); Base.Reverse_Iterate ( Downcast (Container.Super.Data).Last, Cast (Process)); end if; end Reverse_Iterate; function Iterate (Container : List'Class) return List_Iterator_Interfaces.Reversible_Iterator'Class is begin return List_Iterator'( First => First (List (Container)), Last => Last (List (Container))); end Iterate; function Iterate (Container : List'Class; First, Last : Cursor) return List_Iterator_Interfaces.Reversible_Iterator'Class is pragma Unreferenced (Container); Actual_First : Cursor := First; Actual_Last : Cursor := Last; begin if Actual_First = No_Element or else Actual_Last = No_Element or else Actual_Last < Actual_First then Actual_First := No_Element; Actual_Last := No_Element; end if; return List_Iterator'(First => Actual_First, Last => Actual_Last); end Iterate; overriding procedure Adjust (Object : in out List) is begin Copy_On_Write.Adjust (Object.Super'Access); end Adjust; overriding function First (Object : List_Iterator) return Cursor is begin return Object.First; end First; overriding function Next (Object : List_Iterator; Position : Cursor) return Cursor is begin if Position = Object.Last then return No_Element; else return Next (Position); end if; end Next; overriding function Last (Object : List_Iterator) return Cursor is begin return Object.Last; end Last; overriding function Previous (Object : List_Iterator; Position : Cursor) return Cursor is begin if Position = Object.First then return No_Element; else return Previous (Position); end if; end Previous; package body Generic_Sorting is function LT (Left, Right : not null Base.Node_Access) return Boolean; function LT (Left, Right : not null Base.Node_Access) return Boolean is begin return Downcast (Left).Element.all < Downcast (Right).Element.all; end LT; function Is_Sorted (Container : List) return Boolean is begin if Length (Container) <= 1 then return True; else Unique (Container'Unrestricted_Access.all, False); -- private return Base.Is_Sorted ( Downcast (Container.Super.Data).Last, LT => LT'Access); end if; end Is_Sorted; procedure Sort (Container : in out List) is begin if Length (Container) > 1 then Unique (Container, True); declare Data : constant Data_Access := Downcast (Container.Super.Data); begin Base.Merge_Sort ( Data.First, Data.Last, Data.Length, LT => LT'Access); end; end if; end Sort; procedure Merge (Target : in out List; Source : in out List) is pragma Check (Pre, Check => Target'Address /= Source'Address or else Is_Empty (Target) or else raise Program_Error); -- RM A.18.3(151/3), same nonempty container begin if not Is_Empty (Source) then if Is_Empty (Target) then Move (Target, Source); else Unique (Target, True); Unique (Source, True); declare Target_Data : constant Data_Access := Downcast (Target.Super.Data); Source_Data : constant Data_Access := Downcast (Source.Super.Data); begin Base.Merge ( Target_Data.First, Target_Data.Last, Target_Data.Length, Source_Data.First, Source_Data.Last, Source_Data.Length, LT => LT'Access); end; end if; end if; end Merge; end Generic_Sorting; package body Streaming is procedure Read ( Stream : not null access Streams.Root_Stream_Type'Class; Item : out List) is Length : Count_Type'Base; begin Count_Type'Base'Read (Stream, Length); Clear (Item); for I in 1 .. Length loop declare New_Item : constant Element_Type := Element_Type'Input (Stream); begin Insert (Item, null, New_Item); -- diff end; end loop; end Read; procedure Write ( Stream : not null access Streams.Root_Stream_Type'Class; Item : List) is Length : constant Count_Type := Indefinite_Doubly_Linked_Lists.Length (Item); begin Count_Type'Write (Stream, Length); if Length > 0 then declare Position : Cursor := First (Item); begin while Position /= null loop Element_Type'Output (Stream, Position.Element.all); Next (Position); end loop; end; end if; end Write; end Streaming; end Ada.Containers.Indefinite_Doubly_Linked_Lists;
----------------------------------------------------------------------- -- util-streams-encoders -- Streams with encoding and decoding capabilities -- Copyright (C) 2017, 2018, 2019, 2021 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- package body Util.Streams.Buffered.Encoders is -- ----------------------- -- Initialize the stream with a buffer of <b>Size</b> bytes. -- ----------------------- procedure Initialize (Stream : in out Encoder_Stream; Size : in Positive) is begin Buffer_Stream (Stream).Initialize (Size); Stream.No_Flush := True; end Initialize; -- ----------------------- -- Initialize the stream to write on the given stream. -- An internal buffer is allocated for writing the stream. -- ----------------------- -- overriding procedure Produces (Stream : in out Encoder_Stream; Output : access Output_Stream'Class; Size : in Positive) is begin Stream.Initialize (Size); Stream.Output := Output; Stream.No_Flush := False; end Produces; -- ----------------------- -- Initialize the stream to read the given streams. -- ----------------------- procedure Consumes (Stream : in out Encoder_Stream; Input : access Input_Stream'Class; Size : in Positive) is begin Stream.Initialize (Size); Stream.Input := Input; end Consumes; -- ----------------------- -- Close the sink. -- ----------------------- overriding procedure Close (Stream : in out Encoder_Stream) is begin Stream.Flush; if Stream.Output /= null then Stream.Output.Close; end if; end Close; -- ----------------------- -- Write the buffer array to the output stream. -- ----------------------- overriding procedure Write (Stream : in out Encoder_Stream; Buffer : in Ada.Streams.Stream_Element_Array) is First_Encoded : Ada.Streams.Stream_Element_Offset := Buffer'First; Last_Encoded : Ada.Streams.Stream_Element_Offset; Last_Pos : Ada.Streams.Stream_Element_Offset; begin while First_Encoded <= Buffer'Last loop Stream.Transform.Transform (Data => Buffer (First_Encoded .. Buffer'Last), Into => Stream.Buffer (Stream.Write_Pos .. Stream.Buffer'Last), Last => Last_Pos, Encoded => Last_Encoded); if Last_Encoded < Buffer'Last or else Last_Pos = Stream.Buffer'Last then Stream.Output.Write (Stream.Buffer (Stream.Buffer'First .. Last_Pos)); Stream.Write_Pos := Stream.Buffer'First; else Stream.Write_Pos := Last_Pos + 1; end if; First_Encoded := Last_Encoded + 1; end loop; end Write; -- ------------------------------ -- Fill the buffer by reading the input stream. -- Raises Data_Error if there is no input stream; -- ------------------------------ procedure Fill (Stream : in out Encoder_Stream) is begin if Stream.Input = null then Stream.Eof := True; else Stream.Input.Read (Stream.Buffer (1 .. Stream.Last), Stream.Write_Pos); Stream.Eof := Stream.Write_Pos < 1; if not Stream.Eof then Stream.Write_Pos := Stream.Write_Pos + 1; end if; Stream.Read_Pos := 1; end if; end Fill; -- ----------------------- -- Read into the buffer as many bytes as possible and return in -- `last` the position of the last byte read. -- ----------------------- overriding procedure Read (Stream : in out Encoder_Stream; Into : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset) is Start : Stream_Element_Offset := Into'First; Pos : Stream_Element_Offset := Stream.Read_Pos; Avail : Stream_Element_Offset; Last_Decoded : Ada.Streams.Stream_Element_Offset; Last_Pos : Ada.Streams.Stream_Element_Offset; begin while Start <= Into'Last loop Avail := Stream.Write_Pos - Pos; if Avail = 0 then Stream.Fill; Pos := Stream.Read_Pos; Avail := Stream.Write_Pos - Pos; if Avail <= 0 then Last := Start - 1; Stream.Transform.Finish (Into => Into (Start .. Into'Last), Last => Last); return; end if; end if; Stream.Transform.Transform (Data => Stream.Buffer (Pos .. Pos + Avail - 1), Into => Into (Start .. Into'Last), Last => Last_Pos, Encoded => Last_Decoded); Stream.Read_Pos := Last_Decoded + 1; Start := Last_Pos + 1; exit when Stream.Read_Pos = Pos; Pos := Stream.Read_Pos; end loop; Last := Start - 1; end Read; -- ----------------------- -- Flush the buffer by writing on the output stream. -- Raises Data_Error if there is no output stream. -- ----------------------- overriding procedure Flush (Stream : in out Encoder_Stream) is Last_Pos : Ada.Streams.Stream_Element_Offset := Stream.Write_Pos - 1; begin if not Stream.Flushed and then Stream.Buffer /= null and then Stream.Write_Pos >= Stream.Buffer'First then Stream.Transform.Finish (Stream.Buffer (Stream.Write_Pos .. Stream.Buffer'Last), Last_Pos); Stream.Write_Pos := Last_Pos + 1; if not Stream.No_Flush then if Stream.Write_Pos > 1 then if Stream.Output /= null then Stream.Output.Write (Stream.Buffer (1 .. Stream.Write_Pos - 1)); end if; Stream.Write_Pos := 1; end if; if Stream.Output /= null then Stream.Output.Flush; end if; end if; Stream.Flushed := True; end if; end Flush; overriding procedure Finalize (Stream : in out Encoder_Stream) is begin if not Stream.Flushed and then Stream.Buffer /= null then Stream.Flush; end if; Buffer_Stream (Stream).Finalize; end Finalize; end Util.Streams.Buffered.Encoders;
----------------------------------------------------------------------- -- Jason-test -- Unit tests -- Copyright (C) 2016, 2019 Stephane.Carrez -- Written by Stephane.Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Tests; with Jason.Testsuite; procedure Jason_Harness is procedure Harness is new Util.Tests.Harness (Jason.Testsuite.Suite, Jason.Testsuite.Initialize); begin Harness ("jason-tests.xml"); end Jason_Harness;
private with ada.Calendar; package openGL.frame_Counter -- -- A utility which reports frames per second. -- is type Item is tagged private; procedure increment (Self : in out Item); private type Item is tagged record frame_Count : Natural := 0; next_FPS_Time : ada.Calendar.Time := ada.Calendar.Clock; end record; end openGL.frame_Counter;
------------------------------------------------------------------------------ -- Copyright (C) 2020 by Heisenbug Ltd. (gh+flacada@heisenbug.eu) -- -- This work is free. You can redistribute it and/or modify it under the -- terms of the Do What The Fuck You Want To Public License, Version 2, -- as published by Sam Hocevar. See the LICENSE file for more details. ------------------------------------------------------------------------------ pragma License (Unrestricted); with Ada.Text_IO; package body Flac.Debug with SPARK_Mode => On is --------------------------------------------------------------------------- -- Print_Stream_Info --------------------------------------------------------------------------- procedure Print_Stream_Info (Handle : Flac.Reader.File_Handle) with SPARK_Mode => Off is use Flac.Reader; begin Ada.Text_IO.Put_Line (Item => "Channels(S) :" & Num_Channels (Handle => Handle)'Image); Ada.Text_IO.Put_Line (Item => "Sample_Size(S) :" & Bits_Per_Sample (Handle => Handle)'Image); Ada.Text_IO.Put_Line (Item => "Sample_Rate(S) :" & Sample_Rate (Handle => Handle)'Image); Ada.Text_IO.Put_Line (Item => "Sample_Count(S):" & Num_Samples (Handle => Handle)'Image); end Print_Stream_Info; --------------------------------------------------------------------------- -- Print_Frame_Info -- -- Print info about frame. --------------------------------------------------------------------------- procedure Print_Frame_Info (Frame : in Frames.T) with SPARK_Mode => Off is begin Ada.Text_IO.Put_Line (Item => "Blocking_Strategy(F) : " & Frame.Blocking_Strategy'Image); Ada.Text_IO.Put_Line (Item => "Block_Size(F) :" & Frame.Block_Size'Image); Ada.Text_IO.Put_Line (Item => "Sample_Rate(F) :" & Frame.Sample_Rate'Image); Ada.Text_IO.Put_Line (Item => "Channel_Assignment(F):" & Frame.Channel_Assignment'Image); Ada.Text_IO.Put_Line (Item => "Sample_Size(F) :" & Frame.Sample_Size'Image); end Print_Frame_Info; end Flac.Debug;
-- ___ _ ___ _ _ -- -- / __| |/ (_) | | Common SKilL implementation -- -- \__ \ ' <| | | |__ stream to skill tokens -- -- |___/_|\_\_|_|____| by: Timm Felden, Dennis Przytarski -- -- -- pragma Ada_2012; with Ada.Characters.Latin_1; with Ada.Unchecked_Conversion; with Ada.Unchecked_Deallocation; with Interfaces; with Skill.Types; with Interfaces.C.Strings; with System; with Skill.Errors; with System.Address_To_Access_Conversions; with System.Storage_Elements; package body Skill.Streams.Reader is use Skill; use type Uchar.Pointer; function Invalid_Pointer return Map_Pointer is pragma Warnings (Off); function Cast is new Ada.Unchecked_Conversion (Integer, Map_Pointer); begin return Cast (-1); end Invalid_Pointer; -- type used to represent empty input streams -- @note(TF) this is used to keep stream & map pointers not null function Empty_Stream return Input_Stream is begin return new Input_Stream_T' (Map => Invalid_Pointer, Base => Invalid_Pointer, EOF => Invalid_Pointer, Path => null, File => Interfaces.C_Streams.NULL_Stream); end Empty_Stream; function Open (Path : Types.String_Access) return Input_Stream is use type Skill.Types.String_Access; use type Interfaces.C.size_t; begin if null = Path then return Empty_Stream; end if; declare Cpath : Interfaces.C.Strings.chars_ptr := Interfaces.C.Strings.New_String (Path.all); Map : Mmap := MMap_Open (Cpath); Mf : aliased access Integer; for Mf'Address use Map.File'Address; pragma Import (Ada, Mf); Ml : aliased access Integer; for Ml'Address use Map.Length'Address; pragma Import (Ada, Ml); Mm : aliased access Integer; for Mm'Address use Map.Map'Address; pragma Import (Ada, Mm); begin Interfaces.C.Strings.Free (Cpath); if Mf = null and Ml = null and Mm = null then raise Skill.Errors.Skill_Error with "failed to open stream, see stdout for details"; end if; if 0 = Map.Length then return Empty_Stream; end if; return new Input_Stream_T' (Path => Path, File => Map.File, Map => Map.Map, Base => Map.Map, EOF => Map.Map + C.ptrdiff_t (Map.Length)); end; end Open; function Map (This : access Input_Stream_T; Base : Types.v64; First : Types.v64; Last : Types.v64) return Sub_Stream is use type Uchar.Pointer; use type Interfaces.Integer_64; function Cast is new Ada.Unchecked_Conversion (Map_Pointer, Types.v64); begin if Cast (This.EOF) < Cast (This.Base + C.ptrdiff_t (Base + Last)) then raise Constraint_Error with "Tried to read behind end of file."; end if; return new Sub_Stream_T' (Map => This.Base + C.ptrdiff_t (Base + First), Base => This.Base + C.ptrdiff_t (Base + First), EOF => This.Base + C.ptrdiff_t (Base + Last)); end Map; The_Empty_Sub_Stream : Sub_Stream := new Sub_Stream_T' (Map => Invalid_Pointer, Base => Invalid_Pointer, EOF => Invalid_Pointer); function Empty_Sub_Stream return Sub_Stream is (The_Empty_Sub_Stream); procedure Close (This : access Input_Stream_T) is type S is access all Input_Stream_T; procedure Delete is new Ada.Unchecked_Deallocation (Input_Stream_T, S); D : S := S (This); begin -- do not close fake files if Invalid_Pointer /= This.Map then MMap_Close (This.File); end if; Delete (D); end Close; procedure Free (This : access Sub_Stream_T) is type S is access all Sub_Stream_T; procedure Delete is new Ada.Unchecked_Deallocation (Sub_Stream_T, S); D : S := S (This); begin if S (This) /= S (The_Empty_Sub_Stream) then Delete (D); end if; end Free; function Path (This : access Input_Stream_T) return Skill.Types.String_Access is begin return This.Path; end Path; function Position (This : access Abstract_Stream'Class) return Skill.Types.v64 is begin return Types.v64 (This.Map - This.Base); end Position; procedure Check_Offset (This : access Abstract_Stream'Class; Pos : Skill.Types.v64) is use type Types.v64; begin if Types.v64 (This.EOF - This.Base) <= Pos then raise Constraint_Error with "Offset check failed, argument position is behind end of file."; end if; end Check_Offset; procedure Jump (This : access Abstract_Stream'Class; Pos : Skill.Types.v64) is begin This.Map := This.Base + C.ptrdiff_t (Pos); end Jump; function Eof (This : access Abstract_Stream'Class) return Boolean is use C; function Cast is new Ada.Unchecked_Conversion (Uchar.Pointer, Types.i64); use type Interfaces.Integer_64; begin return Cast (This.Map) >= Cast (This.EOF); end Eof; package Casts is new System.Address_To_Access_Conversions (C.unsigned_char); function Convert is new Ada.Unchecked_Conversion (Interfaces.C.unsigned_char, Skill.Types.i8); function Convert is new Ada.Unchecked_Conversion (Casts.Object_Pointer, Map_Pointer); function Convert is new Ada.Unchecked_Conversion (Map_Pointer, Casts.Object_Pointer); procedure Advance (P : in out Map_Pointer) is use C; use Uchar; use System.Storage_Elements; begin P := Convert (Casts.To_Pointer (Casts.To_Address (Convert (P)) + 1)); end Advance; pragma Inline_Always (Advance); function I8 (This : access Abstract_Stream'Class) return Skill.Types.i8 is use C; use Uchar; P : Map_Pointer := This.Map; R : Types.i8 := Convert (This.Map.all); begin Advance (P); This.Map := P; return R; end I8; function I16 (This : access Abstract_Stream'Class) return Skill.Types.i16 is use C; use Uchar; subtype Bytes is Unsigned_Char_Array (1 .. 2); function Convert is new Ada.Unchecked_Conversion (Bytes, Types.i16); P : Uchar.Pointer := This.Map; P1 : Uchar.Pointer := P + 1; R : Types.i16 := Convert (Bytes'(P1.all, This.Map.all)); begin This.Map := This.Map + 2; return R; end I16; function I32 (This : access Abstract_Stream'Class) return Skill.Types.i32 is use C; use Uchar; subtype Bytes is Unsigned_Char_Array (1 .. 4); function Convert is new Ada.Unchecked_Conversion (Bytes, Types.i32); P : Uchar.Pointer := This.Map; P1 : Uchar.Pointer := P + 1; P2 : Uchar.Pointer := P + 2; P3 : Uchar.Pointer := P + 3; R : Types.i32 := Convert (Bytes'(P3.all, P2.all, P1.all, This.Map.all)); begin This.Map := This.Map + 4; return R; end I32; function I64 (This : access Abstract_Stream'Class) return Skill.Types.i64 is use C; use Uchar; subtype Bytes is Unsigned_Char_Array (1 .. 8); function Convert is new Ada.Unchecked_Conversion (Bytes, Types.i64); P : Uchar.Pointer := This.Map; P1 : Uchar.Pointer := P + 1; P2 : Uchar.Pointer := P + 2; P3 : Uchar.Pointer := P + 3; P4 : Uchar.Pointer := P + 4; P5 : Uchar.Pointer := P + 5; P6 : Uchar.Pointer := P + 6; P7 : Uchar.Pointer := P + 7; R : Types.i64 := Convert (Bytes' (P7.all, P6.all, P5.all, P4.all, P3.all, P2.all, P1.all, This.Map.all)); begin This.Map := This.Map + 8; return R; end I64; function F32 (This : access Abstract_Stream'Class) return Skill.Types.F32 is function Cast is new Ada.Unchecked_Conversion (Types.i32, Types.F32); begin return Cast (This.I32); end F32; function F64 (This : access Abstract_Stream'Class) return Skill.Types.F64 is function Cast is new Ada.Unchecked_Conversion (Types.i64, Types.F64); begin return Cast (This.I64); end F64; function V64 (This : access Abstract_Stream'Class) return Skill.Types.v64 is use C; use Uchar; use type Interfaces.Unsigned_64; function Convert is new Ada.Unchecked_Conversion (Source => Types.Uv64, Target => Types.v64); P : Map_Pointer := This.Map; Bucket : C.unsigned_char := P.all; Return_Value : Types.Uv64 := Types.Uv64 (Bucket); begin Advance (P); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := (Return_Value and 16#7f#) or Interfaces.Shift_Left (Types.Uv64 (Bucket) and 16#7f#, 7); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := Return_Value or Interfaces.Shift_Left (Types.Uv64 (Bucket) and 16#7f#, 14); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := Return_Value or Interfaces.Shift_Left (Types.Uv64 (Bucket) and 16#7f#, 21); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := Return_Value or Interfaces.Shift_Left (Types.Uv64 (Bucket) and 16#7f#, 28); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := Return_Value or Interfaces.Shift_Left (Types.Uv64 (Bucket) and 16#7f#, 35); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := Return_Value or Interfaces.Shift_Left (Types.Uv64 (Bucket) and 16#7f#, 42); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := Return_Value or Interfaces.Shift_Left (Types.Uv64 (Bucket) and 16#7f#, 49); if 0 /= (Bucket and 16#80#) then Bucket := P.all; Advance (P); Return_Value := Return_Value or Interfaces.Shift_Left (Types.Uv64 (Bucket), 56); end if; end if; end if; end if; end if; end if; end if; end if; This.Map := P; return Convert (Return_Value); end V64; function Parse_Exception (This : access Input_Stream_T; Block_Counter : Positive; Cause : in Ada.Exceptions.Exception_Occurrence; Message : String) return String is begin return "Parse exception at" & Ada.Characters.Latin_1.LF & This.Path.all & Ada.Characters.Latin_1.LF & " position: " & Long_Integer'Image (Long_Integer (This.Position)) & Ada.Characters.Latin_1.LF & " block: " & Positive'Image (Block_Counter) & Ada.Characters.Latin_1.LF & " reason: " & Message & Ada.Characters.Latin_1.LF & " caused by: " & Ada.Exceptions.Exception_Information (Cause); end Parse_Exception; function Parse_Exception (This : access Input_Stream_T; Block_Counter : Positive; Message : String) return String is begin return "Parse exception at" & Ada.Characters.Latin_1.LF & This.Path.all & Ada.Characters.Latin_1.LF & " position: " & Long_Integer'Image (Long_Integer (This.Position)) & Ada.Characters.Latin_1.LF & " block: " & Positive'Image (Block_Counter) & Ada.Characters.Latin_1.LF & " reason: " & Message & Ada.Characters.Latin_1.LF; end Parse_Exception; end Skill.Streams.Reader;
-- SPDX-FileCopyrightText: 2019 Max Reznik <reznikmm@gmail.com> -- -- SPDX-License-Identifier: MIT ------------------------------------------------------------- with Program.Elements.Type_Definitions; with Program.Lexical_Elements; with Program.Elements.Expressions; package Program.Elements.Interface_Types is pragma Pure (Program.Elements.Interface_Types); type Interface_Type is limited interface and Program.Elements.Type_Definitions.Type_Definition; type Interface_Type_Access is access all Interface_Type'Class with Storage_Size => 0; not overriding function Progenitors (Self : Interface_Type) return Program.Elements.Expressions.Expression_Vector_Access is abstract; not overriding function Has_Limited (Self : Interface_Type) return Boolean is abstract; not overriding function Has_Task (Self : Interface_Type) return Boolean is abstract; not overriding function Has_Protected (Self : Interface_Type) return Boolean is abstract; not overriding function Has_Synchronized (Self : Interface_Type) return Boolean is abstract; type Interface_Type_Text is limited interface; type Interface_Type_Text_Access is access all Interface_Type_Text'Class with Storage_Size => 0; not overriding function To_Interface_Type_Text (Self : in out Interface_Type) return Interface_Type_Text_Access is abstract; not overriding function Limited_Token (Self : Interface_Type_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; not overriding function Task_Token (Self : Interface_Type_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; not overriding function Protected_Token (Self : Interface_Type_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; not overriding function Synchronized_Token (Self : Interface_Type_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; not overriding function Interface_Token (Self : Interface_Type_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; not overriding function And_Token (Self : Interface_Type_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; end Program.Elements.Interface_Types;
-- Copyright (C) 2015-2019 Free Software Foundation, Inc. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. with Pck; use Pck; procedure Foo_O508_021 is SSA : Signed_Simple_Array := (-1, 2, -3, 4); begin Update_Signed_Small (SSA (3)); -- STOP end Foo_O508_021;
------------------------------------------------------------------------------- -- LSE -- L-System Editor -- Author: Heziode -- -- License: -- MIT License -- -- Copyright (c) 2018 Quentin Dauprat (Heziode) <Heziode@protonmail.com> -- -- Permission is hereby granted, free of charge, to any person obtaining a -- copy of this software and associated documentation files (the "Software"), -- to deal in the Software without restriction, including without limitation -- the rights to use, copy, modify, merge, publish, distribute, sublicense, -- and/or sell copies of the Software, and to permit persons to whom the -- Software is furnished to do so, subject to the following conditions: -- -- The above copyright notice and this permission notice shall be included in -- all copies or substantial portions of the Software. -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -- FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -- DEALINGS IN THE SOFTWARE. ------------------------------------------------------------------------------- -- @description -- This package define a missing rule error. -- package LSE.Model.L_System.Error.Missing_Rule is type Instance is new LSE.Model.L_System.Error.Instance with null record; -- Axiom not found in input Error : exception; function Initialize return Instance; overriding function Get_Error (This : Instance) return String; end LSE.Model.L_System.Error.Missing_Rule;
-- Ada_GUI version of Random_Int -- -- Copyright (C) 2021 by PragmAda Software Engineering -- -- Released under the terms of the 3-Clause BSD License. See https://opensource.org/licenses/BSD-3-Clause -- -- Root of the package hierarchy package Random_Int is pragma Pure; end Random_Int;
-- part of AdaYaml, (c) 2017 Felix Krause -- released under the terms of the MIT license, see the file "copying.txt" private with Ada.Containers.Hashed_Maps; package Yaml.Events.Store is type Instance is limited new Refcount_Base with private; type Instance_Access is access all Instance; type Reference is tagged private; type Optional_Reference is tagged private; type Accessor (Data : not null access Instance) is limited null record with Implicit_Dereference => Data; type Anchor_Cursor is private; type Element_Cursor is private; function New_Store return Reference; function Value (Object : Reference) return Accessor; Null_Reference : constant Optional_Reference; function Value (Object : Optional_Reference) return Accessor with Pre => Object /= Null_Reference; function Optional (Object : Reference'Class) return Optional_Reference; function Required (Object : Optional_Reference'Class) return Reference; procedure Memorize (Object : in out Instance; Item : Event); procedure Force_Memorize (Object : in out Instance; Item : Event; Position : out Element_Cursor); function Find (Object : Instance; Alias : Text.Reference) return Anchor_Cursor; function Exists_In_Output (Position : Anchor_Cursor) return Boolean; procedure Set_Exists_In_Output (Object : in out Instance; Position : Anchor_Cursor); procedure Advance (Position : in out Element_Cursor); procedure Advance_At_Same_Level (Object : Instance; Position : in out Element_Cursor); No_Anchor : constant Anchor_Cursor; No_Element : constant Element_Cursor; procedure Clear (Object : in out Instance); procedure Copy (Source : in Instance; Target : in out Instance); type Stream_Instance is limited new Refcount_Base with private; type Stream_Instance_Access is access all Stream_Instance; type Stream_Reference is tagged private; type Optional_Stream_Reference is tagged private; type Stream_Accessor (Data : not null access Stream_Instance) is limited null record with Implicit_Dereference => Data; function Value (Object : Stream_Reference) return Stream_Accessor; function Next (Object : in out Stream_Instance) return Event; function Exists (Object : Optional_Stream_Reference) return Boolean; function Value (Object : Optional_Stream_Reference) return Stream_Accessor with Pre => Object.Exists; function Optional (Object : Stream_Reference'Class) return Optional_Stream_Reference with Post => Optional'Result.Exists; procedure Clear (Object : in out Optional_Stream_Reference) with Post => not Object.Exists; function First (Object : Instance; Position : Anchor_Cursor) return Event; function Element (Object : Instance; Position : Element_Cursor) return Event; function Retrieve (Object : Reference'Class; Position : Anchor_Cursor) return Stream_Reference with Pre => Position /= No_Anchor; function Retrieve (Object : Reference'Class; Position : Element_Cursor) return Stream_Reference with Pre => Position /= No_Element; function To_Element_Cursor (Position : Anchor_Cursor) return Element_Cursor; private type Anchor_Info is record Position : Positive; Has_Been_Output : Boolean; end record; package Anchor_To_Index is new Ada.Containers.Hashed_Maps (Text.Reference, Anchor_Info, Text.Hash, Text."="); type Anchor_Cursor is new Anchor_To_Index.Cursor; type Element_Cursor is new Natural; subtype Depth_Type is Integer with Static_Predicate => Depth_Type = Integer'First or Depth_Type >= 0; After_Annotation_End : constant Depth_Type := Integer'First; type Instance is limited new Event_Holder with record Anchor_Map : Anchor_To_Index.Map; Stream_Count : Natural := 0; Depth : Depth_Type := 0; end record; type Reference is new Ada.Finalization.Controlled with record Data : not null access Instance; end record; overriding procedure Adjust (Object : in out Reference); overriding procedure Finalize (Object : in out Reference); type Optional_Reference is new Ada.Finalization.Controlled with record Data : access Instance; end record; overriding procedure Adjust (Object : in out Optional_Reference); overriding procedure Finalize (Object : in out Optional_Reference); Null_Reference : constant Optional_Reference := (Ada.Finalization.Controlled with Data => null); No_Anchor : constant Anchor_Cursor := Anchor_Cursor (Anchor_To_Index.No_Element); No_Element : constant Element_Cursor := 0; type Stream_Instance is limited new Refcount_Base with record Object : Reference; Depth : Natural; Current : Positive; end record; overriding procedure Finalize (Object : in out Stream_Instance); type Stream_Reference is new Ada.Finalization.Controlled with record Data : not null access Stream_Instance; end record; overriding procedure Adjust (Object : in out Stream_Reference); overriding procedure Finalize (Object : in out Stream_Reference); type Optional_Stream_Reference is new Ada.Finalization.Controlled with record Data : access Stream_Instance; end record; overriding procedure Adjust (Object : in out Optional_Stream_Reference); overriding procedure Finalize (Object : in out Optional_Stream_Reference); end Yaml.Events.Store;
------------------------------------------------------------------------------ -- A d a r u n - t i m e s p e c i f i c a t i o n -- -- ASIS implementation for Gela project, a portable Ada compiler -- -- http://gela.ada-ru.org -- -- - - - - - - - - - - - - - - - -- -- Read copyright and license at the end of ada.ads file -- ------------------------------------------------------------------------------ -- $Revision: 209 $ $Date: 2013-11-30 21:03:24 +0200 (Сб., 30 нояб. 2013) $ with Ada.Strings.Wide_Wide_Bounded; generic with package Bounded is new Ada.Strings.Wide_Wide_Bounded.Generic_Bounded_Length (<>); package Ada.Wide_Wide_Text_IO.Bounded_IO is procedure Put (File : in File_Type; Item : in Bounded.Wide_Wide_Bounded_String); procedure Put (Item : in Bounded.Wide_Wide_Bounded_String); procedure Put_Line (File : in File_Type; Item : in Bounded.Wide_Wide_Bounded_String); procedure Put_Line (Item : in Bounded.Wide_Wide_Bounded_String); function Get_Line (File : in File_Type) return Bounded.Wide_Wide_Bounded_String; function Get_Line return Bounded.Wide_Wide_Bounded_String; procedure Get_Line (File : in File_Type; Item : out Bounded.Wide_Wide_Bounded_String); procedure Get_Line (Item : out Bounded.Wide_Wide_Bounded_String); end Ada.Wide_Wide_Text_IO.Bounded_IO;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- S Y S T E M . V X W O R K S . E X T -- -- -- -- S p e c -- -- -- -- Copyright (C) 2008-2014, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- ------------------------------------------------------------------------------ -- This package provides vxworks specific support functions needed -- by System.OS_Interface. -- This is the VxWorks 5 and VxWorks MILS version of this package with Interfaces.C; package System.VxWorks.Ext is pragma Preelaborate; subtype SEM_ID is Long_Integer; -- typedef struct semaphore *SEM_ID; type sigset_t is mod 2 ** Interfaces.C.long'Size; type t_id is new Long_Integer; subtype int is Interfaces.C.int; subtype unsigned is Interfaces.C.unsigned; type Interrupt_Handler is access procedure (parameter : System.Address); pragma Convention (C, Interrupt_Handler); type Interrupt_Vector is new System.Address; function Int_Lock return int; pragma Import (C, Int_Lock, "intLock"); function Int_Unlock (Old : int) return int; pragma Import (C, Int_Unlock, "intUnlock"); function Interrupt_Connect (Vector : Interrupt_Vector; Handler : Interrupt_Handler; Parameter : System.Address := System.Null_Address) return int; pragma Import (C, Interrupt_Connect, "intConnect"); function Interrupt_Context return int; pragma Import (C, Interrupt_Context, "intContext"); function Interrupt_Number_To_Vector (intNum : int) return Interrupt_Vector; pragma Import (C, Interrupt_Number_To_Vector, "__gnat_inum_to_ivec"); function semDelete (Sem : SEM_ID) return int; pragma Import (C, semDelete, "semDelete"); function Task_Cont (tid : t_id) return int; pragma Import (C, Task_Cont, "taskResume"); function Task_Stop (tid : t_id) return int; pragma Import (C, Task_Stop, "taskSuspend"); function kill (pid : t_id; sig : int) return int; pragma Import (C, kill, "kill"); function getpid return t_id; pragma Import (C, getpid, "taskIdSelf"); function Set_Time_Slice (ticks : int) return int; pragma Import (C, Set_Time_Slice, "kernelTimeSlice"); -------------------------------- -- Processor Affinity for SMP -- -------------------------------- function taskCpuAffinitySet (tid : t_id; CPU : int) return int; pragma Convention (C, taskCpuAffinitySet); -- For SMP run-times set the CPU affinity. -- For uniprocessor systems return ERROR status. function taskMaskAffinitySet (tid : t_id; CPU_Set : unsigned) return int; pragma Convention (C, taskMaskAffinitySet); -- For SMP run-times set the CPU mask affinity. -- For uniprocessor systems return ERROR status. end System.VxWorks.Ext;
------------------------------------------------------------------------------ -- -- -- GNAT LIBRARY COMPONENTS -- -- -- -- ADA.STRINGS.LESS_CASE_INSENSITIVE -- -- -- -- S p e c -- -- -- -- Copyright (C) 2004-2009, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- -- -- -- -- -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- This unit was originally developed by Matthew J Heaney. -- ------------------------------------------------------------------------------ function Ada.Strings.Less_Case_Insensitive (Left, Right : String) return Boolean; pragma Pure (Ada.Strings.Less_Case_Insensitive); -- Performs a case-insensitive lexicographic comparison of Left and -- Right. This is useful as the generic actual less-than operator when -- instantiating an ordered container package with type String as the key, -- allowing case-insensitive equivalence tests.
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- S Y S T E M . P A C K _ 5 8 -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2014, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with System.Storage_Elements; with System.Unsigned_Types; package body System.Pack_58 is subtype Bit_Order is System.Bit_Order; Reverse_Bit_Order : constant Bit_Order := Bit_Order'Val (1 - Bit_Order'Pos (System.Default_Bit_Order)); subtype Ofs is System.Storage_Elements.Storage_Offset; subtype Uns is System.Unsigned_Types.Unsigned; subtype N07 is System.Unsigned_Types.Unsigned range 0 .. 7; use type System.Storage_Elements.Storage_Offset; use type System.Unsigned_Types.Unsigned; type Cluster is record E0, E1, E2, E3, E4, E5, E6, E7 : Bits_58; end record; for Cluster use record E0 at 0 range 0 * Bits .. 0 * Bits + Bits - 1; E1 at 0 range 1 * Bits .. 1 * Bits + Bits - 1; E2 at 0 range 2 * Bits .. 2 * Bits + Bits - 1; E3 at 0 range 3 * Bits .. 3 * Bits + Bits - 1; E4 at 0 range 4 * Bits .. 4 * Bits + Bits - 1; E5 at 0 range 5 * Bits .. 5 * Bits + Bits - 1; E6 at 0 range 6 * Bits .. 6 * Bits + Bits - 1; E7 at 0 range 7 * Bits .. 7 * Bits + Bits - 1; end record; for Cluster'Size use Bits * 8; for Cluster'Alignment use Integer'Min (Standard'Maximum_Alignment, 1 + 1 * Boolean'Pos (Bits mod 2 = 0) + 2 * Boolean'Pos (Bits mod 4 = 0)); -- Use maximum possible alignment, given the bit field size, since this -- will result in the most efficient code possible for the field. type Cluster_Ref is access Cluster; type Rev_Cluster is new Cluster with Bit_Order => Reverse_Bit_Order, Scalar_Storage_Order => Reverse_Bit_Order; type Rev_Cluster_Ref is access Rev_Cluster; -- The following declarations are for the case where the address -- passed to GetU_58 or SetU_58 is not guaranteed to be aligned. -- These routines are used when the packed array is itself a -- component of a packed record, and therefore may not be aligned. type ClusterU is new Cluster; for ClusterU'Alignment use 1; type ClusterU_Ref is access ClusterU; type Rev_ClusterU is new ClusterU with Bit_Order => Reverse_Bit_Order, Scalar_Storage_Order => Reverse_Bit_Order; type Rev_ClusterU_Ref is access Rev_ClusterU; ------------ -- Get_58 -- ------------ function Get_58 (Arr : System.Address; N : Natural; Rev_SSO : Boolean) return Bits_58 is A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8); C : Cluster_Ref with Address => A'Address, Import; RC : Rev_Cluster_Ref with Address => A'Address, Import; begin if Rev_SSO then case N07 (Uns (N) mod 8) is when 0 => return RC.E0; when 1 => return RC.E1; when 2 => return RC.E2; when 3 => return RC.E3; when 4 => return RC.E4; when 5 => return RC.E5; when 6 => return RC.E6; when 7 => return RC.E7; end case; else case N07 (Uns (N) mod 8) is when 0 => return C.E0; when 1 => return C.E1; when 2 => return C.E2; when 3 => return C.E3; when 4 => return C.E4; when 5 => return C.E5; when 6 => return C.E6; when 7 => return C.E7; end case; end if; end Get_58; ------------- -- GetU_58 -- ------------- function GetU_58 (Arr : System.Address; N : Natural; Rev_SSO : Boolean) return Bits_58 is A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8); C : ClusterU_Ref with Address => A'Address, Import; RC : Rev_ClusterU_Ref with Address => A'Address, Import; begin if Rev_SSO then case N07 (Uns (N) mod 8) is when 0 => return RC.E0; when 1 => return RC.E1; when 2 => return RC.E2; when 3 => return RC.E3; when 4 => return RC.E4; when 5 => return RC.E5; when 6 => return RC.E6; when 7 => return RC.E7; end case; else case N07 (Uns (N) mod 8) is when 0 => return C.E0; when 1 => return C.E1; when 2 => return C.E2; when 3 => return C.E3; when 4 => return C.E4; when 5 => return C.E5; when 6 => return C.E6; when 7 => return C.E7; end case; end if; end GetU_58; ------------ -- Set_58 -- ------------ procedure Set_58 (Arr : System.Address; N : Natural; E : Bits_58; Rev_SSO : Boolean) is A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8); C : Cluster_Ref with Address => A'Address, Import; RC : Rev_Cluster_Ref with Address => A'Address, Import; begin if Rev_SSO then case N07 (Uns (N) mod 8) is when 0 => RC.E0 := E; when 1 => RC.E1 := E; when 2 => RC.E2 := E; when 3 => RC.E3 := E; when 4 => RC.E4 := E; when 5 => RC.E5 := E; when 6 => RC.E6 := E; when 7 => RC.E7 := E; end case; else case N07 (Uns (N) mod 8) is when 0 => C.E0 := E; when 1 => C.E1 := E; when 2 => C.E2 := E; when 3 => C.E3 := E; when 4 => C.E4 := E; when 5 => C.E5 := E; when 6 => C.E6 := E; when 7 => C.E7 := E; end case; end if; end Set_58; ------------- -- SetU_58 -- ------------- procedure SetU_58 (Arr : System.Address; N : Natural; E : Bits_58; Rev_SSO : Boolean) is A : constant System.Address := Arr + Bits * Ofs (Uns (N) / 8); C : ClusterU_Ref with Address => A'Address, Import; RC : Rev_ClusterU_Ref with Address => A'Address, Import; begin if Rev_SSO then case N07 (Uns (N) mod 8) is when 0 => RC.E0 := E; when 1 => RC.E1 := E; when 2 => RC.E2 := E; when 3 => RC.E3 := E; when 4 => RC.E4 := E; when 5 => RC.E5 := E; when 6 => RC.E6 := E; when 7 => RC.E7 := E; end case; else case N07 (Uns (N) mod 8) is when 0 => C.E0 := E; when 1 => C.E1 := E; when 2 => C.E2 := E; when 3 => C.E3 := E; when 4 => C.E4 := E; when 5 => C.E5 := E; when 6 => C.E6 := E; when 7 => C.E7 := E; end case; end if; end SetU_58; end System.Pack_58;
-- Copyright (C) 2019 Thierry Rascle <thierr26@free.fr> -- MIT license. Please refer to the LICENSE file. with Ada.Calendar; use Ada.Calendar; with Ada.Calendar.Time_Zones; use Ada.Calendar.Time_Zones; package Apsepp.Calendar is Time_First : constant Time := Time_Of (Year => Year_Number'First, Month => Month_Number'First, Day => Day_Number'First, Seconds => Day_Duration'First); function Unknown_Time_zone return Boolean; function Default_Time_Offset return Time_Offset is (if Unknown_Time_zone then 0 else UTC_Time_Offset); function To_ISO_8601 (Date : Time; Time_Zone : Time_Offset := Default_Time_Offset; Include_Time_Fraction : Boolean := False) return String; end Apsepp.Calendar;
-- SPDX-FileCopyrightText: 2019 Max Reznik <reznikmm@gmail.com> -- -- SPDX-License-Identifier: MIT ------------------------------------------------------------- with Program.Element_Vectors; with Program.Elements.Associations; with Program.Lexical_Elements; with Program.Elements.Expressions; package Program.Elements.Record_Component_Associations is pragma Pure (Program.Elements.Record_Component_Associations); type Record_Component_Association is limited interface and Program.Elements.Associations.Association; type Record_Component_Association_Access is access all Record_Component_Association'Class with Storage_Size => 0; not overriding function Choices (Self : Record_Component_Association) return Program.Element_Vectors.Element_Vector_Access is abstract; not overriding function Component_Value (Self : Record_Component_Association) return Program.Elements.Expressions.Expression_Access is abstract; type Record_Component_Association_Text is limited interface; type Record_Component_Association_Text_Access is access all Record_Component_Association_Text'Class with Storage_Size => 0; not overriding function To_Record_Component_Association_Text (Self : in out Record_Component_Association) return Record_Component_Association_Text_Access is abstract; not overriding function Arrow_Token (Self : Record_Component_Association_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; not overriding function Box_Token (Self : Record_Component_Association_Text) return Program.Lexical_Elements.Lexical_Element_Access is abstract; type Record_Component_Association_Vector is limited interface and Program.Element_Vectors.Element_Vector; type Record_Component_Association_Vector_Access is access all Record_Component_Association_Vector'Class with Storage_Size => 0; overriding function Element (Self : Record_Component_Association_Vector; Index : Positive) return not null Program.Elements.Element_Access is abstract with Post'Class => Element'Result.Is_Record_Component_Association; function To_Record_Component_Association (Self : Record_Component_Association_Vector'Class; Index : Positive) return not null Record_Component_Association_Access is (Self.Element (Index).To_Record_Component_Association); end Program.Elements.Record_Component_Associations;
select delay 10.0; Put_Line ("Cannot finish this in 10s"); then abort -- do some lengthy calculation ... end select;
-- Copyright (c) 2019 Maxim Reznik <reznikmm@gmail.com> -- -- SPDX-License-Identifier: MIT -- License-Filename: LICENSE ------------------------------------------------------------- with Slim.Players.Displays; package Slim.Messages.grfe is type Grfe_Message is new Message with private; -- Sends a bitmap to the client for display. not overriding procedure Initialize (Self : in out Grfe_Message; Value : Ada.Streams.Stream_Element_Array; Transition : Slim.Players.Displays.Transition_Kind := Slim.Players.Displays.None; Offset : Natural := 0); not overriding function Data (Self : Grfe_Message) return Ada.Streams.Stream_Element_Array; private subtype Byte is Ada.Streams.Stream_Element; type Grfe_Message is new Base_Message (Max_8 => 1 + 1, Max_16 => 1, Max_32 => 0, Max_64 => 0) with record Data : League.Stream_Element_Vectors.Stream_Element_Vector; end record; overriding function Read (Data : not null access League.Stream_Element_Vectors.Stream_Element_Vector) return Grfe_Message; overriding procedure Read_Custom_Field (Self : in out Grfe_Message; Index : Positive; Input : in out Ada.Streams.Stream_Element_Offset; Data : League.Stream_Element_Vectors.Stream_Element_Vector); overriding procedure Write_Custom_Field (Self : Grfe_Message; Index : Positive; Data : in out League.Stream_Element_Vectors.Stream_Element_Vector); overriding procedure Write (Self : Grfe_Message; Tag : out Message_Tag; Data : out League.Stream_Element_Vectors.Stream_Element_Vector); overriding procedure Visit (Self : not null access Grfe_Message; Visiter : in out Slim.Message_Visiters.Visiter'Class); end Slim.Messages.grfe;
-- CE3409B.ADA -- Grant of Unlimited Rights -- -- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687, -- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained -- unlimited rights in the software and documentation contained herein. -- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making -- this public release, the Government intends to confer upon all -- recipients unlimited rights equal to those held by the Government. -- These rights include rights to use, duplicate, release or disclose the -- released technical data and computer software in whole or in part, in -- any manner and for any purpose whatsoever, and to have or permit others -- to do so. -- -- DISCLAIMER -- -- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR -- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED -- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE -- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE -- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A -- PARTICULAR PURPOSE OF SAID MATERIAL. --* -- OBJECTIVE: -- CHECK THAT SET_COL RAISES CONSTRAINT_ERROR IF THE GIVEN -- COLUMN NUMBER IS ZERO, OR NEGATIVE. -- HISTORY: -- ABW 08/26/82 -- SPS 09/22/82 -- JBG 01/27/83 -- JLH 08/31/87 CORRECTED EXCEPTION HANDLING, REMOVED UNNECESSARY -- CODE, AND ADDED CASE FOR COUNT'LAST. -- PWN 10/27/95 REMOVED OUT OF RANGE STATIC VALUE CHECKS. WITH REPORT ; USE REPORT ; WITH TEXT_IO ; USE TEXT_IO ; PROCEDURE CE3409B IS FILE : FILE_TYPE; BEGIN TEST ("CE3409B", "CHECK THAT SET_COL RAISES CONSTRAINT_ERROR " & "IF THE GIVEN COLUMN NUMBER IS ZERO, OR NEGATIVE."); BEGIN SET_COL (FILE, POSITIVE_COUNT(IDENT_INT(0))); FAILED ("CONSTRAINT_ERROR NOT RAISED FOR ZERO"); EXCEPTION WHEN CONSTRAINT_ERROR => NULL; WHEN STATUS_ERROR => FAILED ("STATUS_ERROR INSTEAD OF CONSTRAINT_ERROR - 1"); WHEN OTHERS => FAILED ("UNEXPECTED EXCEPTION RAISED FOR ZERO"); END; BEGIN SET_COL (FILE, POSITIVE_COUNT(IDENT_INT(-2))); FAILED ("CONSTRAINT_ERROR NOT RAISED FOR NEGATIVE NUMBER"); EXCEPTION WHEN CONSTRAINT_ERROR => NULL; WHEN STATUS_ERROR => FAILED ("STATUS_ERROR INSTEAD OF CONSTRAINT_ERROR - 2"); WHEN OTHERS => FAILED ("UNEXPECTED EXCEPTION RAISED FOR NEGATIVE " & "NUMBER"); END; RESULT; END CE3409B;
with ObjectPack, AbstractStrategyCombinatorPackage, IntrospectorPackage, StrategyPackage; use ObjectPack, AbstractStrategyCombinatorPackage, IntrospectorPackage, StrategyPackage; package MuVarStrategy is type MuVar is new AbstractStrategyCombinator and Object with record instance : StrategyPtr := null; name : access String := null; end record; type MuVarPtr is access all MuVar; ---------------------------------------------------------------------------- -- Object implementation ---------------------------------------------------------------------------- function toString(c: MuVar) return String; ---------------------------------------------------------------------------- -- Strategy implementation ---------------------------------------------------------------------------- function visitLight(str:access MuVar; any: ObjectPtr; i: access Introspector'Class) return ObjectPtr; function visit(str: access MuVar; i: access Introspector'Class) return Integer; ---------------------------------------------------------------------------- function newMuVar(s : access String) return StrategyPtr; function newMuVar(s : String) return StrategyPtr; function equals(m : access MuVar; o : ObjectPtr) return Boolean; function hashCode(m : access MuVar) return Integer; function getInstance(m: access MuVar) return StrategyPtr; procedure setInstance(m: access MuVar; s: StrategyPtr); procedure setName(m: access MuVar; n: access String); function isExpanded(m: access Muvar) return Boolean; function getName(m: access Muvar) return access String; end MuVarStrategy;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- G N A T . E X C E P T I O N S -- -- -- -- S p e c -- -- -- -- Copyright (C) 2000-2019, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This package provides an interface for raising predefined exceptions -- with an exception message. It can be used from Pure units. -- There is no prohibition in Ada that prevents exceptions being raised -- from within pure units. The raise statement is perfectly acceptable. -- However, it is not normally possible to raise an exception with a -- message because the routine Ada.Exceptions.Raise_Exception is not in -- a Pure unit. This is an annoying and unnecessary restriction and this -- package allows for raising the standard predefined exceptions at least. package GNAT.Exceptions is pragma Pure; type Exception_Type is limited null record; -- Type used to specify which exception to raise -- Really Exception_Type is Exception_Id, but Exception_Id can't be -- used directly since it is declared in the non-pure unit Ada.Exceptions, -- Exception_Id is in fact simply a pointer to the type Exception_Data -- declared in System.Standard_Library (which is also non-pure). So what -- we do is to define it here as a by reference type (any by reference -- type would do), and then Import the definitions from Standard_Library. -- Since this is a by reference type, these will be passed by reference, -- which has the same effect as passing a pointer. -- This type is not private because keeping it by reference would require -- defining it in a way (e.g. using a tagged type) that would drag in other -- run-time files, which is unwanted in the case of e.g. Ravenscar where we -- want to minimize the number of run-time files needed by default. CE : constant Exception_Type; -- Constraint_Error PE : constant Exception_Type; -- Program_Error SE : constant Exception_Type; -- Storage_Error TE : constant Exception_Type; -- Tasking_Error -- One of these constants is used in the call to specify the exception procedure Raise_Exception (E : Exception_Type; Message : String); pragma Import (Ada, Raise_Exception, "__gnat_raise_exception"); pragma No_Return (Raise_Exception); -- Raise specified exception with specified message private pragma Import (C, CE, "constraint_error"); pragma Import (C, PE, "program_error"); pragma Import (C, SE, "storage_error"); pragma Import (C, TE, "tasking_error"); -- References to the exception structures in the standard library end GNAT.Exceptions;
------------------------------------------------------------------------------ -- -- -- Ada User Repository Annex (AURA) -- -- ANNEXI-STRAYLINE Reference Implementation -- -- -- -- ------------------------------------------------------------------------ -- -- -- -- Copyright (C) 2020, ANNEXI-STRAYLINE Trans-Human Ltd. -- -- All rights reserved. -- -- -- -- Original Contributors: -- -- * Richard Wai (ANNEXI-STRAYLINE) -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- -- -- * Neither the name of the copyright holder nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A -- -- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- This package provides facilities for querying the PATH (or equivalent) -- Environment Variable for the presence (and full path) of a program, which -- can be supplied as an Image_Path with Ada.Strings.Bounded; package Child_Processes.Path_Searching is Not_In_Path: exception; function Search_Path (Program: String) return String; -- Searches all directories in the PATH environment variable for a file -- named Name, to which it returns the full-path. -- -- If the search fails Not_In_Path is raised. type Elaboration_Path_Search (<>) is limited private; function Initialize (Program: aliased String) return Elaboration_Path_Search; -- A Elaboration_Path_Search initialization performs Search_Path for -- Program upon and is intended to be used to initialize an -- Elaboration_Path_Search object during elaboration of a library package. -- -- The purpose is to allow for elaboration-time search for optional -- programs, which may or may not be later invoked by the partition. -- -- Attempting to extract the Path of a Elaboration_Path_Search where this -- search fails results in a Not_In_Path exception function Found (Search: Elaboration_Path_Search) return Boolean; -- Returns True iff Search.Program was located in PATH, and will thus -- implies that a subsequent invocation of Image_Path will be successful function Image_Path (Search: Elaboration_Path_Search) return String with Pre => Found (Search); -- Returns the full path of Search.Program. If Found (Search) is False, -- Not_In_Path is raised private package Image_Path_Strings is new Ada.Strings.Bounded.Generic_Bounded_Length (256); type Elaboration_Path_Search (Program: not null access constant String) is record Result: Image_Path_Strings.Bounded_String; end record; end Child_Processes.Path_Searching;
with Ada.Text_IO; use Ada.Text_IO; with Ada.Integer_Text_IO; use Ada.Integer_Text_IO; with Ada.Unchecked_Deallocation; package body ABR is procedure Free is new Ada.Unchecked_Deallocation (Object => T_Noeud, Name => T_ABR); procedure Initialiser(Abr: out T_ABR) is begin Abr := Null; end Initialiser; function Est_Vide (Abr : T_Abr) return Boolean is begin return Abr = Null; end; function Taille (Abr : in T_ABR) return Integer is begin if Abr = Null then return 0; else return 1 + Taille (Abr.all.Sous_Arbre_Gauche) + Taille (Abr.all.Sous_Arbre_Droit); end if; end Taille; procedure Inserer (Abr : in out T_ABR ; Cle : in Character ; Donnee : in Integer) is begin if Abr = Null then Abr := new T_Noeud'(Cle, Donnee, Null, Null); elsif Abr.all.Cle < Cle then Inserer (Abr.all.Sous_Arbre_Droit, Cle, Donnee); elsif Cle < Abr.all.Cle then Inserer (Abr.all.Sous_Arbre_Gauche, Cle, Donnee); else -- { Abr.all.Cle = Cle } raise Cle_Presente_Exception; end if; end Inserer; -- Retourner le noeud qui contient la clé Clé. -- Exception : Cle_Absente_Exception si la clé est absente function Le_Noeud (Abr: in T_Abr ; Cle : in Character) return T_ABR is begin if Abr = Null then raise Cle_Absente_Exception; elsif Abr.all.Cle < Cle then return Le_Noeud (Abr.all.Sous_Arbre_Droit, Cle); elsif Cle < Abr.all.Cle then return Le_Noeud (Abr.all.Sous_Arbre_Gauche, Cle); else -- { Abr.all.Cle = Cle } return Abr; end if; end Le_Noeud; procedure Modifier (Abr : in out T_ABR ; Cle : in Character ; Donnee : in Integer) is begin Le_Noeud (Abr, Cle).all.Donnee := Donnee; end Modifier; function La_Donnee (Abr : in T_ABR ; Cle : in Character) return Integer is begin return Le_Noeud (Abr, Cle).all.Donnee; end La_Donnee; -- Décrocher le noeud de Abr qui a la plus petite clé. Il est récupéré -- dans Min. Abr ne doit pas être vide. procedure Decrocher_Min (Abr : in out T_ABR; Min : out T_Abr) with Pre => Abr /= Null, Post => Min /= Null and then Taille (Min) = 1 -- une feuille and then not (Abr'Old.all.Cle < Min.all.Cle) -- plus petite clé ! and then Taille (Abr) = Taille (Abr)'Old - 1 -- un décroché is begin if Abr.all.Sous_Arbre_Gauche = Null then -- min trouvé Min := Abr; Abr := Abr.all.Sous_Arbre_Droit; else Decrocher_Min (Abr.all.Sous_Arbre_Gauche, Min); end if; end Decrocher_Min; procedure Supprimer (Abr : in out T_ABR ; Cle : in Character) is A_Detruire : T_ABR; begin if Abr = Null then raise Cle_Absente_Exception; elsif Abr.all.Cle < Cle then Supprimer (Abr.all.Sous_Arbre_Droit, Cle); elsif Cle < Abr.all.Cle then Supprimer (Abr.all.Sous_Arbre_Gauche, Cle); else -- { Abr.all.Cle = Cle } -- Supprimer le noeud Abr A_Detruire := Abr; if Abr.all.Sous_Arbre_Gauche = Null then Abr := Abr.all.Sous_Arbre_Droit; elsif Abr.all.Sous_Arbre_Droit = Null then Abr := Abr.all.Sous_Arbre_Gauche; else declare Min: T_ABR; begin Decrocher_Min (Abr.all.Sous_Arbre_Droit, Min); Min.all.Sous_Arbre_Gauche := Abr.all.Sous_Arbre_Gauche; Min.all.Sous_Arbre_Droit := Abr.all.Sous_Arbre_Droit; Abr := Min; end; end if; Free (A_Detruire); end if; end Supprimer; procedure Vider (Abr : in out T_ABR) is begin if Abr = Null then Null; else Vider (Abr.all.Sous_Arbre_Gauche); Vider (Abr.all.Sous_Arbre_Droit); Free (Abr); end if; end Vider; procedure Afficher (Abr : in T_Abr) is begin if Abr = Null then Null; else Afficher (Abr.all.Sous_Arbre_Gauche); Put (Abr.all.Cle); Put (" : "); Put (Abr.all.Donnee, 0); New_Line; Afficher (Abr.all.Sous_Arbre_Droit); end if; end Afficher; procedure Afficher_Debug (Abr : in T_Abr) is procedure Indenter(Decalage : in Integer) is begin for I in 1..Decalage loop Put (' '); end loop; end Indenter; -- Afficher un arbre à la profondeur Profondeur et qui à du côté -- indiqué (< pour Gauche et > pour droit, - pour la racine). procedure Afficher_Profondeur (Abr : in T_Abr ; Profondeur : in Integer ; Cote : in Character) is begin if Abr = Null then Null; else Indenter (Profondeur * 4); Put (Cote & ' '); Put (Abr.all.Cle); Put (" : "); Put (Abr.all.Donnee, 0); New_Line; Afficher_Profondeur (Abr.all.Sous_Arbre_Gauche, Profondeur + 1, '<'); Afficher_Profondeur (Abr.all.Sous_Arbre_Droit, Profondeur + 1, '>'); end if; end Afficher_Profondeur; begin Afficher_Profondeur (Abr, 0, '-'); end Afficher_Debug; end ABR;
-- Copyright (c) 2019 Maxim Reznik <reznikmm@gmail.com> -- -- SPDX-License-Identifier: MIT -- License-Filename: LICENSE ------------------------------------------------------------- package body Program.Nodes.Function_Body_Stubs is function Create (Not_Token : Program.Lexical_Elements.Lexical_Element_Access; Overriding_Token : Program.Lexical_Elements.Lexical_Element_Access; Function_Token : not null Program.Lexical_Elements .Lexical_Element_Access; Name : not null Program.Elements.Defining_Identifiers .Defining_Identifier_Access; Left_Bracket_Token : Program.Lexical_Elements.Lexical_Element_Access; Parameters : Program.Elements.Parameter_Specifications .Parameter_Specification_Vector_Access; Right_Bracket_Token : Program.Lexical_Elements.Lexical_Element_Access; Return_Token : not null Program.Lexical_Elements .Lexical_Element_Access; Not_Token_2 : Program.Lexical_Elements.Lexical_Element_Access; Null_Token : Program.Lexical_Elements.Lexical_Element_Access; Result_Subtype : not null Program.Elements.Element_Access; Is_Token : not null Program.Lexical_Elements .Lexical_Element_Access; Separate_Token : not null Program.Lexical_Elements .Lexical_Element_Access; With_Token : Program.Lexical_Elements.Lexical_Element_Access; Aspects : Program.Elements.Aspect_Specifications .Aspect_Specification_Vector_Access; Semicolon_Token : not null Program.Lexical_Elements .Lexical_Element_Access) return Function_Body_Stub is begin return Result : Function_Body_Stub := (Not_Token => Not_Token, Overriding_Token => Overriding_Token, Function_Token => Function_Token, Name => Name, Left_Bracket_Token => Left_Bracket_Token, Parameters => Parameters, Right_Bracket_Token => Right_Bracket_Token, Return_Token => Return_Token, Not_Token_2 => Not_Token_2, Null_Token => Null_Token, Result_Subtype => Result_Subtype, Is_Token => Is_Token, Separate_Token => Separate_Token, With_Token => With_Token, Aspects => Aspects, Semicolon_Token => Semicolon_Token, Enclosing_Element => null) do Initialize (Result); end return; end Create; function Create (Name : not null Program.Elements.Defining_Identifiers .Defining_Identifier_Access; Parameters : Program.Elements.Parameter_Specifications .Parameter_Specification_Vector_Access; Result_Subtype : not null Program.Elements.Element_Access; Aspects : Program.Elements.Aspect_Specifications .Aspect_Specification_Vector_Access; Is_Part_Of_Implicit : Boolean := False; Is_Part_Of_Inherited : Boolean := False; Is_Part_Of_Instance : Boolean := False; Has_Not : Boolean := False; Has_Overriding : Boolean := False; Has_Not_Null : Boolean := False) return Implicit_Function_Body_Stub is begin return Result : Implicit_Function_Body_Stub := (Name => Name, Parameters => Parameters, Result_Subtype => Result_Subtype, Aspects => Aspects, Is_Part_Of_Implicit => Is_Part_Of_Implicit, Is_Part_Of_Inherited => Is_Part_Of_Inherited, Is_Part_Of_Instance => Is_Part_Of_Instance, Has_Not => Has_Not, Has_Overriding => Has_Overriding, Has_Not_Null => Has_Not_Null, Enclosing_Element => null) do Initialize (Result); end return; end Create; overriding function Name (Self : Base_Function_Body_Stub) return not null Program.Elements.Defining_Identifiers .Defining_Identifier_Access is begin return Self.Name; end Name; overriding function Parameters (Self : Base_Function_Body_Stub) return Program.Elements.Parameter_Specifications .Parameter_Specification_Vector_Access is begin return Self.Parameters; end Parameters; overriding function Result_Subtype (Self : Base_Function_Body_Stub) return not null Program.Elements.Element_Access is begin return Self.Result_Subtype; end Result_Subtype; overriding function Aspects (Self : Base_Function_Body_Stub) return Program.Elements.Aspect_Specifications .Aspect_Specification_Vector_Access is begin return Self.Aspects; end Aspects; overriding function Not_Token (Self : Function_Body_Stub) return Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Not_Token; end Not_Token; overriding function Overriding_Token (Self : Function_Body_Stub) return Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Overriding_Token; end Overriding_Token; overriding function Function_Token (Self : Function_Body_Stub) return not null Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Function_Token; end Function_Token; overriding function Left_Bracket_Token (Self : Function_Body_Stub) return Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Left_Bracket_Token; end Left_Bracket_Token; overriding function Right_Bracket_Token (Self : Function_Body_Stub) return Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Right_Bracket_Token; end Right_Bracket_Token; overriding function Return_Token (Self : Function_Body_Stub) return not null Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Return_Token; end Return_Token; overriding function Not_Token_2 (Self : Function_Body_Stub) return Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Not_Token_2; end Not_Token_2; overriding function Null_Token (Self : Function_Body_Stub) return Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Null_Token; end Null_Token; overriding function Is_Token (Self : Function_Body_Stub) return not null Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Is_Token; end Is_Token; overriding function Separate_Token (Self : Function_Body_Stub) return not null Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Separate_Token; end Separate_Token; overriding function With_Token (Self : Function_Body_Stub) return Program.Lexical_Elements.Lexical_Element_Access is begin return Self.With_Token; end With_Token; overriding function Semicolon_Token (Self : Function_Body_Stub) return not null Program.Lexical_Elements.Lexical_Element_Access is begin return Self.Semicolon_Token; end Semicolon_Token; overriding function Has_Not (Self : Function_Body_Stub) return Boolean is begin return Self.Not_Token.Assigned; end Has_Not; overriding function Has_Overriding (Self : Function_Body_Stub) return Boolean is begin return Self.Overriding_Token.Assigned; end Has_Overriding; overriding function Has_Not_Null (Self : Function_Body_Stub) return Boolean is begin return Self.Null_Token.Assigned; end Has_Not_Null; overriding function Is_Part_Of_Implicit (Self : Implicit_Function_Body_Stub) return Boolean is begin return Self.Is_Part_Of_Implicit; end Is_Part_Of_Implicit; overriding function Is_Part_Of_Inherited (Self : Implicit_Function_Body_Stub) return Boolean is begin return Self.Is_Part_Of_Inherited; end Is_Part_Of_Inherited; overriding function Is_Part_Of_Instance (Self : Implicit_Function_Body_Stub) return Boolean is begin return Self.Is_Part_Of_Instance; end Is_Part_Of_Instance; overriding function Has_Not (Self : Implicit_Function_Body_Stub) return Boolean is begin return Self.Has_Not; end Has_Not; overriding function Has_Overriding (Self : Implicit_Function_Body_Stub) return Boolean is begin return Self.Has_Overriding; end Has_Overriding; overriding function Has_Not_Null (Self : Implicit_Function_Body_Stub) return Boolean is begin return Self.Has_Not_Null; end Has_Not_Null; procedure Initialize (Self : aliased in out Base_Function_Body_Stub'Class) is begin Set_Enclosing_Element (Self.Name, Self'Unchecked_Access); for Item in Self.Parameters.Each_Element loop Set_Enclosing_Element (Item.Element, Self'Unchecked_Access); end loop; Set_Enclosing_Element (Self.Result_Subtype, Self'Unchecked_Access); for Item in Self.Aspects.Each_Element loop Set_Enclosing_Element (Item.Element, Self'Unchecked_Access); end loop; null; end Initialize; overriding function Is_Function_Body_Stub_Element (Self : Base_Function_Body_Stub) return Boolean is pragma Unreferenced (Self); begin return True; end Is_Function_Body_Stub_Element; overriding function Is_Declaration_Element (Self : Base_Function_Body_Stub) return Boolean is pragma Unreferenced (Self); begin return True; end Is_Declaration_Element; overriding procedure Visit (Self : not null access Base_Function_Body_Stub; Visitor : in out Program.Element_Visitors.Element_Visitor'Class) is begin Visitor.Function_Body_Stub (Self); end Visit; overriding function To_Function_Body_Stub_Text (Self : aliased in out Function_Body_Stub) return Program.Elements.Function_Body_Stubs .Function_Body_Stub_Text_Access is begin return Self'Unchecked_Access; end To_Function_Body_Stub_Text; overriding function To_Function_Body_Stub_Text (Self : aliased in out Implicit_Function_Body_Stub) return Program.Elements.Function_Body_Stubs .Function_Body_Stub_Text_Access is pragma Unreferenced (Self); begin return null; end To_Function_Body_Stub_Text; end Program.Nodes.Function_Body_Stubs;
-- Copyright 2008-2015 Free Software Foundation, Inc. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. package Types is type Object_Int is interface; type Another_Int is interface; type Object_Root is abstract tagged record X : Natural; Y : Natural; end record; type Object is abstract new Object_Root and Object_Int and Another_Int with null record; function Ident (O : Object'Class) return Object'Class; procedure Do_Nothing (O : in out Object'Class); type Rectangle is new Object with record W : Natural; H : Natural; end record; type Circle is new Object with record R : Natural; end record; end Types;
------------------------------------------------------------------------------ -- -- -- GNAT ncurses Binding Samples -- -- -- -- ncurses -- -- -- -- B O D Y -- -- -- ------------------------------------------------------------------------------ -- Copyright (c) 2000-2006,2011 Free Software Foundation, Inc. -- -- -- -- Permission is hereby granted, free of charge, to any person obtaining a -- -- copy of this software and associated documentation files (the -- -- "Software"), to deal in the Software without restriction, including -- -- without limitation the rights to use, copy, modify, merge, publish, -- -- distribute, distribute with modifications, sublicense, and/or sell -- -- copies of the Software, and to permit persons to whom the Software is -- -- furnished to do so, subject to the following conditions: -- -- -- -- The above copyright notice and this permission notice shall be included -- -- in all copies or substantial portions of the Software. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- -- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- -- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- -- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- -- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- -- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- -- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- -- -- -- Except as contained in this notice, the name(s) of the above copyright -- -- holders shall not be used in advertising or otherwise to promote the -- -- sale, use or other dealings in this Software without prior written -- -- authorization. -- ------------------------------------------------------------------------------ -- Author: Eugene V. Melaragno <aldomel@ix.netcom.com> 2000 -- Version Control -- $Revision: 1.6 $ -- $Date: 2011/03/23 00:44:12 $ -- Binding Version 01.00 ------------------------------------------------------------------------------ with ncurses2.util; use ncurses2.util; with Terminal_Interface.Curses; use Terminal_Interface.Curses; with Terminal_Interface.Curses.Forms; use Terminal_Interface.Curses.Forms; with Terminal_Interface.Curses.Forms.Field_User_Data; with Ada.Characters.Handling; with Ada.Strings; with Ada.Strings.Bounded; procedure ncurses2.demo_forms is package BS is new Ada.Strings.Bounded.Generic_Bounded_Length (80); type myptr is access Integer; -- The C version stores a pointer in the userptr and -- converts it into a long integer. -- The correct, but inconvenient way to do it is to use a -- pointer to long and keep the pointer constant. -- It just adds one memory piece to allocate and deallocate (not done here) package StringData is new Terminal_Interface.Curses.Forms.Field_User_Data (Integer, myptr); function edit_secure (me : Field; c_in : Key_Code) return Key_Code; function form_virtualize (f : Form; w : Window) return Key_Code; function my_form_driver (f : Form; c : Key_Code) return Boolean; function make_label (frow : Line_Position; fcol : Column_Position; label : String) return Field; function make_field (frow : Line_Position; fcol : Column_Position; rows : Line_Count; cols : Column_Count; secure : Boolean) return Field; procedure display_form (f : Form); procedure erase_form (f : Form); -- prints '*' instead of characters. -- Not that this keeps a bug from the C version: -- type in the psasword field then move off and back. -- the cursor is at position one, but -- this assumes it as at the end so text gets appended instead -- of overwtitting. function edit_secure (me : Field; c_in : Key_Code) return Key_Code is rows, frow : Line_Position; nrow : Natural; cols, fcol : Column_Position; nbuf : Buffer_Number; c : Key_Code := c_in; c2 : Character; use StringData; begin Info (me, rows, cols, frow, fcol, nrow, nbuf); -- TODO if result = Form_Ok and nbuf > 0 then -- C version checked the return value -- of Info, the Ada binding throws an exception I think. if nbuf > 0 then declare temp : BS.Bounded_String; temps : String (1 .. 10); -- TODO Get_Buffer povides no information on the field length? len : myptr; begin Get_Buffer (me, 1, Str => temps); -- strcpy(temp, field_buffer(me, 1)); Get_User_Data (me, len); temp := BS.To_Bounded_String (temps (1 .. len.all)); if c <= Key_Max then c2 := Code_To_Char (c); if Ada.Characters.Handling.Is_Graphic (c2) then BS.Append (temp, c2); len.all := len.all + 1; Set_Buffer (me, 1, BS.To_String (temp)); c := Character'Pos ('*'); else c := 0; end if; else case c is when REQ_BEG_FIELD | REQ_CLR_EOF | REQ_CLR_EOL | REQ_DEL_LINE | REQ_DEL_WORD | REQ_DOWN_CHAR | REQ_END_FIELD | REQ_INS_CHAR | REQ_INS_LINE | REQ_LEFT_CHAR | REQ_NEW_LINE | REQ_NEXT_WORD | REQ_PREV_WORD | REQ_RIGHT_CHAR | REQ_UP_CHAR => c := 0; -- we don't want to do inline editing when REQ_CLR_FIELD => if len.all /= 0 then temp := BS.To_Bounded_String (""); Set_Buffer (me, 1, BS.To_String (temp)); len.all := 0; end if; when REQ_DEL_CHAR | REQ_DEL_PREV => if len.all /= 0 then BS.Delete (temp, BS.Length (temp), BS.Length (temp)); Set_Buffer (me, 1, BS.To_String (temp)); len.all := len.all - 1; end if; when others => null; end case; end if; end; end if; return c; end edit_secure; mode : Key_Code := REQ_INS_MODE; function form_virtualize (f : Form; w : Window) return Key_Code is type lookup_t is record code : Key_Code; result : Key_Code; -- should be Form_Request_Code, but we need MAX_COMMAND + 1 end record; lookup : constant array (Positive range <>) of lookup_t := ( ( Character'Pos ('A') mod 16#20#, REQ_NEXT_CHOICE ), ( Character'Pos ('B') mod 16#20#, REQ_PREV_WORD ), ( Character'Pos ('C') mod 16#20#, REQ_CLR_EOL ), ( Character'Pos ('D') mod 16#20#, REQ_DOWN_FIELD ), ( Character'Pos ('E') mod 16#20#, REQ_END_FIELD ), ( Character'Pos ('F') mod 16#20#, REQ_NEXT_PAGE ), ( Character'Pos ('G') mod 16#20#, REQ_DEL_WORD ), ( Character'Pos ('H') mod 16#20#, REQ_DEL_PREV ), ( Character'Pos ('I') mod 16#20#, REQ_INS_CHAR ), ( Character'Pos ('K') mod 16#20#, REQ_CLR_EOF ), ( Character'Pos ('L') mod 16#20#, REQ_LEFT_FIELD ), ( Character'Pos ('M') mod 16#20#, REQ_NEW_LINE ), ( Character'Pos ('N') mod 16#20#, REQ_NEXT_FIELD ), ( Character'Pos ('O') mod 16#20#, REQ_INS_LINE ), ( Character'Pos ('P') mod 16#20#, REQ_PREV_FIELD ), ( Character'Pos ('R') mod 16#20#, REQ_RIGHT_FIELD ), ( Character'Pos ('S') mod 16#20#, REQ_BEG_FIELD ), ( Character'Pos ('U') mod 16#20#, REQ_UP_FIELD ), ( Character'Pos ('V') mod 16#20#, REQ_DEL_CHAR ), ( Character'Pos ('W') mod 16#20#, REQ_NEXT_WORD ), ( Character'Pos ('X') mod 16#20#, REQ_CLR_FIELD ), ( Character'Pos ('Y') mod 16#20#, REQ_DEL_LINE ), ( Character'Pos ('Z') mod 16#20#, REQ_PREV_CHOICE ), ( Character'Pos ('[') mod 16#20#, -- ESCAPE Form_Request_Code'Last + 1 ), ( Key_Backspace, REQ_DEL_PREV ), ( KEY_DOWN, REQ_DOWN_CHAR ), ( Key_End, REQ_LAST_FIELD ), ( Key_Home, REQ_FIRST_FIELD ), ( KEY_LEFT, REQ_LEFT_CHAR ), ( KEY_LL, REQ_LAST_FIELD ), ( Key_Next, REQ_NEXT_FIELD ), ( KEY_NPAGE, REQ_NEXT_PAGE ), ( KEY_PPAGE, REQ_PREV_PAGE ), ( Key_Previous, REQ_PREV_FIELD ), ( KEY_RIGHT, REQ_RIGHT_CHAR ), ( KEY_UP, REQ_UP_CHAR ), ( Character'Pos ('Q') mod 16#20#, -- QUIT Form_Request_Code'Last + 1 -- TODO MAX_FORM_COMMAND + 1 ) ); c : Key_Code := Getchar (w); me : constant Field := Current (f); begin if c = Character'Pos (']') mod 16#20# then if mode = REQ_INS_MODE then mode := REQ_OVL_MODE; else mode := REQ_INS_MODE; end if; c := mode; else for n in lookup'Range loop if lookup (n).code = c then c := lookup (n).result; exit; end if; end loop; end if; -- Force the field that the user is typing into to be in reverse video, -- while the other fields are shown underlined. if c <= Key_Max then c := edit_secure (me, c); Set_Background (me, (Reverse_Video => True, others => False)); elsif c <= Form_Request_Code'Last then c := edit_secure (me, c); Set_Background (me, (Under_Line => True, others => False)); end if; return c; end form_virtualize; function my_form_driver (f : Form; c : Key_Code) return Boolean is flag : constant Driver_Result := Driver (f, F_Validate_Field); begin if c = Form_Request_Code'Last + 1 and flag = Form_Ok then return True; else Beep; return False; end if; end my_form_driver; function make_label (frow : Line_Position; fcol : Column_Position; label : String) return Field is f : constant Field := Create (1, label'Length, frow, fcol, 0, 0); o : Field_Option_Set := Get_Options (f); begin if f /= Null_Field then Set_Buffer (f, 0, label); o.Active := False; Set_Options (f, o); end if; return f; end make_label; function make_field (frow : Line_Position; fcol : Column_Position; rows : Line_Count; cols : Column_Count; secure : Boolean) return Field is f : Field; use StringData; len : myptr; begin if secure then f := Create (rows, cols, frow, fcol, 0, 1); else f := Create (rows, cols, frow, fcol, 0, 0); end if; if f /= Null_Field then Set_Background (f, (Under_Line => True, others => False)); len := new Integer; len.all := 0; Set_User_Data (f, len); end if; return f; end make_field; procedure display_form (f : Form) is w : Window; rows : Line_Count; cols : Column_Count; begin Scale (f, rows, cols); w := New_Window (rows + 2, cols + 4, 0, 0); if w /= Null_Window then Set_Window (f, w); Set_Sub_Window (f, Derived_Window (w, rows, cols, 1, 2)); Box (w); -- 0,0 Set_KeyPad_Mode (w, True); end if; -- TODO if Post(f) /= Form_Ok then it's a procedure declare begin Post (f); exception when Eti_System_Error | Eti_Bad_Argument | Eti_Posted | Eti_Connected | Eti_Bad_State | Eti_No_Room | Eti_Not_Posted | Eti_Unknown_Command | Eti_No_Match | Eti_Not_Selectable | Eti_Not_Connected | Eti_Request_Denied | Eti_Invalid_Field | Eti_Current => Refresh (w); end; -- end if; end display_form; procedure erase_form (f : Form) is w : Window := Get_Window (f); s : Window := Get_Sub_Window (f); begin Post (f, False); Erase (w); Refresh (w); Delete (s); Delete (w); end erase_form; finished : Boolean := False; f : constant Field_Array_Access := new Field_Array (1 .. 12); secure : Field; myform : Form; w : Window; c : Key_Code; result : Driver_Result; begin Move_Cursor (Line => 18, Column => 0); Add (Str => "Defined form-traversal keys: ^Q/ESC- exit form"); Add (Ch => newl); Add (Str => "^N -- go to next field ^P -- go to previous field"); Add (Ch => newl); Add (Str => "Home -- go to first field End -- go to last field"); Add (Ch => newl); Add (Str => "^L -- go to field to left ^R -- go to field to right"); Add (Ch => newl); Add (Str => "^U -- move upward to field ^D -- move downward to field"); Add (Ch => newl); Add (Str => "^W -- go to next word ^B -- go to previous word"); Add (Ch => newl); Add (Str => "^S -- go to start of field ^E -- go to end of field"); Add (Ch => newl); Add (Str => "^H -- delete previous char ^Y -- delete line"); Add (Ch => newl); Add (Str => "^G -- delete current word ^C -- clear to end of line"); Add (Ch => newl); Add (Str => "^K -- clear to end of field ^X -- clear field"); Add (Ch => newl); Add (Str => "Arrow keys move within a field as you would expect."); Add (Line => 4, Column => 57, Str => "Forms Entry Test"); Refresh; -- describe the form f.all (1) := make_label (0, 15, "Sample Form"); f.all (2) := make_label (2, 0, "Last Name"); f.all (3) := make_field (3, 0, 1, 18, False); f.all (4) := make_label (2, 20, "First Name"); f.all (5) := make_field (3, 20, 1, 12, False); f.all (6) := make_label (2, 34, "Middle Name"); f.all (7) := make_field (3, 34, 1, 12, False); f.all (8) := make_label (5, 0, "Comments"); f.all (9) := make_field (6, 0, 4, 46, False); f.all (10) := make_label (5, 20, "Password:"); f.all (11) := make_field (5, 30, 1, 9, True); secure := f.all (11); f.all (12) := Null_Field; myform := New_Form (f); display_form (myform); w := Get_Window (myform); Set_Raw_Mode (SwitchOn => True); Set_NL_Mode (SwitchOn => True); -- lets us read ^M's while not finished loop c := form_virtualize (myform, w); result := Driver (myform, c); case result is when Form_Ok => Add (Line => 5, Column => 57, Str => Get_Buffer (secure, 1)); Clear_To_End_Of_Line; Refresh; when Unknown_Request => finished := my_form_driver (myform, c); when others => Beep; end case; end loop; erase_form (myform); -- TODO Free_Form(myform); -- for (c = 0; f[c] != 0; c++) free_field(f[c]); Set_Raw_Mode (SwitchOn => False); Set_NL_Mode (SwitchOn => True); end ncurses2.demo_forms;
----------------------------------------------------------------------- -- util-properties-bundles -- Generic name/value property management -- Copyright (C) 2001 - 2020 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Ada.Unchecked_Deallocation; with Ada.Unchecked_Conversion; with Ada.Directories; with Ada.Containers.Vectors; with Ada.Strings.Fixed; with Util.Log.Loggers; with Util.Files; with Util.Concurrent.Counters; package body Util.Properties.Bundles is Log : constant Util.Log.Loggers.Logger := Util.Log.Loggers.Create ("Util.Properties.Bundles"); use Implementation; procedure Free is new Ada.Unchecked_Deallocation (Manager'Class, Bundle_Manager_Access); -- Implementation of the Bundle -- (this allows to decouples the implementation from the API) package Interface_P is package PropertyList is new Ada.Containers.Vectors (Element_Type => Util.Properties.Manager_Access, Index_Type => Natural, "=" => "="); type Manager is limited new Util.Properties.Implementation.Manager with record List : PropertyList.Vector; Props : aliased Util.Properties.Manager; Count : Util.Concurrent.Counters.Counter := Util.Concurrent.Counters.ONE; Shared : Boolean := False; end record; -- Get the value identified by the name. -- If the name cannot be found, the method should return the Null object. overriding function Get_Value (From : in Manager; Name : in String) return Util.Beans.Objects.Object; -- Set the value identified by the name. -- If the map contains the given name, the value changed. -- Otherwise name is added to the map and the value associated with it. overriding procedure Set_Value (From : in out Manager; Name : in String; Value : in Util.Beans.Objects.Object); -- Returns TRUE if the property exists. overriding function Exists (Self : in Manager; Name : in String) return Boolean; -- Remove the property given its name. overriding procedure Remove (Self : in out Manager; Name : in String); -- Iterate over the properties and execute the given procedure passing the -- property name and its value. overriding procedure Iterate (Self : in Manager; Process : access procedure (Name : in String; Item : in Util.Beans.Objects.Object)); procedure Load_Properties (Self : in out Manager; File : in String); -- Deep copy of properties stored in 'From' to 'To'. overriding function Create_Copy (Self : in Manager) return Util.Properties.Implementation.Manager_Access; procedure Add_Bundle (Self : in out Manager; Props : in Util.Properties.Manager_Access); package Shared_Implementation is new Implementation.Shared_Implementation (Manager); subtype Shared_Manager is Shared_Implementation.Manager; function Allocate_Property return Implementation.Shared_Manager_Access is (new Shared_Manager); -- Create a property implementation if there is none yet. procedure Check_And_Create_Impl is new Implementation.Create (Allocator => Allocate_Property); end Interface_P; procedure Add_Bundle (Self : in out Manager; Props : in Manager_Access) is begin Interface_P.Manager'Class (Self.Impl.all).Add_Bundle (Props); end Add_Bundle; procedure Initialize (Object : in out Manager) is begin Interface_P.Check_And_Create_Impl (Object); end Initialize; procedure Adjust (Object : in out Manager) is begin Interface_P.Check_And_Create_Impl (Object); Object.Impl.Adjust; end Adjust; -- ------------------------------ -- Initialize the bundle factory and specify where the property files are stored. -- ------------------------------ procedure Initialize (Factory : in out Loader; Path : in String) is begin Log.Info ("Initialize bundle factory to load from {0}", Path); Factory.Path := To_Unbounded_String (Path); end Initialize; -- ------------------------------ -- Load the bundle with the given name and for the given locale name. -- ------------------------------ procedure Load_Bundle (Factory : in out Loader; Name : in String; Locale : in String; Bundle : out Manager'Class) is Found : Boolean := False; begin Log.Info ("Load bundle {0} for language {1}", Name, Locale); Find_Bundle (Factory, Name, Locale, Bundle, Found); if not Found then Load_Bundle (Factory, Name, Found); if not Found then Log.Error ("Bundle {0} not found", Name); raise NO_BUNDLE with "No bundle '" & Name & "'"; end if; Find_Bundle (Factory, Name, Locale, Bundle, Found); if not Found then Log.Error ("Bundle {0} not found", Name); raise NO_BUNDLE with "No bundle '" & Name & "'"; end if; end if; end Load_Bundle; -- ------------------------------ -- Find the bundle with the given name and for the given locale name. -- ------------------------------ procedure Find_Bundle (Factory : in out Loader; Name : in String; Locale : in String; Bundle : out Manager'Class; Found : out Boolean) is use Ada.Strings; Loc_Name : constant String := '_' & Locale; Last_Pos : Integer := Loc_Name'Last; begin Log.Debug ("Looking for bundle {0} and language {1}", Name, Locale); Found := False; Factory.Lock.Read; declare Pos : Bundle_Map.Cursor; begin while Last_Pos + 1 >= Loc_Name'First loop declare Bundle_Name : aliased constant String := Name & Loc_Name (Loc_Name'First .. Last_Pos); begin Log.Debug ("Searching for {0}", Bundle_Name); Pos := Factory.Bundles.Find (Bundle_Name'Unrestricted_Access); if Bundle_Map.Has_Element (Pos) then Bundle.Finalize; Bundle.Impl := Bundle_Map.Element (Pos).Impl; Bundle.Impl.Adjust; Found := True; exit; end if; end; if Last_Pos > Loc_Name'First then Last_Pos := Fixed.Index (Loc_Name, "_", Last_Pos - 1, Backward) - 1; else Last_Pos := Last_Pos - 1; end if; end loop; exception when others => Factory.Lock.Release_Read; raise; end; Factory.Lock.Release_Read; end Find_Bundle; -- ------------------------------ -- Load the bundle with the given name and for the given locale name. -- ------------------------------ procedure Load_Bundle (Factory : in out Loader; Name : in String; Found : out Boolean) is use Ada.Directories; use Ada.Strings; use Util.Strings; use Ada.Containers; use Util.Strings.String_Set; use Bundle_Map; procedure Process_File (Name : in String; File_Path : in String; Done : out Boolean); Path : constant String := To_String (Factory.Path); Pattern : constant String := Name & "*.properties"; Names : Util.Strings.String_Set.Set; procedure Process_File (Name : in String; File_Path : in String; Done : out Boolean) is subtype Cursor is Bundle_Map.Cursor; Base_Name : aliased constant String := Name (Name'First .. Name'Last - 11); Pos : constant Cursor := Factory.Bundles.Find (Base_Name'Unchecked_Access); Bundle_Name : Name_Access; Bundle : Bundle_Manager_Access; begin Log.Info ("Loading file {0}", File_Path); if Bundle_Map.Has_Element (Pos) then Bundle := Bundle_Map.Element (Pos); else Bundle := new Manager; Bundle_Name := new String '(Base_Name); Factory.Bundles.Include (Key => Bundle_Name, New_Item => Bundle); Names.Insert (Bundle_Name); end if; Interface_P.Manager'Class (Bundle.Impl.all).Load_Properties (File_Path); Found := True; Done := False; end Process_File; begin Log.Info ("Reading bundle {1} in directory {0}", Path, Name); Found := False; Factory.Lock.Write; begin Util.Files.Iterate_Files_Path (Pattern => Pattern, Path => Path, Process => Process_File'Access, Going => Ada.Strings.Backward); -- Link the property files to implement the localization default rules. while Names.Length > 0 loop declare Name_Pos : String_Set.Cursor := Names.First; Bundle_Name : constant Name_Access := String_Set.Element (Name_Pos); Idx : Natural := Fixed.Index (Bundle_Name.all, "_", Backward); Bundle_Pos : constant Bundle_Map.Cursor := Factory.Bundles.Find (Bundle_Name); Bundle : constant Bundle_Manager_Access := Element (Bundle_Pos); begin Names.Delete (Name_Pos); -- Associate the property bundle to the first existing parent -- Ex: message_fr_CA -> message_fr -- message_fr_CA -> message while Idx > 0 loop declare Name : aliased constant String := Bundle_Name (Bundle_Name'First .. Idx - 1); Pos : constant Bundle_Map.Cursor := Factory.Bundles.Find (Name'Unchecked_Access); begin if Bundle_Map.Has_Element (Pos) then Bundle.Add_Bundle (Bundle_Map.Element (Pos).all'Access); Idx := 0; else Idx := Fixed.Index (Bundle_Name.all, "_", Idx - 1, Backward); end if; end; end loop; end; end loop; exception when others => Factory.Lock.Release_Write; raise; end; Factory.Lock.Release_Write; exception when Name_Error => Log.Error ("Cannot read directory: {0}", Path); end Load_Bundle; -- Implementation of the Bundle -- (this allows to decouples the implementation from the API) package body Interface_P is use PropertyList; -- Get the value identified by the name. -- If the name cannot be found, the method should return the Null object. overriding function Get_Value (From : in Manager; Name : in String) return Util.Beans.Objects.Object is Result : Util.Beans.Objects.Object := From.Props.Get_Value (Name); begin if Util.Beans.Objects.Is_Null (Result) then declare Iter : Cursor := From.List.First; begin while Has_Element (Iter) loop Result := Element (Iter).all.Get_Value (Name); exit when not Util.Beans.Objects.Is_Null (Result); Iter := Next (Iter); end loop; end; end if; return Result; end Get_Value; -- Set the value identified by the name. -- If the map contains the given name, the value changed. -- Otherwise name is added to the map and the value associated with it. overriding procedure Set_Value (From : in out Manager; Name : in String; Value : in Util.Beans.Objects.Object) is begin raise NOT_WRITEABLE with "Bundle is readonly"; end Set_Value; -- ------------------------------ -- Returns TRUE if the property exists. -- ------------------------------ function Exists (Self : in Manager; Name : in String) return Boolean is Iter : Cursor := Self.List.First; begin if Self.Props.Exists (Name) then return True; end if; while Has_Element (Iter) loop if Element (Iter).Exists (Name) then return True; end if; Iter := Next (Iter); end loop; return False; end Exists; procedure Load_Properties (Self : in out Manager; File : in String) is begin Self.Props.Load_Properties (File); end Load_Properties; -- ------------------------------ -- Remove the property given its name. -- ------------------------------ procedure Remove (Self : in out Manager; Name : in String) is begin raise NOT_WRITEABLE with "Bundle is readonly"; end Remove; -- Iterate over the properties and execute the given procedure passing the -- property name and its value. procedure Iterate (Self : in Manager; Process : access procedure (Name : in String; Item : in Util.Beans.Objects.Object)) is begin raise Program_Error with "Iterate is not implemented on Bundle"; end Iterate; -- ------------------------------ -- Deep copy of properties stored in 'From' to 'To'. -- ------------------------------ overriding function Create_Copy (Self : in Manager) return Util.Properties.Implementation.Manager_Access is pragma Unreferenced (Self); begin return null; end Create_Copy; procedure Add_Bundle (Self : in out Manager; Props : in Util.Properties.Manager_Access) is begin Self.List.Append (Props); end Add_Bundle; end Interface_P; -- ------------------------------ -- Clear the bundle cache -- ------------------------------ procedure Clear_Cache (Factory : in out Loader) is use Util.Strings; use Bundle_Map; function To_String_Access is new Ada.Unchecked_Conversion (Source => Util.Strings.Name_Access, Target => Ada.Strings.Unbounded.String_Access); begin Log.Info ("Clearing bundle cache"); Factory.Lock.Write; loop declare Pos : Bundle_Map.Cursor := Factory.Bundles.First; Name : Ada.Strings.Unbounded.String_Access; Node : Bundle_Manager_Access; begin exit when not Has_Element (Pos); Node := Element (Pos); Name := To_String_Access (Key (Pos)); Factory.Bundles.Delete (Pos); Free (Node); Free (Name); end; end loop; Factory.Lock.Release_Write; end Clear_Cache; -- ------------------------------ -- Finalize the bundle loader and clear the cache -- ------------------------------ procedure Finalize (Factory : in out Loader) is begin Clear_Cache (Factory); end Finalize; end Util.Properties.Bundles;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2011-2012, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- This file is generated, don't edit it. ------------------------------------------------------------------------------ with AMF.Generic_Collections; package AMF.UML.Message_Events.Collections is pragma Preelaborate; package UML_Message_Event_Collections is new AMF.Generic_Collections (UML_Message_Event, UML_Message_Event_Access); type Set_Of_UML_Message_Event is new UML_Message_Event_Collections.Set with null record; Empty_Set_Of_UML_Message_Event : constant Set_Of_UML_Message_Event; type Ordered_Set_Of_UML_Message_Event is new UML_Message_Event_Collections.Ordered_Set with null record; Empty_Ordered_Set_Of_UML_Message_Event : constant Ordered_Set_Of_UML_Message_Event; type Bag_Of_UML_Message_Event is new UML_Message_Event_Collections.Bag with null record; Empty_Bag_Of_UML_Message_Event : constant Bag_Of_UML_Message_Event; type Sequence_Of_UML_Message_Event is new UML_Message_Event_Collections.Sequence with null record; Empty_Sequence_Of_UML_Message_Event : constant Sequence_Of_UML_Message_Event; private Empty_Set_Of_UML_Message_Event : constant Set_Of_UML_Message_Event := (UML_Message_Event_Collections.Set with null record); Empty_Ordered_Set_Of_UML_Message_Event : constant Ordered_Set_Of_UML_Message_Event := (UML_Message_Event_Collections.Ordered_Set with null record); Empty_Bag_Of_UML_Message_Event : constant Bag_Of_UML_Message_Event := (UML_Message_Event_Collections.Bag with null record); Empty_Sequence_Of_UML_Message_Event : constant Sequence_Of_UML_Message_Event := (UML_Message_Event_Collections.Sequence with null record); end AMF.UML.Message_Events.Collections;
with Ada.Sequential_IO; with Ada.Directories; package body Utilities is ----------- -- Slurp -- ----------- function Slurp (Filename : String) return String is subtype Content is String (1 .. Integer (Ada.Directories.Size (Filename))); Result : Content; package Content_IO is new Ada.Sequential_IO (Content); Input : Content_IO.File_Type; begin Content_IO.Open (File => Input, Mode => Content_IO.In_File, Name => Filename); Content_IO.Read (File => Input, Item => Result); Content_IO.Close (Input); return Result; end Slurp; end Utilities;
package OpenGL.State is type Capability_t is (Alpha_Test, Auto_Normal, Blend, Color_Array, Color_Logic_Op, Color_Material, Color_Sum, Color_Table, Convolution_1D, Convolution_2D, Cull_Face, Depth_Test, Dither, Edge_Flag_Array, Fog, Fog_Coord_Array, Histogram, Index_Array, Index_Logic_Op, Lighting, Line_Smooth, Line_Stipple, Map1_Color_4, Map1_Index, Map1_Normal, Map1_Texture_Coord_1, Map1_Texture_Coord_2, Map1_Texture_Coord_3, Map1_Texture_Coord_4, Map2_Color_4, Map2_Index, Map2_Normal, Map2_Texture_Coord_1, Map2_Texture_Coord_2, Map2_Texture_Coord_3, Map2_Texture_Coord_4, Map2_Vertex_3, Map2_Vertex_4, Minmax, Multisample, Normal_Array, Normalize, Point_Smooth, Point_Sprite, Polygon_Smooth, Polygon_Offset_Fill, Polygon_Offset_Line, Polygon_Offset_Point, Polygon_Stipple, Post_Color_Matrix_Color_Table, Post_Convolution_Color_Table, Rescale_Normal, Sample_Alpha_To_Coverage, Sample_Alpha_To_One, Sample_Coverage, Scissor_Test, Secondary_Color_Array, Separable_2D, Stencil_Test, Texture_1D, Texture_2D, Texture_3D, Texture_Coord_Array, Texture_Cube_Map, Texture_Gen_Q, Texture_Gen_R, Texture_Gen_S, Texture_Gen_T, Texture_Rectangle_ARB, Vertex_Array, Vertex_Program_Point_Size, Vertex_Program_Two_Side); -- proc_map : glEnable procedure Enable (Capability : in Capability_t); pragma Inline (Enable); -- proc_map : glDisable procedure Disable (Capability : in Capability_t); pragma Inline (Disable); -- proc_map : glIsEnabled function Is_Enabled (Capability : in Capability_t) return Boolean; pragma Inline (Is_Enabled); -- -- Client state. -- type Client_Capability_t is (Color_Array, Edge_Flag_Array, Fog_Coord_Array, Index_Array, Normal_Array, Secondary_Color_Array, Texture_Coord_Array, Vertex_Array); -- proc_map : glEnableClientState procedure Enable_Client_State (Capability : in Client_Capability_t); pragma Inline (Enable_Client_State); -- proc_map : glDisableClientState procedure Disable_Client_State (Capability : in Client_Capability_t); pragma Inline (Disable_Client_State); end OpenGL.State;
-------------------------------------------------------------------------------------------------------------------- -- Copyright (c) 2013-2020, Luke A. Guest -- -- This software is provided 'as-is', without any express or implied -- warranty. In no event will the authors be held liable for any damages -- arising from the use of this software. -- -- Permission is granted to anyone to use this software for any purpose, -- including commercial applications, and to alter it and redistribute it -- freely, subject to the following restrictions: -- -- 1. The origin of this software must not be misrepresented; you must not -- claim that you wrote the original software. If you use this software -- in a product, an acknowledgment in the product documentation would be -- appreciated but is not required. -- -- 2. Altered source versions must be plainly marked as such, and must not be -- misrepresented as being the original software. -- -- 3. This notice may not be removed or altered from any source -- distribution. -------------------------------------------------------------------------------------------------------------------- -- SDL.Log -- -- Message logging. -------------------------------------------------------------------------------------------------------------------- package SDL.Log is -- Messages longer than Max_Length will be truncated. -- TODO: Import this from a C constant set from SDL_MAX_LOG_MESSAGE. Max_Length : constant Integer := 4096; -- Had to make this into a type with constants due to the abuse of -- the C enumeration. type Categories is range 0 .. 2 ** 32; Application : constant Categories := 0; Errors : constant Categories := 1; Assert : constant Categories := 2; System : constant Categories := 3; Audio : constant Categories := 4; Video : constant Categories := 5; Render : constant Categories := 6; Input : constant Categories := 7; Test : constant Categories := 8; -- Reserved categories. Reserved_First : constant Categories := 9; Reserved_Last : constant Categories := 18; -- Custom categories. subtype Custom_Categories is Categories range Reserved_Last .. Categories'Last; type Priorities is (Verbose, Debug, Info, Warn, Error, Critical) with Convention => C; for Priorities use (Verbose => 1, Debug => 2, Info => 3, Warn => 4, Error => 5, Critical => 6); -- Log a message with Category: Application and Priority: Info. procedure Put (Message : in String) with Inline => True; procedure Put (Message : in String; Category : in Categories; Priority : in Priorities) with Inline => True; -- Log a message with Priority: Critical. procedure Put_Critical (Message : in String; Category : in Categories := Application) with Inline => True; -- Log a message with Priority: Debug. procedure Put_Debug (Message : in String; Category : in Categories := Application) with Inline => True; -- Log a message with Priority: Error. procedure Put_Error (Message : in String; Category : in Categories := Application) with Inline => True; -- Log a message with Priority: Info. procedure Put_Info (Message : in String; Category : in Categories := Application) with Inline => True; -- Log a message with Priority: Verbose. procedure Put_Verbose (Message : in String; Category : in Categories := Application) with Inline => True; -- Log a message with Priority: Warn. procedure Put_Warn (Message : in String; Category : in Categories := Application) with Inline => True; -- procedure Reset_Priorities with Inline => True; -- Set the priority of all the log categories to the given Priority. procedure Set (Priority : in Priorities) with Inline => True; -- Set the the given log Category to the given Priority. procedure Set (Category : in Categories; Priority : in Priorities) with Inline => True; -- Logging callbacks. -- TODO: complete this. -- I think this will require a bit more work. I think we will have to allocate a record -- and store this in a container which gets destroyed on application shutdown before SDL quits. type Root_User_Data is tagged null record; type Output_Callback is access procedure (User_Data : in Root_User_Data'Class; Category : in Categories; Priority : in Priorities; Message : in String); end SDL.Log;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2011-2012, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- This file is generated, don't edit it. ------------------------------------------------------------------------------ with AMF.Elements.Generic_Hash; function AMF.UML.Central_Buffer_Nodes.Hash is new AMF.Elements.Generic_Hash (UML_Central_Buffer_Node, UML_Central_Buffer_Node_Access);
------------------------------------------------------------------------------ -- -- -- GNAT ncurses Binding Samples -- -- -- -- ncurses -- -- -- -- B O D Y -- -- -- ------------------------------------------------------------------------------ -- Copyright 2020 Thomas E. Dickey -- -- Copyright 2000 Free Software Foundation, Inc. -- -- -- -- Permission is hereby granted, free of charge, to any person obtaining a -- -- copy of this software and associated documentation files (the -- -- "Software"), to deal in the Software without restriction, including -- -- without limitation the rights to use, copy, modify, merge, publish, -- -- distribute, distribute with modifications, sublicense, and/or sell -- -- copies of the Software, and to permit persons to whom the Software is -- -- furnished to do so, subject to the following conditions: -- -- -- -- The above copyright notice and this permission notice shall be included -- -- in all copies or substantial portions of the Software. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- -- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- -- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -- -- IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, -- -- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR -- -- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR -- -- THE USE OR OTHER DEALINGS IN THE SOFTWARE. -- -- -- -- Except as contained in this notice, the name(s) of the above copyright -- -- holders shall not be used in advertising or otherwise to promote the -- -- sale, use or other dealings in this Software without prior written -- -- authorization. -- ------------------------------------------------------------------------------ -- Author: Eugene V. Melaragno <aldomel@ix.netcom.com> 2000 -- Version Control -- $Revision: 1.2 $ -- Binding Version 01.00 ------------------------------------------------------------------------------ procedure ncurses2.slk_test;
-- Copyright 2018-2019 Free Software Foundation, Inc. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 3 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program. If not, see <http://www.gnu.org/licenses/>. with System; package Pck is Global_Var : Integer := 0; procedure Do_Nothing (A : System.Address); end Pck;
with Ada.Text_IO; use Ada.Text_IO; procedure Adventofcode.Day_13.Main is begin Put_Line ("Day-13"); end Adventofcode.Day_13.Main;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2011-2012, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- This file is generated, don't edit it. ------------------------------------------------------------------------------ -- Shows an StateMachine and its elements. Also see Annex A. ------------------------------------------------------------------------------ limited with AMF.UML.State_Machines; with AMF.UMLDI.UML_Behavior_Diagrams; package AMF.UMLDI.UML_State_Machine_Diagrams is pragma Preelaborate; type UMLDI_UML_State_Machine_Diagram is limited interface and AMF.UMLDI.UML_Behavior_Diagrams.UMLDI_UML_Behavior_Diagram; type UMLDI_UML_State_Machine_Diagram_Access is access all UMLDI_UML_State_Machine_Diagram'Class; for UMLDI_UML_State_Machine_Diagram_Access'Storage_Size use 0; not overriding function Get_Inherited_State_Border (Self : not null access constant UMLDI_UML_State_Machine_Diagram) return AMF.UMLDI.Optional_UMLDI_UML_Inherited_State_Border_Kind is abstract; -- Getter of UMLStateMachineDiagram::inheritedStateBorder. -- -- Indicates how borders shall be rendered on UMLShapes that have an -- inherited State as modelElement. not overriding procedure Set_Inherited_State_Border (Self : not null access UMLDI_UML_State_Machine_Diagram; To : AMF.UMLDI.Optional_UMLDI_UML_Inherited_State_Border_Kind) is abstract; -- Setter of UMLStateMachineDiagram::inheritedStateBorder. -- -- Indicates how borders shall be rendered on UMLShapes that have an -- inherited State as modelElement. not overriding function Get_Is_Collapse_State_Icon (Self : not null access constant UMLDI_UML_State_Machine_Diagram) return Boolean is abstract; -- Getter of UMLStateMachineDiagram::isCollapseStateIcon. -- -- Indicates whether UMLShapes for composite States shall contain a small -- icon distinguishing them from non-composite States. not overriding procedure Set_Is_Collapse_State_Icon (Self : not null access UMLDI_UML_State_Machine_Diagram; To : Boolean) is abstract; -- Setter of UMLStateMachineDiagram::isCollapseStateIcon. -- -- Indicates whether UMLShapes for composite States shall contain a small -- icon distinguishing them from non-composite States. not overriding function Get_Is_Transition_Oriented (Self : not null access constant UMLDI_UML_State_Machine_Diagram) return Boolean is abstract; -- Getter of UMLStateMachineDiagram::isTransitionOriented. -- -- Indicates whether properties of Transitions shall be shown graphically. not overriding procedure Set_Is_Transition_Oriented (Self : not null access UMLDI_UML_State_Machine_Diagram; To : Boolean) is abstract; -- Setter of UMLStateMachineDiagram::isTransitionOriented. -- -- Indicates whether properties of Transitions shall be shown graphically. not overriding function Get_Model_Element (Self : not null access constant UMLDI_UML_State_Machine_Diagram) return AMF.UML.State_Machines.UML_State_Machine_Access is abstract; -- Getter of UMLStateMachineDiagram::modelElement. -- not overriding procedure Set_Model_Element (Self : not null access UMLDI_UML_State_Machine_Diagram; To : AMF.UML.State_Machines.UML_State_Machine_Access) is abstract; -- Setter of UMLStateMachineDiagram::modelElement. -- end AMF.UMLDI.UML_State_Machine_Diagrams;
------------------------------------------------------------------------------ -- -- -- GNAT EXAMPLE -- -- -- -- Copyright (C) 2014, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This file provides register definitions for the STM32F4 (ARM Cortex M4F) -- microcontrollers from ST Microelectronics. pragma Restrictions (No_Elaboration_Code); with System; package STM32F4.Reset_Clock_Control is type RCC_Clock is record SYSCLK : Word; HCLK : Word; PCLK1 : Word; PCLK2 : Word; TIMCLK1 : Word; TIMCLK2 : Word; end record; function Get_Clock_Frequency return RCC_Clock; procedure Set_PLLSAI_Factors (LCD : Bits_3; SAI1 : Bits_4; VCO : Bits_9; DivR : Bits_2); procedure Enable_PLLSAI; procedure GPIOA_Clock_Enable with Inline; procedure GPIOB_Clock_Enable with Inline; procedure GPIOC_Clock_Enable with Inline; procedure GPIOD_Clock_Enable with Inline; procedure GPIOE_Clock_Enable with Inline; procedure GPIOF_Clock_Enable with Inline; procedure GPIOG_Clock_Enable with Inline; procedure GPIOH_Clock_Enable with Inline; procedure GPIOI_Clock_Enable with Inline; procedure GPIOJ_Clock_Enable with Inline; procedure GPIOK_Clock_Enable with Inline; procedure CRC_Clock_Enable with Inline; procedure BKPSRAM_Clock_Enable with Inline; procedure CCMDATARAMEN_Clock_Enable with Inline; procedure DMA1_Clock_Enable with Inline; procedure DMA2_Clock_Enable with Inline; procedure GPIOA_Clock_Disable with Inline; procedure GPIOB_Clock_Disable with Inline; procedure GPIOC_Clock_Disable with Inline; procedure GPIOD_Clock_Disable with Inline; procedure GPIOE_Clock_Disable with Inline; procedure GPIOF_Clock_Disable with Inline; procedure GPIOG_Clock_Disable with Inline; procedure GPIOH_Clock_Disable with Inline; procedure GPIOI_Clock_Disable with Inline; procedure GPIOJ_Clock_Disable with Inline; procedure GPIOK_Clock_Disable with Inline; procedure CRC_Clock_Disable with Inline; procedure BKPSRAM_Clock_Disable with Inline; procedure CCMDATARAMEN_Clock_Disable with Inline; procedure DMA1_Clock_Disable with Inline; procedure DMA2_Clock_Disable with Inline; procedure RNG_Clock_Enable with Inline; procedure RNG_Clock_Disable with Inline; procedure TIM2_Clock_Enable with Inline; procedure TIM3_Clock_Enable with Inline; procedure TIM4_Clock_Enable with Inline; procedure TIM5_Clock_Enable with Inline; procedure TIM6_Clock_Enable with Inline; procedure TIM7_Clock_Enable with Inline; procedure WWDG_Clock_Enable with Inline; procedure SPI2_Clock_Enable with Inline; procedure SPI3_Clock_Enable with Inline; procedure USART2_Clock_Enable with Inline; procedure USART3_Clock_Enable with Inline; procedure UART4_Clock_Enable with Inline; procedure UART5_Clock_Enable with Inline; procedure UART7_Clock_Enable with Inline; procedure UART8_Clock_Enable with Inline; procedure I2C1_Clock_Enable with Inline; procedure I2C2_Clock_Enable with Inline; procedure I2C3_Clock_Enable with Inline; procedure PWR_Clock_Enable with Inline; procedure TIM2_Clock_Disable with Inline; procedure TIM3_Clock_Disable with Inline; procedure TIM4_Clock_Disable with Inline; procedure TIM5_Clock_Disable with Inline; procedure TIM6_Clock_Disable with Inline; procedure TIM7_Clock_Disable with Inline; procedure WWDG_Clock_Disable with Inline; procedure SPI2_Clock_Disable with Inline; procedure SPI3_Clock_Disable with Inline; procedure USART2_Clock_Disable with Inline; procedure USART3_Clock_Disable with Inline; procedure UART4_Clock_Disable with Inline; procedure UART5_Clock_Disable with Inline; procedure UART7_Clock_Disable with Inline; procedure UART8_Clock_Disable with Inline; procedure I2C1_Clock_Disable with Inline; procedure I2C2_Clock_Disable with Inline; procedure I2C3_Clock_Disable with Inline; procedure PWR_Clock_Disable with Inline; procedure TIM1_Clock_Enable with Inline; procedure USART1_Clock_Enable with Inline; procedure USART6_Clock_Enable with Inline; procedure ADC1_Clock_Enable with Inline; procedure SDIO_Clock_Enable with Inline; procedure SPI1_Clock_Enable with Inline; procedure SPI4_Clock_Enable with Inline; procedure SYSCFG_Clock_Enable with Inline; procedure TIM9_Clock_Enable with Inline; procedure TIM10_Clock_Enable with Inline; procedure TIM11_Clock_Enable with Inline; procedure SPI5_Clock_Enable with Inline; procedure SPI6_Clock_Enable with Inline; procedure LTDC_Clock_Enable with Inline; procedure TIM1_Clock_Disable with Inline; procedure USART1_Clock_Disable with Inline; procedure USART6_Clock_Disable with Inline; procedure ADC1_Clock_Disable with Inline; procedure SDIO_Clock_Disable with Inline; procedure SPI1_Clock_Disable with Inline; procedure SPI4_Clock_Disable with Inline; procedure SYSCFG_Clock_Disable with Inline; procedure TIM9_Clock_Disable with Inline; procedure TIM10_Clock_Disable with Inline; procedure TIM11_Clock_Disable with Inline; procedure SPI5_Clock_Disable with Inline; procedure SPI6_Clock_Disable with Inline; procedure LTDC_Clock_Disable with Inline; procedure AHB1_Force_Reset with Inline; procedure GPIOA_Force_Reset with Inline; procedure GPIOB_Force_Reset with Inline; procedure GPIOC_Force_Reset with Inline; procedure GPIOD_Force_Reset with Inline; procedure GPIOE_Force_Reset with Inline; procedure GPIOH_Force_Reset with Inline; procedure CRC_Force_Reset with Inline; procedure DMA1_Force_Reset with Inline; procedure DMA2_Force_Reset with Inline; procedure AHB1_Release_Reset with Inline; procedure GPIOA_Release_Reset with Inline; procedure GPIOB_Release_Reset with Inline; procedure GPIOC_Release_Reset with Inline; procedure GPIOD_Release_Reset with Inline; procedure GPIOE_Release_Reset with Inline; procedure GPIOF_Release_Reset with Inline; procedure GPIOG_Release_Reset with Inline; procedure GPIOH_Release_Reset with Inline; procedure GPIOI_Release_Reset with Inline; procedure CRC_Release_Reset with Inline; procedure DMA1_Release_Reset with Inline; procedure DMA2_Release_Reset with Inline; procedure AHB2_Force_Reset with Inline; procedure OTGFS_Force_Reset with Inline; procedure AHB2_Release_Reset with Inline; procedure OTGFS_Release_Reset with Inline; procedure RNG_Force_Reset with Inline; procedure RNG_Release_Reset with Inline; procedure APB1_Force_Reset with Inline; procedure TIM2_Force_Reset with Inline; procedure TIM3_Force_Reset with Inline; procedure TIM4_Force_Reset with Inline; procedure TIM5_Force_Reset with Inline; procedure TIM6_Force_Reset with Inline; procedure TIM7_Force_Reset with Inline; procedure WWDG_Force_Reset with Inline; procedure SPI2_Force_Reset with Inline; procedure SPI3_Force_Reset with Inline; procedure USART2_Force_Reset with Inline; procedure I2C1_Force_Reset with Inline; procedure I2C2_Force_Reset with Inline; procedure I2C3_Force_Reset with Inline; procedure PWR_Force_Reset with Inline; procedure APB1_Release_Reset with Inline; procedure TIM2_Release_Reset with Inline; procedure TIM3_Release_Reset with Inline; procedure TIM4_Release_Reset with Inline; procedure TIM5_Release_Reset with Inline; procedure TIM6_Release_Reset with Inline; procedure TIM7_Release_Reset with Inline; procedure WWDG_Release_Reset with Inline; procedure SPI2_Release_Reset with Inline; procedure SPI3_Release_Reset with Inline; procedure USART2_Release_Reset with Inline; procedure I2C1_Release_Reset with Inline; procedure I2C2_Release_Reset with Inline; procedure I2C3_Release_Reset with Inline; procedure PWR_Release_Reset with Inline; procedure APB2_Force_Reset with Inline; procedure TIM1_Force_Reset with Inline; procedure USART1_Force_Reset with Inline; procedure USART6_Force_Reset with Inline; procedure ADC_Force_Reset with Inline; procedure SDIO_Force_Reset with Inline; procedure SPI1_Force_Reset with Inline; procedure SPI4_Force_Reset with Inline; procedure SYSCFG_Force_Reset with Inline; procedure TIM9_Force_Reset with Inline; procedure TIM10_Force_Reset with Inline; procedure TIM11_Force_Reset with Inline; procedure SPI5_Force_Reset with Inline; procedure SPI6_Force_Reset with Inline; procedure LTDC_Force_Reset with Inline; procedure APB2_Release_Reset with Inline; procedure TIM1_Release_Reset with Inline; procedure USART1_Release_Reset with Inline; procedure USART6_Release_Reset with Inline; procedure ADC_Release_Reset with Inline; procedure SDIO_Release_Reset with Inline; procedure SPI1_Release_Reset with Inline; procedure SPI4_Release_Reset with Inline; procedure SYSCFG_Release_Reset with Inline; procedure TIM9_Release_Reset with Inline; procedure TIM10_Release_Reset with Inline; procedure TIM11_Release_Reset with Inline; procedure SPI5_Release_Reset with Inline; procedure SPI6_Release_Reset with Inline; procedure LTDC_Release_Reset with Inline; procedure FSMC_Clock_Enable with Inline; procedure FSMC_Clock_Disable with Inline; private type RCC_Registers is record CR : Word; -- RCC clock control register at 16#00# PLLCFGR : Word; -- RCC PLL configuration register at 16#04# CFGR : Word; -- RCC clock configuration register at 16#08# CIR : Word; -- RCC clock interrupt register at 16#0C# AHB1RSTR : Word; -- RCC AHB1 peripheral reset register at 16#10# AHB2RSTR : Word; -- RCC AHB2 peripheral reset register at 16#14# AHB3RSTR : Word; -- RCC AHB3 peripheral reset register at 16#18# Reserved_0 : Word; -- Reserved at 16#1C# APB1RSTR : Word; -- RCC APB1 peripheral reset register at 16#20# APB2RSTR : Word; -- RCC APB2 peripheral reset register at 16#24# Reserved_1 : Word; -- Reserved at 16#28# Reserved_2 : Word; -- Reserved at 16#2c# AHB1ENR : Word; -- RCC AHB1 peripheral clock register at 16#30# AHB2ENR : Word; -- RCC AHB2 peripheral clock register at 16#34# AHB3ENR : Word; -- RCC AHB3 peripheral clock register at 16#38# Reserved_3 : Word; -- Reserved at 16#0C# APB1ENR : Word; -- RCC APB1 peripheral clock enable at 16#40# APB2ENR : Word; -- RCC APB2 peripheral clock enable at 16#44# Reserved_4 : Word; -- Reserved at 16#48# Reserved_5 : Word; -- Reserved at 16#4c# AHB1LPENR : Word; -- RCC AHB1 periph. low power clk en. at 16#50# AHB2LPENR : Word; -- RCC AHB2 periph. low power clk en. at 16#54# AHB3LPENR : Word; -- RCC AHB3 periph. low power clk en. at 16#58# Reserved_6 : Word; -- Reserved, 16#5C# APB1LPENR : Word; -- RCC APB1 periph. low power clk en. at 16#60# APB2LPENR : Word; -- RCC APB2 periph. low power clk en. at 16#64# Reserved_7 : Word; -- Reserved at 16#68# Reserved_8 : Word; -- Reserved at 16#6C# BDCR : Word; -- RCC Backup domain control register at 16#70# CSR : Word; -- RCC clock control/status register at 16#74# Reserved_9 : Word; -- Reserved at 16#78# Reserved_10 : Word; -- Reserved at 16#7C# SSCGR : Word; -- RCC spread spectrum clk gen. reg. at 16#80# PLLI2SCFGR : Word; -- RCC PLLI2S configuration register at 16#84# PLLSAICFGR : Word; -- RCC PLLSAI configuration register at 16#88# DCKCFGR : Word; -- RCC DCK configuration register at 16#8C# end record with Volatile; for RCC_Registers use record CR at 0 range 0 .. 31; PLLCFGR at 4 range 0 .. 31; CFGR at 8 range 0 .. 31; CIR at 12 range 0 .. 31; AHB1RSTR at 16 range 0 .. 31; AHB2RSTR at 20 range 0 .. 31; AHB3RSTR at 24 range 0 .. 31; Reserved_0 at 28 range 0 .. 31; APB1RSTR at 32 range 0 .. 31; APB2RSTR at 36 range 0 .. 31; Reserved_1 at 40 range 0 .. 31; Reserved_2 at 44 range 0 .. 31; AHB1ENR at 48 range 0 .. 31; AHB2ENR at 52 range 0 .. 31; AHB3ENR at 56 range 0 .. 31; Reserved_3 at 60 range 0 .. 31; APB1ENR at 64 range 0 .. 31; APB2ENR at 68 range 0 .. 31; Reserved_4 at 72 range 0 .. 31; Reserved_5 at 76 range 0 .. 31; AHB1LPENR at 80 range 0 .. 31; AHB2LPENR at 84 range 0 .. 31; AHB3LPENR at 88 range 0 .. 31; Reserved_6 at 92 range 0 .. 31; APB1LPENR at 96 range 0 .. 31; APB2LPENR at 100 range 0 .. 31; Reserved_7 at 104 range 0 .. 31; Reserved_8 at 108 range 0 .. 31; BDCR at 112 range 0 .. 31; CSR at 116 range 0 .. 31; Reserved_9 at 120 range 0 .. 31; Reserved_10 at 124 range 0 .. 31; SSCGR at 128 range 0 .. 31; PLLI2SCFGR at 132 range 0 .. 31; PLLSAICFGR at 136 range 0 .. 31; DCKCFGR at 140 range 0 .. 31; end record; RCC : RCC_Registers with Volatile, Address => System'To_Address (RCC_Base); --------------------- Constants for RCC_CR register --------------------- HSION : constant := 16#00000001#; HSIRDY : constant := 16#00000002#; HSITRIM : constant := 16#000000F8#; HSITRIM_0 : constant := 16#00000008#; -- Bit 0 HSITRIM_1 : constant := 16#00000010#; -- Bit 1 HSITRIM_2 : constant := 16#00000020#; -- Bit 2 HSITRIM_3 : constant := 16#00000040#; -- Bit 3 HSITRIM_4 : constant := 16#00000080#; -- Bit 4 HSICAL : constant := 16#0000FF00#; HSICAL_0 : constant := 16#00000100#; -- Bit 0 HSICAL_1 : constant := 16#00000200#; -- Bit 1 HSICAL_2 : constant := 16#00000400#; -- Bit 2 HSICAL_3 : constant := 16#00000800#; -- Bit 3 HSICAL_4 : constant := 16#00001000#; -- Bit 4 HSICAL_5 : constant := 16#00002000#; -- Bit 5 HSICAL_6 : constant := 16#00004000#; -- Bit 6 HSICAL_7 : constant := 16#00008000#; -- Bit 7 HSEON : constant := 16#00010000#; HSERDY : constant := 16#00020000#; HSEBYP : constant := 16#00040000#; CSSON : constant := 16#00080000#; PLLON : constant := 16#01000000#; PLLRDY : constant := 16#02000000#; PLLI2SON : constant := 16#04000000#; PLLI2SRDY : constant := 16#08000000#; ------------------ Constants for RCC_PLLCFGR register --------------------- PLLM : constant := 16#0000003F#; PLLM_0 : constant := 16#00000001#; PLLM_1 : constant := 16#00000002#; PLLM_2 : constant := 16#00000004#; PLLM_3 : constant := 16#00000008#; PLLM_4 : constant := 16#00000010#; PLLM_5 : constant := 16#00000020#; PLLN : constant := 16#00007FC0#; PLLN_0 : constant := 16#00000040#; PLLN_1 : constant := 16#00000080#; PLLN_2 : constant := 16#00000100#; PLLN_3 : constant := 16#00000200#; PLLN_4 : constant := 16#00000400#; PLLN_5 : constant := 16#00000800#; PLLN_6 : constant := 16#00001000#; PLLN_7 : constant := 16#00002000#; PLLN_8 : constant := 16#00004000#; PLLP : constant := 16#00030000#; PLLP_0 : constant := 16#00010000#; PLLP_1 : constant := 16#00020000#; PLLSRC : constant := 16#00400000#; PLLSRC_HSE : constant := 16#00400000#; PLLSRC_HSI : constant := 16#00000000#; PLLQ : constant := 16#0F000000#; PLLQ_0 : constant := 16#01000000#; PLLQ_1 : constant := 16#02000000#; PLLQ_2 : constant := 16#04000000#; PLLQ_3 : constant := 16#08000000#; ------------------ Constants for RCC_CFGR register --------------------- -- SW configuration SW : constant := 16#00000003#; -- SW[1:0] bits (System clock Switch) SW_0 : constant := 16#00000001#; -- Bit 0 SW_1 : constant := 16#00000002#; -- Bit 1 SW_HSI : constant := 16#00000000#; -- HSI selected as system clock SW_HSE : constant := 16#00000001#; -- HSE selected as system clock SW_PLL : constant := 16#00000002#; -- PLL selected as system clock -- SWS configuration SWS : constant := 16#0000000C#; -- SWS[1:0] bits (System Clock Switch Status) SWS_0 : constant := 16#00000004#; -- Bit 0 SWS_1 : constant := 16#00000008#; -- Bit 1 SWS_HSI : constant := 16#00000000#; -- HSI oscillator used as system clock SWS_HSE : constant := 16#00000004#; -- HSE oscillator used as system clock SWS_PLL : constant := 16#00000008#; -- PLL used as system clock -- HPRE configuration HPRE : constant := 16#000000F0#; -- HPRE[3:0] bits (AHB prescaler) HPRE_0 : constant := 16#00000010#; -- Bit 0 HPRE_1 : constant := 16#00000020#; -- Bit 1 HPRE_2 : constant := 16#00000040#; -- Bit 2 HPRE_3 : constant := 16#00000080#; -- Bit 3 HPRE_DIV1 : constant := 16#00000000#; -- SYSCLK not divided HPRE_DIV2 : constant := 16#00000080#; -- SYSCLK divided by 2 HPRE_DIV4 : constant := 16#00000090#; -- SYSCLK divided by 4 HPRE_DIV8 : constant := 16#000000A0#; -- SYSCLK divided by 8 HPRE_DIV16 : constant := 16#000000B0#; -- SYSCLK divided by 16 HPRE_DIV64 : constant := 16#000000C0#; -- SYSCLK divided by 64 HPRE_DIV128 : constant := 16#000000D0#; -- SYSCLK divided by 128 HPRE_DIV256 : constant := 16#000000E0#; -- SYSCLK divided by 256 HPRE_DIV512 : constant := 16#000000F0#; -- SYSCLK divided by 512 -- PPRE1 configuration PPRE1 : constant := 16#00001C00#; -- PRE1[2:0] bits (APB1 prescaler) PPRE1_0 : constant := 16#00000400#; -- Bit 0 PPRE1_1 : constant := 16#00000800#; -- Bit 1 PPRE1_2 : constant := 16#00001000#; -- Bit 2 PPRE1_DIV1 : constant := 16#00000000#; -- HCLK not divided PPRE1_DIV2 : constant := 16#00001000#; -- HCLK divided by 2 PPRE1_DIV4 : constant := 16#00001400#; -- HCLK divided by 4 PPRE1_DIV8 : constant := 16#00001800#; -- HCLK divided by 8 PPRE1_DIV16 : constant := 16#00001C00#; -- HCLK divided by 16 -- PPRE2 configuration PPRE2 : constant := 16#0000E000#; -- PRE2[2:0] bits (APB2 prescaler) PPRE2_0 : constant := 16#00002000#; -- Bit 0 PPRE2_1 : constant := 16#00004000#; -- Bit 1 PPRE2_2 : constant := 16#00008000#; -- Bit 2 PPRE2_DIV1 : constant := 16#00000000#; -- HCLK not divided PPRE2_DIV2 : constant := 16#00008000#; -- HCLK divided by 2 PPRE2_DIV4 : constant := 16#0000A000#; -- HCLK divided by 4 PPRE2_DIV8 : constant := 16#0000C000#; -- HCLK divided by 8 PPRE2_DIV16 : constant := 16#0000E000#; -- HCLK divided by 16 -- RTCPRE configuration RTCPRE : constant := 16#001F0000#; RTCPRE_0 : constant := 16#00010000#; RTCPRE_1 : constant := 16#00020000#; RTCPRE_2 : constant := 16#00040000#; RTCPRE_3 : constant := 16#00080000#; RTCPRE_4 : constant := 16#00100000#; -- MCO1 configuration MCO1 : constant := 16#00600000#; MCO1_0 : constant := 16#00200000#; MCO1_1 : constant := 16#00400000#; I2SSRC : constant := 16#00800000#; MCO1PRE : constant := 16#07000000#; MCO1PRE_0 : constant := 16#01000000#; MCO1PRE_1 : constant := 16#02000000#; MCO1PRE_2 : constant := 16#04000000#; MCO2PRE : constant := 16#38000000#; MCO2PRE_0 : constant := 16#08000000#; MCO2PRE_1 : constant := 16#10000000#; MCO2PRE_2 : constant := 16#20000000#; MCO2 : constant := 16#C0000000#; MCO2_0 : constant := 16#40000000#; MCO2_1 : constant := 16#80000000#; ------------------ Constants for RCC_CIR register --------------------- LSIRDYF : constant := 16#00000001#; LSERDYF : constant := 16#00000002#; HSIRDYF : constant := 16#00000004#; HSERDYF : constant := 16#00000008#; PLLRDYF : constant := 16#00000010#; PLLI2SRDYF : constant := 16#00000020#; CSSF : constant := 16#00000080#; LSIRDYIE : constant := 16#00000100#; LSERDYIE : constant := 16#00000200#; HSIRDYIE : constant := 16#00000400#; HSERDYIE : constant := 16#00000800#; PLLRDYIE : constant := 16#00001000#; PLLI2SRDYIE : constant := 16#00002000#; LSIRDYC : constant := 16#00010000#; LSERDYC : constant := 16#00020000#; HSIRDYC : constant := 16#00040000#; HSERDYC : constant := 16#00080000#; PLLRDYC : constant := 16#00100000#; PLLI2SRDYC : constant := 16#00200000#; CSSC : constant := 16#00800000#; ------------------ Constants for RCC_AHB1RSTR register --------------------- -- Note: we include the prefix for the sake of being able to check, when -- using the constants, that they are being assigned to the right bus. AHB1RSTR_GPIOARST : constant := 16#00000001#; AHB1RSTR_GPIOBRST : constant := 16#00000002#; AHB1RSTR_GPIOCRST : constant := 16#00000004#; AHB1RSTR_GPIODRST : constant := 16#00000008#; AHB1RSTR_GPIOERST : constant := 16#00000010#; AHB1RSTR_GPIOFRST : constant := 16#00000020#; AHB1RSTR_GPIOGRST : constant := 16#00000040#; AHB1RSTR_GPIOHRST : constant := 16#00000080#; AHB1RSTR_GPIOIRST : constant := 16#00000100#; AHB1RSTR_CRCRST : constant := 16#00001000#; AHB1RSTR_DMA1RST : constant := 16#00200000#; AHB1RSTR_DMA2RST : constant := 16#00400000#; AHB1RSTR_ETHMACRST : constant := 16#02000000#; AHB1RSTR_OTGHRST : constant := 16#10000000#; ------------------ Constants for RCC_AHB2RSTR register --------------------- AHB2RSTR_DCMIRST : constant := 16#00000001#; AHB2RSTR_RNGRST : constant := 16#00000040#; AHB2RSTR_OTGFSRST : constant := 16#00000080#; ------------------ Constants for RCC_AHB3RSTR register --------------------- AHB3RSTR_FSMCRST : constant := 16#00000001#; ------------------ Constants for RCC_APB1RSTR register --------------------- APB1RSTR_TIM2RST : constant := 16#00000001#; APB1RSTR_TIM3RST : constant := 16#00000002#; APB1RSTR_TIM4RST : constant := 16#00000004#; APB1RSTR_TIM5RST : constant := 16#00000008#; APB1RSTR_TIM6RST : constant := 16#00000010#; APB1RSTR_TIM7RST : constant := 16#00000020#; APB1RSTR_TIM12RST : constant := 16#00000040#; APB1RSTR_TIM13RST : constant := 16#00000080#; APB1RSTR_TIM14RST : constant := 16#00000100#; APB1RSTR_WWDGRST : constant := 16#00000800#; APB1RSTR_SPI2RST : constant := 16#00004000#; APB1RSTR_SPI3RST : constant := 16#00008000#; APB1RSTR_USART2RST : constant := 16#00020000#; APB1RSTR_USART3RST : constant := 16#00040000#; APB1RSTR_UART4RST : constant := 16#00080000#; APB1RSTR_UART5RST : constant := 16#00100000#; APB1RSTR_I2C1RST : constant := 16#00200000#; APB1RSTR_I2C2RST : constant := 16#00400000#; APB1RSTR_I2C3RST : constant := 16#00800000#; APB1RSTR_CAN1RST : constant := 16#02000000#; APB1RSTR_CAN2RST : constant := 16#04000000#; APB1RSTR_PWRRST : constant := 16#10000000#; APB1RSTR_DACRST : constant := 16#20000000#; ------------------ Constants for RCC_APB2RSTR register --------------------- APB2RSTR_TIM1RST : constant := 16#00000001#; APB2RSTR_TIM8RST : constant := 16#00000002#; APB2RSTR_USART1RST : constant := 16#00000010#; APB2RSTR_USART6RST : constant := 16#00000020#; APB2RSTR_ADCRST : constant := 16#00000100#; APB2RSTR_SDIORST : constant := 16#00000800#; APB2RSTR_SPI1RST : constant := 16#00001000#; APB2RSTR_SPI4RST : constant := 16#00002000#; APB2RSTR_SYSCFGRST : constant := 16#00004000#; APB2RSTR_TIM9RST : constant := 16#00010000#; APB2RSTR_TIM10RST : constant := 16#00020000#; APB2RSTR_TIM11RST : constant := 16#00040000#; APB2RSTR_SPI5RST : constant := 16#00100000#; APB2RSTR_SPI6RST : constant := 16#00200000#; APB2RSTR_LTDCRST : constant := 16#04000000#; ------------------ Constants for RCC_AHB1ENR register --------------------- AHB1ENR_GPIOAEN : constant := 16#00000001#; AHB1ENR_GPIOBEN : constant := 16#00000002#; AHB1ENR_GPIOCEN : constant := 16#00000004#; AHB1ENR_GPIODEN : constant := 16#00000008#; AHB1ENR_GPIOEEN : constant := 16#00000010#; AHB1ENR_GPIOFEN : constant := 16#00000020#; AHB1ENR_GPIOGEN : constant := 16#00000040#; AHB1ENR_GPIOHEN : constant := 16#00000080#; AHB1ENR_GPIOIEN : constant := 16#00000100#; AHB1ENR_GPIOJEN : constant := 16#00000200#; AHB1ENR_GPIOKEN : constant := 16#00000400#; AHB1ENR_CRCEN : constant := 16#00001000#; AHB1ENR_BKPSRAMEN : constant := 16#00040000#; AHB1ENR_CCMDATARAMEN : constant := 16#00100000#; AHB1ENR_DMA1EN : constant := 16#00200000#; AHB1ENR_DMA2EN : constant := 16#00400000#; AHB1ENR_ETHMACEN : constant := 16#02000000#; AHB1ENR_ETHMACTXEN : constant := 16#04000000#; AHB1ENR_ETHMACRXEN : constant := 16#08000000#; AHB1ENR_ETHMACPTPEN : constant := 16#10000000#; AHB1ENR_OTGHSEN : constant := 16#20000000#; AHB1ENR_OTGHSULPIEN : constant := 16#40000000#; ------------------ Constants for RCC_AHB2ENR register --------------------- AHB2ENR_DCMIEN : constant := 16#00000001#; AHB2ENR_RNGEN : constant := 16#00000040#; AHB2ENR_OTGFSEN : constant := 16#00000080#; ------------------ Constants for RCC_AHB3ENR register --------------------- AHB3ENR_FSMCEN : constant := 16#00000001#; ------------------ Constants for RCC_APB1ENR register --------------------- APB1ENR_TIM2EN : constant := 16#00000001#; APB1ENR_TIM3EN : constant := 16#00000002#; APB1ENR_TIM4EN : constant := 16#00000004#; APB1ENR_TIM5EN : constant := 16#00000008#; APB1ENR_TIM6EN : constant := 16#00000010#; APB1ENR_TIM7EN : constant := 16#00000020#; APB1ENR_TIM12EN : constant := 16#00000040#; APB1ENR_TIM13EN : constant := 16#00000080#; APB1ENR_TIM14EN : constant := 16#00000100#; APB1ENR_WWDGEN : constant := 16#00000800#; APB1ENR_SPI2EN : constant := 16#00004000#; APB1ENR_SPI3EN : constant := 16#00008000#; APB1ENR_USART2EN : constant := 16#00020000#; APB1ENR_USART3EN : constant := 16#00040000#; APB1ENR_UART4EN : constant := 16#00080000#; APB1ENR_UART5EN : constant := 16#00100000#; APB1ENR_I2C1EN : constant := 16#00200000#; APB1ENR_I2C2EN : constant := 16#00400000#; APB1ENR_I2C3EN : constant := 16#00800000#; APB1ENR_CAN1EN : constant := 16#02000000#; APB1ENR_CAN2EN : constant := 16#04000000#; APB1ENR_PWREN : constant := 16#10000000#; APB1ENR_DACEN : constant := 16#20000000#; APB1ENR_UART7EN : constant := 16#40000000#; APB1ENR_UART8EN : constant := 16#80000000#; ------------------ Constants for RCC_APB2ENR register --------------------- APB2ENR_TIM1EN : constant := 16#00000001#; APB2ENR_TIM8EN : constant := 16#00000002#; APB2ENR_USART1EN : constant := 16#00000010#; APB2ENR_USART6EN : constant := 16#00000020#; APB2ENR_ADC1EN : constant := 16#00000100#; APB2ENR_ADC2EN : constant := 16#00000200#; APB2ENR_ADC3EN : constant := 16#00000400#; APB2ENR_SDIOEN : constant := 16#00000800#; APB2ENR_SPI1EN : constant := 16#00001000#; APB2ENR_SPI4EN : constant := 16#00002000#; APB2ENR_SYSCFGEN : constant := 16#00004000#; APB2ENR_TIM9EN : constant := 16#00010000#; APB2ENR_TIM10EN : constant := 16#00020000#; APB2ENR_TIM11EN : constant := 16#00040000#; APB2ENR_SPI5EN : constant := 16#00100000#; APB2ENR_SPI6EN : constant := 16#00200000#; APB2ENR_LTDCEN : constant := 16#04000000#; ------------------ Constants for RCC_AHB1LPENR register --------------------- AHB1LPENR_GPIOALPEN : constant := 16#00000001#; AHB1LPENR_GPIOBLPEN : constant := 16#00000002#; AHB1LPENR_GPIOCLPEN : constant := 16#00000004#; AHB1LPENR_GPIODLPEN : constant := 16#00000008#; AHB1LPENR_GPIOELPEN : constant := 16#00000010#; AHB1LPENR_GPIOFLPEN : constant := 16#00000020#; AHB1LPENR_GPIOGLPEN : constant := 16#00000040#; AHB1LPENR_GPIOHLPEN : constant := 16#00000080#; AHB1LPENR_GPIOILPEN : constant := 16#00000100#; AHB1LPENR_CRCLPEN : constant := 16#00001000#; AHB1LPENR_FLITFLPEN : constant := 16#00008000#; AHB1LPENR_SRAM1LPEN : constant := 16#00010000#; AHB1LPENR_SRAM2LPEN : constant := 16#00020000#; AHB1LPENR_BKPSRAMLPEN : constant := 16#00040000#; AHB1LPENR_SRAM3LPEN : constant := 16#00080000#; AHB1LPENR_DMA1LPEN : constant := 16#00200000#; AHB1LPENR_DMA2LPEN : constant := 16#00400000#; AHB1LPENR_ETHMACLPEN : constant := 16#02000000#; AHB1LPENR_ETHMACTXLPEN : constant := 16#04000000#; AHB1LPENR_ETHMACRXLPEN : constant := 16#08000000#; AHB1LPENR_ETHMACPTPLPEN : constant := 16#10000000#; AHB1LPENR_OTGHSLPEN : constant := 16#20000000#; AHB1LPENR_OTGHSULPILPEN : constant := 16#40000000#; ------------------ Constants for RCC_AHB2LPENR register --------------------- AHB2LPENR_DCMILPEN : constant := 16#00000001#; AHB2LPENR_RNGLPEN : constant := 16#00000040#; AHB2LPENR_OTGFSLPEN : constant := 16#00000080#; ------------------ Constants for RCC_AHB3LPENR register --------------------- AHB3LPENR_FSMCLPEN : constant := 16#00000001#; ------------------ Constants for RCC_APB1LPENR register --------------------- APB1LPENR_TIM2LPEN : constant := 16#00000001#; APB1LPENR_TIM3LPEN : constant := 16#00000002#; APB1LPENR_TIM4LPEN : constant := 16#00000004#; APB1LPENR_TIM5LPEN : constant := 16#00000008#; APB1LPENR_TIM6LPEN : constant := 16#00000010#; APB1LPENR_TIM7LPEN : constant := 16#00000020#; APB1LPENR_TIM12LPEN : constant := 16#00000040#; APB1LPENR_TIM13LPEN : constant := 16#00000080#; APB1LPENR_TIM14LPEN : constant := 16#00000100#; APB1LPENR_WWDGLPEN : constant := 16#00000800#; APB1LPENR_SPI2LPEN : constant := 16#00004000#; APB1LPENR_SPI3LPEN : constant := 16#00008000#; APB1LPENR_USART2LPEN : constant := 16#00020000#; APB1LPENR_USART3LPEN : constant := 16#00040000#; APB1LPENR_UART4LPEN : constant := 16#00080000#; APB1LPENR_UART5LPEN : constant := 16#00100000#; APB1LPENR_I2C1LPEN : constant := 16#00200000#; APB1LPENR_I2C2LPEN : constant := 16#00400000#; APB1LPENR_I2C3LPEN : constant := 16#00800000#; APB1LPENR_CAN1LPEN : constant := 16#02000000#; APB1LPENR_CAN2LPEN : constant := 16#04000000#; APB1LPENR_PWRLPEN : constant := 16#10000000#; APB1LPENR_DACLPEN : constant := 16#20000000#; ------------------ Constants for RCC_APB2LPENR register --------------------- APB2LPENR_TIM1LPEN : constant := 16#00000001#; APB2LPENR_TIM8LPEN : constant := 16#00000002#; APB2LPENR_USART1LPEN : constant := 16#00000010#; APB2LPENR_USART6LPEN : constant := 16#00000020#; APB2LPENR_ADC1LPEN : constant := 16#00000100#; APB2LPENR_ADC2LPEN : constant := 16#00000200#; APB2LPENR_ADC3LPEN : constant := 16#00000400#; APB2LPENR_SDIOLPEN : constant := 16#00000800#; APB2LPENR_SPI1LPEN : constant := 16#00001000#; APB2LPENR_SPI4LPEN : constant := 16#00002000#; APB2LPENR_SYSCFGLPEN : constant := 16#00004000#; APB2LPENR_TIM9LPEN : constant := 16#00010000#; APB2LPENR_TIM10LPEN : constant := 16#00020000#; APB2LPENR_TIM11LPEN : constant := 16#00040000#; APB2LPENR_SPI5LPEN : constant := 16#00100000#; APB2LPENR_SPI6LPEN : constant := 16#00200000#; APB2LPENR_LTDCLPEN : constant := 16#04000000#; ------------------ Constants for RCC_BDCR register --------------------- LSEON : constant := 16#00000001#; LSERDY : constant := 16#00000002#; LSEBYP : constant := 16#00000004#; RTCSEL : constant := 16#00000300#; RTCSEL_0 : constant := 16#00000100#; RTCSEL_1 : constant := 16#00000200#; RTCEN : constant := 16#00008000#; BDRST : constant := 16#00010000#; ------------------ Constants for RCC_CSR register --------------------- LSION : constant := 16#00000001#; LSIRDY : constant := 16#00000002#; RMVF : constant := 16#01000000#; BORRSTF : constant := 16#02000000#; PADRSTF : constant := 16#04000000#; PORRSTF : constant := 16#08000000#; SFTRSTF : constant := 16#10000000#; WDGRSTF : constant := 16#20000000#; WWDGRSTF : constant := 16#40000000#; LPWRRSTF : constant := 16#80000000#; ------------------ Constants for RCC_SSCGR register --------------------- MODPER : constant := 16#00001FFF#; INCSTEP : constant := 16#0FFFE000#; SPREADSEL : constant := 16#40000000#; SSCGEN : constant := 16#80000000#; ------------------ Constants for RCC_PLLI2SCFGR register --------------------- PLLI2SN : constant := 16#00007FC0#; PLLI2SN_0 : constant := 16#00000040#; PLLI2SN_1 : constant := 16#00000080#; PLLI2SN_2 : constant := 16#00000100#; PLLI2SN_3 : constant := 16#00000200#; PLLI2SN_4 : constant := 16#00000400#; PLLI2SN_5 : constant := 16#00000800#; PLLI2SN_6 : constant := 16#00001000#; PLLI2SN_7 : constant := 16#00002000#; PLLI2SN_8 : constant := 16#00004000#; PLLI2SR : constant := 16#70000000#; PLLI2SR_0 : constant := 16#10000000#; PLLI2SR_1 : constant := 16#20000000#; PLLI2SR_2 : constant := 16#40000000#; end STM32F4.Reset_Clock_Control;
-- The MIT License (MIT) -- Copyright (c) 2015 Pavel Zhukov <landgraf@fedoraproject.org> -- Permission is hereby granted, free of charge, to any person obtaining a copy -- of this software and associated documentation files (the "Software"), to deal -- in the Software without restriction, including without limitation the rights -- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -- copies of the Software, and to permit persons to whom the Software is -- furnished to do so, subject to the following conditions: -- The above copyright notice and this permission notice shall be included in all -- copies or substantial portions of the Software. -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -- SOFTWARE. with Aunit; use Aunit; with Nanomsg.Socket; with Aunit.Simple_Test_Cases; package Nanomsg.Test_Message_Send_Receive is type TC is new Simple_Test_Cases.Test_Case with record Socket1 : Nanomsg.Socket.Socket_T; Socket2 : Nanomsg.Socket.Socket_T; end record; overriding procedure Tear_Down (T : in out Tc); overriding procedure Run_Test (T : in out TC); overriding function Name (T : TC) return Message_String; end Nanomsg.Test_Message_Send_Receive;
generic package Extended_Real.IO is -- E_real Text translation. function e_Real_Image (X : in e_Real; Aft : in Positive := Positive'Last) return String; -- e_Real to Text translation. -- Minimum length of Aft is 12. If less, it gets set to 12. -- The number of digits in the result is the minimum of the 3 quantities: -- Aft+1, Max_No_Of_Digits, and Max_Practical_String_Length. Aft is -- input by the user: it's the number of decimal digits beyond the -- decimal point. Max_No_Of_Digits is slightly greater than the -- Desired_Decimal_Digit_Precision, the generic parameter. (see below.) -- Text to E_real translation. -- The following Sets define white space. In translation from ASCII to -- e_Real only white space may separate the numbers in ASCII format. -- The present setting is standard white space on UNIX workstations and -- Crays. The parenthesis are used by complex numbers. type Set is Array(Character) of Boolean; pragma Pack (Set); Is_White_Space : constant Set := (' ' | ',' | '(' | ')' => True, others => False); Is_Exp_Symbol : constant Set := ('E' | 'e' | 'D' | 'd' => True, others => False); procedure e_Real_Val (X : in String; Y : out e_Real; Last : out Natural); -- Accepts many non Ada standard formats of the sort found in ascii output -- on common machines. Also accepts formats of the sort one is likely -- to type in at the key board. Accepts the following formats: -- -- INTEGER : 1234567 or +1234567 or -1234567 -- DECIMAL : 12.34567 or -.1234567 or +.1234567 or 1234567. -- EXPONENTIAL : 1234.567E+002 or .1234567E002 or 123467.E-03 -- NON_DECIMAL_EXPONENTIAL : -1234567E-003 -- -- Notice that -- 0) Both the 'E' and the '.' are optional. -- 1) If an 'E' exists, then the '.' may be anywhere to the left of the 'E'. -- 2) The Leading sign is optional if its '+'. -- 3) The sign of the exponent is optional if its '+'. -- 4) The set Is_Exp_Symbol determines which Exp symbols are acceptible. -- -- "Last" is the index of the last character of the Number. The purpose -- is to allow one to read numbers sequentially from a string by inputting -- string X(Last+1..X'Length) once the value of Last is determined. -- -- We leave it up to the extended arithm. package to raise constraint_error -- when the Exponent is out of range. E_Format_Error : Exception; private -- Parameters that determine the maximum size of the output string: No_Of_Decimal_Digits_Per_Chunk : constant := 6; -- 8 is good if Radix is big enough (see next Assert). pragma Assert (10.0**No_Of_Decimal_Digits_Per_Chunk < Radix_Minus_1); -- The Decimal value of e_Real is actually calculated in -- Radix 10.0**No_Of_Decimal_Digits_Per_Chunk. i.e. in chunks of 5-8 digits. Bits_Per_e_Real : constant := No_Of_Bits_In_Radix * Mantissa'Length; Decimal_Digits_Per_e_Real : constant := 1 + (Bits_Per_e_Real*1000 - 1) / 3322; -- Ceiling (Bits_Per_e_Real / 3.322). Chunks_Per_e_Real : constant := 1 + (Decimal_Digits_Per_e_Real - 1) / No_Of_Decimal_Digits_Per_Chunk; -- Ceiling (Decimal_Digits_Per_e_Real / No_Of_Decimal_Digits_Per_Chunk) Max_No_Of_Digits : constant Positive := No_Of_Decimal_Digits_Per_Chunk * Chunks_Per_e_Real - 4; -- -- Notice: it keeps some of the digits beyond the number supposedly held -- in the input e_Real (Item). By keeping these extra digits at the end, -- you reduce the Max error in translating from binary to ascii back to -- binary again. -- -- Subtract 4 because they always seem to be noise anyway. pragma Assert (Max_Exponent <= 2 ** (e_Integer'Size - 5)); -- Just making sure. Doesn't work for excessively large Max_Exponent. pragma Assert (e_Integer'Size <= Integer'Size); -- Essentially requires 32 bit Integer or greater. Max_Practical_String_Length : constant Positive := Max_No_Of_Digits + 19; -- Maximum size of the output strings. -- Set to whatever you think is appropriate. -- Strings this size are actually created, so memory must be sufficient. end Extended_Real.IO;
------------------------------------------------------------------------------ -- -- -- GNAT EXAMPLE -- -- -- -- Copyright (C) 2014, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ -- This file provides register definitions for the TMS570LS31 (ARM Cortex R4F) -- microcontrollers from Texas Instruments. pragma Restrictions (No_Elaboration_Code); package TMS570.GPIO is type GPIO_Register is record DIR : Word; -- Data Direction Register DIN : Word; -- Data Input Register DOUT : Word; -- Data Output Register DSET : Word; -- Data Output Set Register DCLR : Word; -- Data Output Clear Register PDR : Word; -- Open Drain Register PULDIS : Word; -- Pullup Disable Register PSL : Word; -- Pull Up/Down Selection Register end record; for GPIO_Register use record DIR at 0 range 0 .. 31; DIN at 4 range 0 .. 31; DOUT at 8 range 0 .. 31; DSET at 12 range 0 .. 31; DCLR at 16 range 0 .. 31; PDR at 20 range 0 .. 31; PULDIS at 24 range 0 .. 31; PSL at 28 range 0 .. 31; end record; -- GPIO pin definitions GPIO_Pin_0 : constant := 16#0000_0001#; GPIO_Pin_1 : constant := 16#0000_0002#; GPIO_Pin_2 : constant := 16#0000_0004#; GPIO_Pin_3 : constant := 16#0000_0008#; GPIO_Pin_4 : constant := 16#0000_0010#; GPIO_Pin_5 : constant := 16#0000_0020#; GPIO_Pin_6 : constant := 16#0000_0040#; GPIO_Pin_7 : constant := 16#0000_0080#; GPIO_Pin_8 : constant := 16#0000_0100#; GPIO_Pin_9 : constant := 16#0000_0200#; GPIO_Pin_10 : constant := 16#0000_0400#; GPIO_Pin_11 : constant := 16#0000_0800#; GPIO_Pin_12 : constant := 16#0000_1000#; GPIO_Pin_13 : constant := 16#0000_2000#; GPIO_Pin_14 : constant := 16#0000_4000#; GPIO_Pin_15 : constant := 16#0000_8000#; GPIO_Pin_16 : constant := 16#0001_0000#; GPIO_Pin_17 : constant := 16#0002_0000#; GPIO_Pin_18 : constant := 16#0004_0000#; GPIO_Pin_19 : constant := 16#0008_0000#; GPIO_Pin_20 : constant := 16#0010_0000#; GPIO_Pin_21 : constant := 16#0020_0000#; GPIO_Pin_22 : constant := 16#0040_0000#; GPIO_Pin_23 : constant := 16#0080_0000#; GPIO_Pin_24 : constant := 16#0100_0000#; GPIO_Pin_25 : constant := 16#0200_0000#; GPIO_Pin_26 : constant := 16#0400_0000#; GPIO_Pin_27 : constant := 16#0800_0000#; GPIO_Pin_28 : constant := 16#1000_0000#; GPIO_Pin_29 : constant := 16#2000_0000#; GPIO_Pin_30 : constant := 16#4000_0000#; GPIO_Pin_31 : constant := 16#8000_0000#; GPIO_Pin_All : constant := 16#FFFF_FFFF#; -- All pins selected subtype GPIO_Pin_Number is Word; function Set (This : GPIO_Register; Pin : GPIO_Pin_Number) return Boolean; pragma Inline (Set); procedure Set_Pin (This : in out GPIO_Register; Pin : GPIO_Pin_Number); pragma Inline (Set_Pin); procedure Clear_Pin (This : in out GPIO_Register; Pin : GPIO_Pin_Number); pragma Inline (Clear_Pin); procedure Toggle_Pin (This : in out GPIO_Register; Pin : GPIO_Pin_Number); pragma Inline (Toggle_Pin); end TMS570.GPIO;
with Ada.Text_IO; use Ada.Text_IO; with Ada.Integer_Text_IO; use Ada.Integer_Text_IO; with Ada.Float_Text_IO; use Ada.Float_Text_IO; with Ada.Unchecked_Deallocation; package body Vecteurs_Creux is procedure Free is new Ada.Unchecked_Deallocation (T_Cellule, T_Vecteur_Creux); procedure Initialiser (V : out T_Vecteur_Creux) is begin V := Null; end Initialiser; procedure Detruire (V: in out T_Vecteur_Creux) is T: T_Vecteur_Creux; begin while V /= Null loop T := V.all.Suivant; Free(V); V := T; end loop; end Detruire; function Est_Nul (V : in T_Vecteur_Creux) return Boolean is begin return V = Null; end Est_Nul; function Composante_Recursif (V : in T_Vecteur_Creux ; Indice : in Integer) return Float is begin if Est_Nul(V) then return 0.0; else if Indice = V.all.Indice then return V.all.Valeur; else return Composante_Recursif(V.all.Suivant, Indice); end if; end if; end Composante_Recursif; function Composante_Iteratif (V : in T_Vecteur_Creux ; Indice : in Integer) return Float is Current: T_Vecteur_Creux; begin Current := V; while Not Est_Nul(Current) and then Current.all.Indice <= Indice loop if Current.all.Indice = Indice then return Current.all.Valeur; else Current := Current.all.Suivant; end if; end loop; return 0.0; end Composante_Iteratif; procedure Modifier (V : in out T_Vecteur_Creux ; Indice : in Integer ; Valeur : in Float ) is Temp: T_Vecteur_Creux; begin if Valeur = 0.0 then -- Chercher la cellule d'indice Indice et la supprimer; if not Est_Nul(V) then if V.all.Indice = Indice then Temp := V; V := V.all.Suivant; Free(Temp); elsif V.all.Indice < Indice then Modifier(V.all.Suivant, Indice, Valeur); end if; end if; elsif Est_Nul(V) then V := new T_Cellule; V.all.Indice := Indice; V.all.Valeur := Valeur; else if V.all.Indice < Indice then if Est_Nul(V.all.Suivant) then Temp := new T_Cellule; Temp.all.Indice := Indice; Temp.all.Valeur := Valeur; V.all.Suivant := Temp; else Modifier(V.all.Suivant, Indice, Valeur); end if; elsif V.all.Indice = Indice then V.all.Valeur := Valeur; else Temp := new T_Cellule; Temp.all.Indice := V.all.Indice; Temp.all.Valeur := V.all.Valeur; Temp.all.Suivant := V.all.Suivant; V.all.Indice := Indice; V.all.Valeur := Valeur; V.all.Suivant := Temp; end if; end if; end Modifier; function Sont_Egaux_Recursif (V1, V2 : in T_Vecteur_Creux) return Boolean is begin if Est_Nul(V1) and Est_Nul(V2) then return True; elsif not Est_Nul(V1) and then not Est_Nul(V2) then return Sont_Egaux_Recursif(V1.all.Suivant, V2.all.Suivant); end if; return False; end Sont_Egaux_Recursif; function Sont_Egaux_Iteratif (V1, V2 : in T_Vecteur_Creux) return Boolean is Temp1: T_Vecteur_Creux; Temp2: T_Vecteur_Creux; begin Temp1 := V1; Temp2 := V2; while not Est_Nul(Temp1) and then not Est_Nul(Temp2) loop if not (Temp1.all.Indice = Temp2.all.Indice and Temp1.all.Valeur = Temp2.all.Valeur) then Temp1 := Null; else Temp1 := Temp1.all.Suivant; Temp2 := Temp2.all.Suivant; end if; end loop; return Est_Nul(Temp1) and Est_Nul(Temp2); end Sont_Egaux_Iteratif; procedure Additionner (V1 : in out T_Vecteur_Creux; V2 : in T_Vecteur_Creux) is Temp1: T_Vecteur_Creux; Temp2: T_Vecteur_Creux; Precedent: T_Vecteur_Creux; begin Temp1 := V1; Temp2 := V2; while not Est_Nul(Temp1) and not Est_Nul(Temp2) loop if Temp1.all.Indice < Temp2.all.Indice then Precedent := Temp1; Temp1 := Temp1.all.Suivant; elsif Temp1.all.Indice = Temp2.all.Indice then if Temp1.all.Valeur + Temp2.all.Valeur = 0.0 then -- Enlever la cellule de cet indice Modifier(Temp1, Temp1.all.Indice, 0.0); if not Est_Nul(Precedent) then Precedent.all.Suivant := Temp1; else V1 := V1.all.Suivant; end if; else Temp1.all.Valeur := Temp1.all.Valeur + Temp2.all.Valeur; Precedent := Temp1; Temp1 := Temp1.all.Suivant; end if; Temp2 := Temp2.all.Suivant; else Modifier(Temp1, Temp2.all.Indice, Temp2.all.Valeur); -- O(1) ! Temp2 := Temp2.all.Suivant; end if; end loop; while not Est_Nul(Temp2) loop if Est_Nul(V1) then V1 := new T_Cellule; V1.all.Indice := Temp2.all.Indice; V1.all.Valeur := Temp2.all.Valeur; Precedent := V1; Temp2 := Temp2.Suivant; else Modifier(Precedent, Temp2.all.Indice, Temp2.all.Valeur); -- O(1) ! Precedent := Precedent.all.Suivant; Temp2 := Temp2.all.Suivant; end if; end loop; end Additionner; function Norme2 (V : in T_Vecteur_Creux) return Float is Somme: Float; Cellule: T_Vecteur_Creux; begin Cellule := V; Somme := 0.0; while not Est_Nul(Cellule) loop Somme := Somme + Cellule.all.Valeur * Cellule.all.Valeur; Cellule := Cellule.all.Suivant; end loop; return Somme; end Norme2; Function Produit_Scalaire (V1, V2: in T_Vecteur_Creux) return Float is Temp1: T_Vecteur_Creux; Temp2: T_Vecteur_Creux; Produit: Float; begin Temp1 := V1; Temp2 := V2; Produit := 0.0; while not (Est_Nul(Temp1) or Est_Nul(Temp2)) loop if Temp1.all.Indice < Temp2.all.Indice then Temp1 := Temp1.all.Suivant; elsif Temp1.all.Indice > Temp2.all.Indice then Temp2 := Temp2.all.Suivant; else Produit := Produit + Temp1.all.Valeur * Temp2.all.Valeur; Temp1 := Temp1.all.Suivant; Temp2 := Temp2.all.Suivant; end if; end loop; return Produit; end Produit_Scalaire; procedure Afficher (V : T_Vecteur_Creux) is begin if V = Null then Put ("--E"); else -- Afficher la composante V.all Put ("-->[ "); Put (V.all.Indice, 0); Put (" | "); Put (V.all.Valeur, Fore => 0, Aft => 1, Exp => 0); Put (" ]"); -- Afficher les autres composantes Afficher (V.all.Suivant); end if; end Afficher; function Nombre_Composantes_Non_Nulles (V: in T_Vecteur_Creux) return Integer is begin if V = Null then return 0; else return 1 + Nombre_Composantes_Non_Nulles (V.all.Suivant); end if; end Nombre_Composantes_Non_Nulles; end Vecteurs_Creux;
package openGL.Palette -- -- Provides a pallete of named colors. -- -- Color values are sourced from WikiPaedia: -- -- - http://en.wikipedia.org/wiki/Primary_color -- - http://en.wikipedia.org/wiki/Secondary_color -- - http://en.wikipedia.org/wiki/Tertiary_color -- - http://en.wikipedia.org/wiki/List_of_colors -- is -------------------- -- Color Primitives -- -- Shades -- type Shade_Level is digits 7 range 0.0 .. 1.0; function Shade_of (Self : in Color; Level : in Shade_Level) return Color; -- -- Darkens a color by the given shade level factor. -- Color Mixing -- type mix_Factor is digits 7 range 0.0 .. 1.0; -- 0.0 returns 'Self', 1.0 returns 'Other'. function mixed (Self : in Color; Other : in Color; Mix : in mix_Factor := 0.5) return Color; -- -- Combines two colors. -- Similarity -- default_Similarity : constant Primary; function is_similar (Self : in Color; To : in Color; Similarity : in Primary := default_Similarity) return Boolean; -- -- Returns true if the none of the red, green, blue components of 'Self' -- differ from 'to' by more than 'Similarity'. -- Random Colors -- function random_Color return Color; ---------------- -- Named Colors -- -- Achromatic -- White : constant Color; Black : constant Color; Grey : constant Color; -- Primary -- Red : constant Color; Green : constant Color; Blue : constant Color; -- Secondary -- Yellow : constant Color; Cyan : constant Color; Magenta : constant Color; -- Tertiary -- Azure : constant Color; Violet : constant Color; Rose : constant Color; Orange : constant Color; Chartreuse : constant Color; spring_Green : constant Color; -- Named (TODO: sort named colors into primary, secondary and tertiary categories). -- Air_Force_blue : constant Color; Alice_blue : constant Color; Alizarin : constant Color; Amaranth : constant Color; Amaranth_cerise : constant Color; Amaranth_deep_purple : constant Color; Amaranth_magenta : constant Color; Amaranth_pink : constant Color; Amaranth_purple : constant Color; Amber : constant Color; Amber_SAE_ECE : constant Color; American_rose : constant Color; Amethyst : constant Color; Android_Green : constant Color; Anti_flash_white : constant Color; Antique_fuchsia : constant Color; Antique_white : constant Color; Apple_green : constant Color; Apricot : constant Color; Aqua : constant Color; Aquamarine : constant Color; Army_green : constant Color; Arsenic : constant Color; Ash_grey : constant Color; Asparagus : constant Color; Atomic_tangerine : constant Color; Auburn : constant Color; Aureolin : constant Color; Azure_mist : constant Color; Baby_blue : constant Color; Baby_pink : constant Color; Battleship_grey : constant Color; Beige : constant Color; Bistre : constant Color; Bittersweet : constant Color; Blue_pigment : constant Color; Blue_RYB : constant Color; Blue_green : constant Color; Blue_violet : constant Color; Bole : constant Color; Bondi_blue : constant Color; Boston_University_Red : constant Color; Brandeis_Blue : constant Color; Brass : constant Color; Brick_red : constant Color; Bright_cerulean : constant Color; Bright_green : constant Color; Bright_lavender : constant Color; Bright_maroon : constant Color; Bright_pink : constant Color; Bright_turquoise : constant Color; Bright_ube : constant Color; Brilliant_lavender : constant Color; Brilliant_rose : constant Color; Brink_Pink : constant Color; British_racing_green : constant Color; Bronze : constant Color; Brown : constant Color; Brown_web : constant Color; Buff : constant Color; Bulgarian_rose : constant Color; Burgundy : constant Color; Burnt_orange : constant Color; Burnt_sienna : constant Color; Burnt_umber : constant Color; Byzantine : constant Color; Byzantium : constant Color; Cadet_blue : constant Color; Cadmium_Green : constant Color; Cadmium_Orange : constant Color; Cadmium_Red : constant Color; Cadmium_Yellow : constant Color; Cambridge_Blue : constant Color; Camel : constant Color; Camouflage_green : constant Color; Canary_yellow : constant Color; Candy_apple_red : constant Color; Candy_pink : constant Color; Caput_mortuum : constant Color; Cardinal : constant Color; Carmine : constant Color; Carmine_pink : constant Color; Carmine_red : constant Color; Carnation_pink : constant Color; Carnelian : constant Color; Carolina_blue : constant Color; Caribbean_green : constant Color; Carrot_orange : constant Color; Ceil : constant Color; Celadon : constant Color; Celestial_blue : constant Color; Cerise : constant Color; Cerise_pink : constant Color; Cerulean : constant Color; Cerulean_blue : constant Color; Chamoisee : constant Color; Champagne : constant Color; Charcoal : constant Color; Chartreuse_web : constant Color; Cherry_blossom_pink : constant Color; Chestnut : constant Color; Chocolate : constant Color; Chrome_yellow : constant Color; Cinereous : constant Color; Cinnabar : constant Color; Cinnamon : constant Color; Citrine : constant Color; Classic_rose : constant Color; Cobalt : constant Color; Columbia_blue : constant Color; Cool_black : constant Color; Cool_grey : constant Color; Copper : constant Color; Copper_rose : constant Color; Coquelicot : constant Color; Coral : constant Color; Coral_pink : constant Color; Coral_red : constant Color; Cordovan : constant Color; Corn : constant Color; Cornsilk : constant Color; Cornflower_blue : constant Color; Cosmic_latte : constant Color; Cotton_candy : constant Color; Cream : constant Color; Crimson : constant Color; Crimson_glory : constant Color; Cyan_process : constant Color; Dandelion : constant Color; Dark_blue : constant Color; Dark_brown : constant Color; Dark_byzantium : constant Color; Dark_candy_apple_red : constant Color; Dark_cerulean : constant Color; Dark_champagne : constant Color; Dark_chestnut : constant Color; Dark_coral : constant Color; Dark_cyan : constant Color; Dark_electric_blue : constant Color; Dark_goldenrod : constant Color; Dark_green : constant Color; Dark_jungle_green : constant Color; Dark_khaki : constant Color; Dark_lava : constant Color; Dark_lavender : constant Color; Dark_magenta : constant Color; Dark_midnight_blue : constant Color; Dark_orange : constant Color; Dark_pastel_green : constant Color; Dark_pink : constant Color; Dark_powder_blue : constant Color; Dark_raspberry : constant Color; Dark_red : constant Color; Dark_salmon : constant Color; Dark_scarlet : constant Color; Dark_sienna : constant Color; Dark_slate_gray : constant Color; Dark_spring_green : constant Color; Dark_tan : constant Color; Dark_tangerine : constant Color; Dark_taupe : constant Color; Dark_terra_cotta : constant Color; Dark_turquoise : constant Color; Dark_violet : constant Color; Dartmouth_green : constant Color; Davys_grey : constant Color; Deep_carmine : constant Color; Deep_carmine_pink : constant Color; Deep_carrot_orange : constant Color; Deep_cerise : constant Color; Deep_champagne : constant Color; Deep_chestnut : constant Color; Deep_fuchsia : constant Color; Deep_jungle_green : constant Color; Deep_lilac : constant Color; Deep_magenta : constant Color; Deep_peach : constant Color; Deep_pink : constant Color; Deep_saffron : constant Color; Deep_sky_blue : constant Color; Denim : constant Color; Desert : constant Color; Desert_sand : constant Color; Dim_gray : constant Color; Dodger_blue : constant Color; Dogwood_Rose : constant Color; Drab : constant Color; Duke_blue : constant Color; Earth_yellow : constant Color; Ecru : constant Color; Eggplant : constant Color; Eggshell : constant Color; Egyptian_blue : constant Color; Electric_blue : constant Color; Electric_cyan : constant Color; Electric_green : constant Color; Electric_indigo : constant Color; Electric_lavender : constant Color; Electric_lime : constant Color; Electric_purple : constant Color; Electric_ultramarine : constant Color; Electric_violet : constant Color; Emerald : constant Color; Eton_blue : constant Color; Fallow : constant Color; Falu_red : constant Color; Fandango : constant Color; Fashion_fuchsia : constant Color; Fawn : constant Color; Feldgrau : constant Color; Fern_green : constant Color; Field_drab : constant Color; Firebrick : constant Color; Fire_engine_red : constant Color; Flame : constant Color; Flamingo_pink : constant Color; Flavescent : constant Color; Flax : constant Color; Forest_green : constant Color; Forest_green_web : constant Color; French_Beige : constant Color; French_Rose : constant Color; Fuchsia : constant Color; Fuchsia_Pink : constant Color; Fulvous : constant Color; Gamboge : constant Color; Ghost_white : constant Color; Glaucous : constant Color; Gold_metallic : constant Color; Gold_web : constant Color; Golden_brown : constant Color; Golden_poppy : constant Color; Golden_yellow : constant Color; Goldenrod : constant Color; Gray : constant Color; Gray_asparagus : constant Color; Green_web : constant Color; Green_pigment : constant Color; Green_RYB : constant Color; Green_yellow : constant Color; Grullo : constant Color; Halaya_ube : constant Color; Han_Blue : constant Color; Han_Purple : constant Color; Harlequin : constant Color; Heliotrope : constant Color; Hollywood_cerise : constant Color; Honeydew : constant Color; Hot_magenta : constant Color; Hot_pink : constant Color; Hunter_green : constant Color; Iceberg : constant Color; Icterine : constant Color; India_green : constant Color; Indian_yellow : constant Color; Indigo : constant Color; Indigo_web : constant Color; International_Klein_Blue : constant Color; International_orange : constant Color; Iris : constant Color; Isabelline : constant Color; Islamic_green : constant Color; Ivory : constant Color; Jade : constant Color; Jazzberry_jam : constant Color; Jonquil : constant Color; June_bud : constant Color; Jungle_green : constant Color; Kelly_green : constant Color; Khaki_web : constant Color; Khaki : constant Color; Languid_lavender : constant Color; Lava : constant Color; Lavender_floral : constant Color; Lavender_web : constant Color; Lavender_blue : constant Color; Lavender_blush : constant Color; Lavender_gray : constant Color; Lavender_indigo : constant Color; Lavender_magenta : constant Color; Lavender_mist : constant Color; Lavender_pink : constant Color; Lavender_purple : constant Color; Lavender_rose : constant Color; Lawn_green : constant Color; Lemon : constant Color; Lemon_chiffon : constant Color; Light_apricot : constant Color; Light_blue : constant Color; Light_carmine_pink : constant Color; Light_coral : constant Color; Light_cornflower_blue : constant Color; Light_fuchsia_pink : constant Color; Light_khaki : constant Color; Light_mauve : constant Color; Light_pink : constant Color; Light_sea_green : constant Color; Light_salmon : constant Color; Light_salmon_pink : constant Color; Light_sky_blue : constant Color; Light_slate_gray : constant Color; Light_Thulian_pink : constant Color; Lilac : constant Color; Lime : constant Color; Lime_web : constant Color; Lime_green : constant Color; Linen : constant Color; Liver : constant Color; Lust : constant Color; Magenta_dye : constant Color; Magenta_process : constant Color; Magic_mint : constant Color; Magnolia : constant Color; Mahogany : constant Color; Maize : constant Color; Majorelle_Blue : constant Color; Malachite : constant Color; Maroon_web : constant Color; Maroon : constant Color; Mauve : constant Color; Mauve_taupe : constant Color; Maya_blue : constant Color; Medium_aquamarine : constant Color; Medium_blue : constant Color; Medium_candy_apple_red : constant Color; Medium_carmine : constant Color; Medium_champagne : constant Color; Medium_electric_blue : constant Color; Medium_jungle_green : constant Color; Medium_lavender_magenta : constant Color; Medium_Persian_blue : constant Color; Medium_purple : constant Color; Medium_red_violet : constant Color; Medium_sea_green : constant Color; Medium_spring_bud : constant Color; Medium_spring_green : constant Color; Medium_taupe : constant Color; Medium_teal_blue : constant Color; Medium_turquoise : constant Color; Midnight_blue : constant Color; Midnight_green : constant Color; Eagle_green : constant Color; Mikado_yellow : constant Color; Mint_green : constant Color; Misty_rose : constant Color; Moccasin : constant Color; Mode_Beige : constant Color; Mordant_red : constant Color; Moss_green : constant Color; Mountbatten_pink : constant Color; Mulberry : constant Color; Mustard : constant Color; Myrtle : constant Color; MSU_Green : constant Color; Nadeshiko_pink : constant Color; Napier_Green : constant Color; Naples_Yellow : constant Color; Navajo_white : constant Color; Navy_Blue : constant Color; Ochre : constant Color; Office_green : constant Color; Old_Gold : constant Color; Old_Lace : constant Color; Old_lavender : constant Color; Old_Rose : constant Color; Olive : constant Color; Olive_Drab_web : constant Color; Olive_Drab : constant Color; Olivine : constant Color; Onyx : constant Color; Opera_mauve : constant Color; Orange_color_wheel : constant Color; Orange_RYB : constant Color; Orange_web : constant Color; Orange_peel : constant Color; Orange_red : constant Color; Orchid : constant Color; Oxford_Blue : constant Color; OU_Crimson_Red : constant Color; Pale_Amaranth_Pink : constant Color; Pale_blue : constant Color; Pale_brown : constant Color; Pale_carmine : constant Color; Pale_cerulean : constant Color; Pale_chestnut : constant Color; Pale_copper : constant Color; Pale_cornflower_blue : constant Color; Pale_gold : constant Color; Pale_magenta : constant Color; Pale_pink : constant Color; Pale_red_violet : constant Color; Pale_robin_egg_blue : constant Color; Pale_silver : constant Color; Pale_spring_bud : constant Color; Pale_taupe : constant Color; Palatinate_blue : constant Color; Palatinate_purple : constant Color; Pansy_purple : constant Color; Papaya_whip : constant Color; Pastel_green : constant Color; Pastel_pink : constant Color; Paynes_grey : constant Color; Peach : constant Color; Peach_orange : constant Color; Peach_puff : constant Color; Peach_yellow : constant Color; Pear : constant Color; Pearl : constant Color; Periwinkle : constant Color; Persian_blue : constant Color; Persian_green : constant Color; Persian_indigo : constant Color; Persian_orange : constant Color; Persian_red : constant Color; Persian_pink : constant Color; Persian_rose : constant Color; Persimmon : constant Color; Phthalo_blue : constant Color; Phthalo_green : constant Color; Piggy_pink : constant Color; Pine_green : constant Color; Pink : constant Color; Pink_orange : constant Color; Pistachio : constant Color; Platinum : constant Color; Plum : constant Color; Portland_Orange : constant Color; Powder_blue : constant Color; Princeton_Orange : constant Color; Prussian_blue : constant Color; Psychedelic_purple : constant Color; Puce : constant Color; Pumpkin : constant Color; Purple_web : constant Color; Purple : constant Color; Purple_Heart : constant Color; Purple_mountain_majesty : constant Color; Purple_taupe : constant Color; Radical_Red : constant Color; Raspberry : constant Color; Raspberry_glace : constant Color; Raspberry_pink : constant Color; Raspberry_rose : constant Color; Raw_umber : constant Color; Razzle_dazzle_rose : constant Color; Razzmatazz : constant Color; Red_pigment : constant Color; Red_RYB : constant Color; Red_violet : constant Color; Rich_black : constant Color; Rich_brilliant_lavender : constant Color; Rich_carmine : constant Color; Rich_electric_blue : constant Color; Rich_lavender : constant Color; Rich_maroon : constant Color; Rifle_green : constant Color; Robin_egg_blue : constant Color; Rose_Ebony : constant Color; Rose_Gold : constant Color; Rose_Madder : constant Color; Rose_pink : constant Color; Rose_quartz : constant Color; Rose_taupe : constant Color; Rose_vale : constant Color; Rosewood : constant Color; Rosso_corsa : constant Color; Rosy_brown : constant Color; Royal_azure : constant Color; Royal_blue : constant Color; Royal_blue_web : constant Color; Royal_fuchsia : constant Color; Royal_purple : constant Color; Ruby : constant Color; Rufous : constant Color; Russet : constant Color; Rust : constant Color; Sacramento_State_green : constant Color; Saddle_brown : constant Color; Safety_orange : constant Color; blaze_orange : constant Color; Saffron : constant Color; St_Patricks_blue : constant Color; Salmon : constant Color; Salmon_pink : constant Color; Sand : constant Color; Sand_dune : constant Color; Sandy_brown : constant Color; Sandy_taupe : constant Color; Sangria : constant Color; Sap_green : constant Color; Sapphire : constant Color; Satin_sheen_gold : constant Color; Scarlet : constant Color; School_bus_yellow : constant Color; Sea_green : constant Color; Seal_brown : constant Color; Seashell : constant Color; Selective_yellow : constant Color; Sepia : constant Color; Shamrock_green : constant Color; Shocking_pink : constant Color; Sienna : constant Color; Silver : constant Color; Skobeloff : constant Color; Sky_blue : constant Color; Sky_magenta : constant Color; Slate_gray : constant Color; Smalt : constant Color; Smoky_black : constant Color; Snow : constant Color; Splashed_white : constant Color; Spring_bud : constant Color; Steel_blue : constant Color; Straw : constant Color; Sunglow : constant Color; Sunset : constant Color; Tan : constant Color; Tangelo : constant Color; Tangerine : constant Color; Tangerine_yellow : constant Color; Taupe : constant Color; Taupe_gray : constant Color; Tea_green : constant Color; Tea_rose_orange : constant Color; Tea_rose : constant Color; Teal : constant Color; Teal_blue : constant Color; Tenne : constant Color; Tawny : constant Color; Terra_cotta : constant Color; Thistle : constant Color; Thulian_pink : constant Color; Tiffany_Blue : constant Color; Tomato : constant Color; Torch_red : constant Color; Tropical_rain_forest : constant Color; Turkish_Rose : constant Color; Turquoise : constant Color; Turquoise_blue : constant Color; Tuscan_red : constant Color; Twilight_lavender : constant Color; Tyrian_purple : constant Color; Ube : constant Color; Ultramarine : constant Color; Ultramarine_blue : constant Color; Ultra_pink : constant Color; Umber : constant Color; United_Nations_blue : constant Color; Upsdell_red : constant Color; UP_Forest_green : constant Color; UP_Maroon : constant Color; Vegas_Gold : constant Color; Venetian_red : constant Color; Vermilion : constant Color; Violet_web : constant Color; Violet_RYB : constant Color; Viridian : constant Color; Vivid_auburn : constant Color; Vivid_burgundy : constant Color; Vivid_violet : constant Color; Warm_black : constant Color; Wenge : constant Color; Wheat : constant Color; White_smoke : constant Color; Wild_blue_yonder : constant Color; Wisteria : constant Color; Xanadu : constant Color; Yale_Blue : constant Color; Yellow_process : constant Color; Yellow_RYB : constant Color; Yellow_green : constant Color; private default_Similarity : constant Primary := to_Primary (3); White : constant Color := (1.0, 1.0, 1.0); Black : constant Color := (0.0, 0.0, 0.0); Grey : constant Color := (0.5, 0.5, 0.5); Red : constant Color := (1.0, 0.0, 0.0); Green : constant Color := (0.0, 1.0, 0.0); Blue : constant Color := (0.0, 0.0, 1.0); Yellow : constant Color := (1.0, 1.0, 0.0); Cyan : constant Color := (0.0, 1.0, 1.0); Magenta : constant Color := (1.0, 0.0, 1.0); Azure : constant Color := +( 0, 127, 255); Violet : constant Color := +(139, 0, 255); Rose : constant Color := +(255, 0, 127); Orange : constant Color := +(255, 127, 0); Chartreuse : constant Color := +(223, 255, 0); spring_Green : constant Color := +( 0, 255, 127); Air_Force_blue : constant Color := +(93, 138, 168); Alice_blue : constant Color := +(240, 248, 255); Alizarin : constant Color := +(227, 38, 54); Amaranth : constant Color := +(229, 43, 80); Amaranth_cerise : constant Color := +(205, 38, 130); Amaranth_deep_purple : constant Color := +(159, 43, 104); Amaranth_magenta : constant Color := +(237, 60, 202); Amaranth_pink : constant Color := +(241, 156, 187); Amaranth_purple : constant Color := +(171, 39, 79); Amber : constant Color := +(255, 191, 0); Amber_SAE_ECE : constant Color := +(255, 126, 0); American_rose : constant Color := +(255, 3, 62); Amethyst : constant Color := +(153, 102, 204); Android_Green : constant Color := +(164, 198, 57); Anti_flash_white : constant Color := +(242, 243, 244); Antique_fuchsia : constant Color := +(145, 92, 131); Antique_white : constant Color := +(250, 235, 215); Apple_green : constant Color := +(141, 182, 0); Apricot : constant Color := +(251, 206, 177); Aqua : constant Color := +(0, 255, 255); Aquamarine : constant Color := +(127, 255, 212); Army_green : constant Color := +(75, 83, 32); Arsenic : constant Color := +(59, 68, 75); Ash_grey : constant Color := +(178, 190, 181); Asparagus : constant Color := +(135, 169, 107); Atomic_tangerine : constant Color := +(255, 153, 102); Auburn : constant Color := +(109, 53, 26); Aureolin : constant Color := +(253, 238, 0); Azure_mist : constant Color := +(240, 255, 255); Baby_blue : constant Color := +(224, 255, 255); Baby_pink : constant Color := +(244, 194, 194); Battleship_grey : constant Color := +(132, 132, 130); Beige : constant Color := +(245, 245, 220); Bistre : constant Color := +(61, 43, 31); Bittersweet : constant Color := +(254, 111, 94); Blue_pigment : constant Color := +(51, 51, 153); Blue_RYB : constant Color := +(2, 71, 254); Blue_green : constant Color := +(0, 221, 221); Blue_violet : constant Color := +(138, 43, 226); Bole : constant Color := +(121, 68, 59); Bondi_blue : constant Color := +(0, 149, 182); Boston_University_Red : constant Color := +(204, 0, 0); Brandeis_Blue : constant Color := +(0, 112, 255); Brass : constant Color := +(181, 166, 66); Brick_red : constant Color := +(203, 65, 84); Bright_cerulean : constant Color := +(29, 172, 214); Bright_green : constant Color := +(102, 255, 0); Bright_lavender : constant Color := +(191, 148, 228); Bright_maroon : constant Color := +(195, 33, 72); Bright_pink : constant Color := +(255, 0, 127); Bright_turquoise : constant Color := +(8, 232, 222); Bright_ube : constant Color := +(209, 159, 232); Brilliant_lavender : constant Color := +(244, 187, 255); Brilliant_rose : constant Color := +(255, 85, 163); Brink_Pink : constant Color := +(251, 96, 127); British_racing_green : constant Color := +(0, 66, 37); Bronze : constant Color := +(205, 127, 50); Brown : constant Color := +(150, 75, 0); Brown_web : constant Color := +(165, 42, 42); Buff : constant Color := +(240, 220, 130); Bulgarian_rose : constant Color := +(72, 6, 7); Burgundy : constant Color := +(128, 0, 32); Burnt_orange : constant Color := +(204, 85, 0); Burnt_sienna : constant Color := +(233, 116, 81); Burnt_umber : constant Color := +(138, 51, 36); Byzantine : constant Color := +(189, 51, 164); Byzantium : constant Color := +(112, 41, 99); Cadet_blue : constant Color := +(95, 158, 160); Cadmium_Green : constant Color := +(0, 107, 60); Cadmium_Orange : constant Color := +(237, 135, 45); Cadmium_Red : constant Color := +(227, 0, 34); Cadmium_Yellow : constant Color := +(255, 246, 0); Cambridge_Blue : constant Color := +(153, 204, 204); Camel : constant Color := +(193, 154, 107); Camouflage_green : constant Color := +(120, 134, 107); Canary_yellow : constant Color := +(255, 239, 0); Candy_apple_red : constant Color := +(255, 8, 0); Candy_pink : constant Color := +(228, 113, 122); Caput_mortuum : constant Color := +(89, 39, 32); Cardinal : constant Color := +(196, 30, 58); Carmine : constant Color := +(150, 0, 24); Carmine_pink : constant Color := +(235, 76, 66); Carmine_red : constant Color := +(255, 0, 51); Carnation_pink : constant Color := +(255, 166, 201); Carnelian : constant Color := +(179, 27, 27); Carolina_blue : constant Color := +(153, 186, 227); Caribbean_green : constant Color := +(0, 204, 153); Carrot_orange : constant Color := +(237, 145, 33); Ceil : constant Color := +(147, 162, 208); Celadon : constant Color := +(172, 225, 175); Celestial_blue : constant Color := +(73, 151, 208); Cerise : constant Color := +(222, 49, 99); Cerise_pink : constant Color := +(236, 59, 131); Cerulean : constant Color := +(0, 123, 167); Cerulean_blue : constant Color := +(42, 82, 190); Chamoisee : constant Color := +(160, 120, 90); Champagne : constant Color := +(247, 231, 206); Charcoal : constant Color := +(54, 69, 79); Chartreuse_web : constant Color := +(127, 255, 0); Cherry_blossom_pink : constant Color := +(255, 183, 197); Chestnut : constant Color := +(205, 92, 92); Chocolate : constant Color := +(123, 63, 0); Chrome_yellow : constant Color := +(255, 167, 0); Cinereous : constant Color := +(152, 129, 123); Cinnabar : constant Color := +(227, 66, 52); Cinnamon : constant Color := +(210, 105, 30); Citrine : constant Color := +(228, 208, 10); Classic_rose : constant Color := +(251, 204, 231); Cobalt : constant Color := +(0, 71, 171); Columbia_blue : constant Color := +(155, 221, 255); Cool_black : constant Color := +(0, 46, 99); Cool_grey : constant Color := +(140, 146, 172); Copper : constant Color := +(184, 115, 51); Copper_rose : constant Color := +(153, 102, 102); Coquelicot : constant Color := +(255, 56, 0); Coral : constant Color := +(255, 127, 80); Coral_pink : constant Color := +(248, 131, 121); Coral_red : constant Color := +(255, 64, 64); Cordovan : constant Color := +(137, 63, 69); Corn : constant Color := +(251, 236, 93); Cornsilk : constant Color := +(255, 248, 220); Cornflower_blue : constant Color := +(100, 149, 237); Cosmic_latte : constant Color := +(255, 248, 231); Cotton_candy : constant Color := +(255, 188, 217); Cream : constant Color := +(255, 253, 208); Crimson : constant Color := +(220, 20, 60); Crimson_glory : constant Color := +(190, 0, 50); Cyan_process : constant Color := +(0, 183, 235); Dandelion : constant Color := +(240, 225, 48); Dark_blue : constant Color := +(0, 0, 139); Dark_brown : constant Color := +(101, 67, 33); Dark_byzantium : constant Color := +(93, 57, 84); Dark_candy_apple_red : constant Color := +(164, 0, 0); Dark_cerulean : constant Color := +(8, 69, 126); Dark_champagne : constant Color := +(194, 178, 128); Dark_chestnut : constant Color := +(152, 105, 96); Dark_coral : constant Color := +(205, 91, 69); Dark_cyan : constant Color := +(0, 139, 139); Dark_electric_blue : constant Color := +(83, 104, 120); Dark_goldenrod : constant Color := +(184, 134, 11); Dark_green : constant Color := +(1, 50, 32); Dark_jungle_green : constant Color := +(26, 36, 33); Dark_khaki : constant Color := +(189, 183, 107); Dark_lava : constant Color := +(72, 60, 50); Dark_lavender : constant Color := +(115, 79, 150); Dark_magenta : constant Color := +(139, 0, 139); Dark_midnight_blue : constant Color := +(0, 51, 102); Dark_orange : constant Color := +(255, 140, 0); Dark_pastel_green : constant Color := +(3, 192, 60); Dark_pink : constant Color := +(231, 84, 128); Dark_powder_blue : constant Color := +(0, 51, 153); Dark_raspberry : constant Color := +(135, 38, 87); Dark_red : constant Color := +(139, 0, 0); Dark_salmon : constant Color := +(233, 150, 122); Dark_scarlet : constant Color := +(86, 3, 25); Dark_sienna : constant Color := +(60, 20, 20); Dark_slate_gray : constant Color := +(47, 79, 79); Dark_spring_green : constant Color := +(23, 114, 69); Dark_tan : constant Color := +(145, 129, 81); Dark_tangerine : constant Color := +(255, 168, 18); Dark_taupe : constant Color := +(72, 60, 50); Dark_terra_cotta : constant Color := +(204, 78, 92); Dark_turquoise : constant Color := +(0, 206, 209); Dark_violet : constant Color := +(148, 0, 211); Dartmouth_green : constant Color := +(13, 128, 15); Davys_grey : constant Color := +(85, 85, 85); Deep_carmine : constant Color := +(169, 32, 62); Deep_carmine_pink : constant Color := +(239, 48, 56); Deep_carrot_orange : constant Color := +(233, 105, 44); Deep_cerise : constant Color := +(218, 50, 135); Deep_champagne : constant Color := +(250, 214, 165); Deep_chestnut : constant Color := +(185, 78, 72); Deep_fuchsia : constant Color := +(193, 84, 193); Deep_jungle_green : constant Color := +(0, 75, 73); Deep_lilac : constant Color := +(153, 85, 187); Deep_magenta : constant Color := +(205, 0, 204); Deep_peach : constant Color := +(255, 203, 164); Deep_pink : constant Color := +(255, 20, 147); Deep_saffron : constant Color := +(255, 153, 51); Deep_sky_blue : constant Color := +(0, 191, 255); Denim : constant Color := +(21, 96, 189); Desert : constant Color := +(193, 154, 107); Desert_sand : constant Color := +(237, 201, 175); Dim_gray : constant Color := +(105, 105, 105); Dodger_blue : constant Color := +(30, 144, 255); Dogwood_Rose : constant Color := +(215, 24, 104); Drab : constant Color := +(150, 113, 23); Duke_blue : constant Color := +(0, 0, 156); Earth_yellow : constant Color := +(225, 169, 95); Ecru : constant Color := +(194, 178, 128); Eggplant : constant Color := +(97, 64, 81); Eggshell : constant Color := +(240, 234, 214); Egyptian_blue : constant Color := +(16, 52, 166); Electric_blue : constant Color := +(125, 249, 255); Electric_cyan : constant Color := +(0, 255, 255); Electric_green : constant Color := +(0, 255, 0); Electric_indigo : constant Color := +(111, 0, 255); Electric_lavender : constant Color := +(244, 187, 255); Electric_lime : constant Color := +(204, 255, 0); Electric_purple : constant Color := +(191, 0, 255); Electric_ultramarine : constant Color := +(63, 0, 255); Electric_violet : constant Color := +(139, 0, 255); Emerald : constant Color := +(80, 200, 120); Eton_blue : constant Color := +(150, 200, 162); Fallow : constant Color := +(193, 154, 107); Falu_red : constant Color := +(128, 24, 24); Fandango : constant Color := +(184, 84, 137); Fashion_fuchsia : constant Color := +(244, 0, 161); Fawn : constant Color := +(229, 170, 112); Feldgrau : constant Color := +(77, 93, 83); Fern_green : constant Color := +(79, 121, 66); Field_drab : constant Color := +(108, 84, 30); Firebrick : constant Color := +(178, 34, 34); Fire_engine_red : constant Color := +(206, 22, 32); Flame : constant Color := +(226, 88, 34); Flamingo_pink : constant Color := +(252, 142, 172); Flavescent : constant Color := +(247, 233, 142); Flax : constant Color := +(238, 220, 130); Forest_green : constant Color := +(1, 68, 33); Forest_green_web : constant Color := +(34, 139, 34); French_Beige : constant Color := +(166, 123, 91); French_Rose : constant Color := +(246, 74, 138); Fuchsia : constant Color := +(255, 0, 255); Fuchsia_Pink : constant Color := +(255, 119, 255); Fulvous : constant Color := +(220, 132, 0); Gamboge : constant Color := +(228, 155, 15); Ghost_white : constant Color := +(248, 248, 255); Glaucous : constant Color := +(96, 130, 182); Gold_metallic : constant Color := +(212, 175, 55); Gold_web : constant Color := +(255, 215, 0); Golden_brown : constant Color := +(153, 101, 21); Golden_poppy : constant Color := +(252, 194, 0); Golden_yellow : constant Color := +(255, 223, 0); Goldenrod : constant Color := +(218, 165, 32); Gray : constant Color := +(128, 128, 128); Gray_asparagus : constant Color := +(70, 89, 69); Green_web : constant Color := +(0, 128, 0); Green_pigment : constant Color := +(0, 165, 80); Green_RYB : constant Color := +(102, 176, 50); Green_yellow : constant Color := +(173, 255, 47); Grullo : constant Color := +(169, 154, 134); Halaya_ube : constant Color := +(102, 56, 84); Han_Blue : constant Color := +(82, 24, 250); Han_Purple : constant Color := +(82, 24, 250); Harlequin : constant Color := +(63, 255, 0); Heliotrope : constant Color := +(223, 115, 255); Hollywood_cerise : constant Color := +(244, 0, 161); Honeydew : constant Color := +(240, 255, 240); Hot_magenta : constant Color := +(255, 0, 204); Hot_pink : constant Color := +(255, 105, 180); Hunter_green : constant Color := +(53, 94, 59); Iceberg : constant Color := +(113, 166, 210); Icterine : constant Color := +(252, 247, 94); India_green : constant Color := +(19, 136, 8); Indian_yellow : constant Color := +(227, 168, 87); Indigo : constant Color := +(0, 65, 106); Indigo_web : constant Color := +(75, 0, 130); International_Klein_Blue : constant Color := +(0, 47, 167); International_orange : constant Color := +(255, 79, 0); Iris : constant Color := +(90, 79, 207); Isabelline : constant Color := +(244, 240, 236); Islamic_green : constant Color := +(0, 144, 0); Ivory : constant Color := +(255, 255, 240); Jade : constant Color := +(0, 168, 107); Jazzberry_jam : constant Color := +(165, 11, 94); Jonquil : constant Color := +(250, 218, 94); June_bud : constant Color := +(189, 218, 87); Jungle_green : constant Color := +(41, 171, 135); Kelly_green : constant Color := +(76, 187, 23); Khaki_web : constant Color := +(195, 176, 145); Khaki : constant Color := +(240, 230, 140); Languid_lavender : constant Color := +(214, 202, 221); Lava : constant Color := +(207, 16, 32); Lavender_floral : constant Color := +(181, 126, 220); Lavender_web : constant Color := +(230, 230, 250); Lavender_blue : constant Color := +(204, 204, 255); Lavender_blush : constant Color := +(255, 240, 245); Lavender_gray : constant Color := +(196, 195, 208); Lavender_indigo : constant Color := +(148, 87, 235); Lavender_magenta : constant Color := +(238, 130, 238); Lavender_mist : constant Color := +(230, 230, 250); Lavender_pink : constant Color := +(251, 174, 210); Lavender_purple : constant Color := +(150, 123, 182); Lavender_rose : constant Color := +(251, 160, 227); Lawn_green : constant Color := +(124, 252, 0); Lemon : constant Color := +(255, 247, 0); Lemon_chiffon : constant Color := +(255, 250, 205); Light_apricot : constant Color := +(253, 213, 177); Light_blue : constant Color := +(173, 216, 230); Light_carmine_pink : constant Color := +(230, 103, 97); Light_coral : constant Color := +(240, 128, 128); Light_cornflower_blue : constant Color := +(173, 216, 230); Light_fuchsia_pink : constant Color := +(249, 132, 229); Light_khaki : constant Color := +(240, 230, 140); Light_mauve : constant Color := +(220, 208, 255); Light_pink : constant Color := +(255, 182, 193); Light_sea_green : constant Color := +(32, 178, 170); Light_salmon : constant Color := +(255, 160, 122); Light_salmon_pink : constant Color := +(255, 153, 153); Light_sky_blue : constant Color := +(135, 206, 250); Light_slate_gray : constant Color := +(119, 136, 153); Light_Thulian_pink : constant Color := +(230, 143, 172); Lilac : constant Color := +(200, 162, 200); Lime : constant Color := +(191, 255, 0); Lime_web : constant Color := +(0, 255, 0); Lime_green : constant Color := +(50, 205, 50); Linen : constant Color := +(250, 240, 230); Liver : constant Color := +(83, 75, 79); Lust : constant Color := +(230, 32, 32); Magenta_dye : constant Color := +(202, 21, 123); Magenta_process : constant Color := +(255, 0, 144); Magic_mint : constant Color := +(170, 240, 209); Magnolia : constant Color := +(248, 244, 255); Mahogany : constant Color := +(192, 64, 0); Maize : constant Color := +(251, 236, 94); Majorelle_Blue : constant Color := +(96, 80, 220); Malachite : constant Color := +(11, 218, 81); Maroon_web : constant Color := +(128, 0, 0); Maroon : constant Color := +(176, 48, 96); Mauve : constant Color := +(224, 176, 255); Mauve_taupe : constant Color := +(145, 95, 109); Maya_blue : constant Color := +(115, 194, 251); Medium_aquamarine : constant Color := +(0, 84, 180); Medium_blue : constant Color := +(0, 0, 205); Medium_candy_apple_red : constant Color := +(226, 6, 44); Medium_carmine : constant Color := +(175, 64, 53); Medium_champagne : constant Color := +(243, 229, 171); Medium_electric_blue : constant Color := +(3, 80, 150); Medium_jungle_green : constant Color := +(28, 53, 45); Medium_lavender_magenta : constant Color := +(204, 153, 204); Medium_Persian_blue : constant Color := +(0, 103, 165); Medium_purple : constant Color := +(147, 112, 219); Medium_red_violet : constant Color := +(187, 51, 133); Medium_sea_green : constant Color := +(60, 179, 113); Medium_spring_bud : constant Color := +(201, 220, 137); Medium_spring_green : constant Color := +(0, 250, 154); Medium_taupe : constant Color := +(103, 76, 71); Medium_teal_blue : constant Color := +(0, 84, 180); Medium_turquoise : constant Color := +(72, 209, 204); Midnight_blue : constant Color := +(25, 25, 112); Midnight_green : constant Color := +(0, 73, 83); Eagle_green : constant Color := +(0, 73, 83); Mikado_yellow : constant Color := +(255, 196, 12); Mint_green : constant Color := +(152, 255, 152); Misty_rose : constant Color := +(255, 228, 225); Moccasin : constant Color := +(250, 235, 215); Mode_Beige : constant Color := +(150, 113, 23); Mordant_red : constant Color := +(174, 12, 0); Moss_green : constant Color := +(173, 223, 173); Mountbatten_pink : constant Color := +(153, 122, 141); Mulberry : constant Color := +(197, 75, 140); Mustard : constant Color := +(255, 219, 88); Myrtle : constant Color := +(33, 66, 30); MSU_Green : constant Color := +(0, 102, 51); Nadeshiko_pink : constant Color := +(246, 173, 198); Napier_Green : constant Color := +(42, 128, 0); Naples_Yellow : constant Color := +(250, 218, 94); Navajo_white : constant Color := +(255, 222, 173); Navy_Blue : constant Color := +(0, 0, 128); Ochre : constant Color := +(204, 119, 34); Office_green : constant Color := +(0, 128, 0); Old_Gold : constant Color := +(207, 181, 59); Old_Lace : constant Color := +(253, 245, 230); Old_lavender : constant Color := +(121, 104, 120); Old_Rose : constant Color := +(192, 128, 129); Olive : constant Color := +(128, 128, 0); Olive_Drab_web : constant Color := +(107, 142, 35); Olive_Drab : constant Color := +(60, 52, 31); Olivine : constant Color := +(154, 185, 115); Onyx : constant Color := +(15, 15, 15); Opera_mauve : constant Color := +(183, 132, 167); Orange_color_wheel : constant Color := +(255, 127, 0); Orange_RYB : constant Color := +(251, 153, 2); Orange_web : constant Color := +(255, 165, 0); Orange_peel : constant Color := +(255, 159, 0); Orange_red : constant Color := +(255, 69, 0); Orchid : constant Color := +(218, 112, 214); Oxford_Blue : constant Color := +(0, 33, 71); OU_Crimson_Red : constant Color := +(153, 0, 0); Pale_Amaranth_Pink : constant Color := +(221, 190, 195); Pale_blue : constant Color := +(175, 238, 238); Pale_brown : constant Color := +(152, 118, 84); Pale_carmine : constant Color := +(175, 64, 53); Pale_cerulean : constant Color := +(155, 196, 226); Pale_chestnut : constant Color := +(221, 173, 175); Pale_copper : constant Color := +(218, 138, 103); Pale_cornflower_blue : constant Color := +(171, 205, 239); Pale_gold : constant Color := +(230, 190, 138); Pale_magenta : constant Color := +(249, 132, 229); Pale_pink : constant Color := +(250, 218, 221); Pale_red_violet : constant Color := +(219, 112, 147); Pale_robin_egg_blue : constant Color := +(150, 222, 209); Pale_silver : constant Color := +(201, 192, 187); Pale_spring_bud : constant Color := +(236, 235, 189); Pale_taupe : constant Color := +(188, 152, 126); Palatinate_blue : constant Color := +(39, 59, 226); Palatinate_purple : constant Color := +(104, 40, 96); Pansy_purple : constant Color := +(120, 24, 74); Papaya_whip : constant Color := +(255, 239, 213); Pastel_green : constant Color := +(119, 221, 119); Pastel_pink : constant Color := +(255, 209, 220); Paynes_grey : constant Color := +(64, 64, 72); Peach : constant Color := +(255, 229, 180); Peach_orange : constant Color := +(255, 204, 153); Peach_puff : constant Color := +(255, 218, 185); Peach_yellow : constant Color := +(250, 223, 173); Pear : constant Color := +(209, 226, 49); Pearl : constant Color := +(240, 234, 214); Periwinkle : constant Color := +(204, 204, 255); Persian_blue : constant Color := +(28, 57, 187); Persian_green : constant Color := +(0, 166, 147); Persian_indigo : constant Color := +(50, 18, 122); Persian_orange : constant Color := +(217, 144, 88); Persian_red : constant Color := +(204, 51, 51); Persian_pink : constant Color := +(247, 127, 190); Persian_rose : constant Color := +(254, 40, 162); Persimmon : constant Color := +(236, 88, 0); Phthalo_blue : constant Color := +(0, 15, 137); Phthalo_green : constant Color := +(18, 53, 36); Piggy_pink : constant Color := +(253, 221, 230); Pine_green : constant Color := +(1, 121, 111); Pink : constant Color := +(255, 192, 203); Pink_orange : constant Color := +(255, 153, 102); Pistachio : constant Color := +(147, 197, 114); Platinum : constant Color := +(229, 228, 226); Plum : constant Color := +(204, 153, 204); Portland_Orange : constant Color := +(255, 90, 54); Powder_blue : constant Color := +(176, 224, 230); Princeton_Orange : constant Color := +(215, 71, 33); Prussian_blue : constant Color := +(0, 49, 83); Psychedelic_purple : constant Color := +(221, 0, 255); Puce : constant Color := +(204, 136, 153); Pumpkin : constant Color := +(255, 117, 24); Purple_web : constant Color := +(127, 0, 127); Purple : constant Color := +(160, 92, 240); Purple_Heart : constant Color := +(105, 53, 156); Purple_mountain_majesty : constant Color := +(150, 120, 182); Purple_taupe : constant Color := +(80, 64, 77); Radical_Red : constant Color := +(255, 53, 94); Raspberry : constant Color := +(227, 11, 92); Raspberry_glace : constant Color := +(145, 95, 109); Raspberry_pink : constant Color := +(226, 80, 155); Raspberry_rose : constant Color := +(179, 68, 108); Raw_umber : constant Color := +(130, 102, 68); Razzle_dazzle_rose : constant Color := +(255, 51, 204); Razzmatazz : constant Color := +(227, 37, 107); Red_pigment : constant Color := +(237, 28, 36); Red_RYB : constant Color := +(254, 39, 18); Red_violet : constant Color := +(199, 21, 133); Rich_black : constant Color := +(0, 64, 64); Rich_brilliant_lavender : constant Color := +(241, 167, 254); Rich_carmine : constant Color := +(215, 0, 64); Rich_electric_blue : constant Color := +(8, 146, 208); Rich_lavender : constant Color := +(170, 97, 204); Rich_maroon : constant Color := +(176, 48, 96); Rifle_green : constant Color := +(65, 72, 51); Robin_egg_blue : constant Color := +(0, 204, 204); Rose_Ebony : constant Color := +(103, 76, 71); Rose_Gold : constant Color := +(183, 110, 121); Rose_Madder : constant Color := +(227, 38, 54); Rose_pink : constant Color := +(255, 102, 204); Rose_quartz : constant Color := +(170, 152, 169); Rose_taupe : constant Color := +(144, 93, 93); Rose_vale : constant Color := +(171, 78, 82); Rosewood : constant Color := +(101, 0, 11); Rosso_corsa : constant Color := +(212, 0, 0); Rosy_brown : constant Color := +(188, 143, 143); Royal_azure : constant Color := +(0, 56, 168); Royal_blue : constant Color := +(0, 35, 102); Royal_blue_web : constant Color := +(65, 105, 225); Royal_fuchsia : constant Color := +(202, 44, 146); Royal_purple : constant Color := +(107, 63, 160); Ruby : constant Color := +(224, 17, 95); Rufous : constant Color := +(168, 28, 7); Russet : constant Color := +(128, 70, 27); Rust : constant Color := +(183, 65, 14); Sacramento_State_green : constant Color := +(0, 86, 63); Saddle_brown : constant Color := +(139, 69, 19); Safety_orange : constant Color := +(255, 102, 0); blaze_orange : constant Color := +(255, 102, 0); Saffron : constant Color := +(244, 196, 48); St_Patricks_blue : constant Color := +(35, 41, 122); Salmon : constant Color := +(255, 140, 105); Salmon_pink : constant Color := +(255, 145, 164); Sand : constant Color := +(194, 178, 128); Sand_dune : constant Color := +(150, 113, 23); Sandy_brown : constant Color := +(244, 164, 96); Sandy_taupe : constant Color := +(150, 113, 23); Sangria : constant Color := +(146, 0, 10); Sap_green : constant Color := +(80, 125, 42); Sapphire : constant Color := +(8, 37, 103); Satin_sheen_gold : constant Color := +(203, 161, 53); Scarlet : constant Color := +(255, 32, 0); School_bus_yellow : constant Color := +(255, 216, 0); Sea_green : constant Color := +(46, 139, 87); Seal_brown : constant Color := +(50, 20, 20); Seashell : constant Color := +(255, 245, 238); Selective_yellow : constant Color := +(255, 186, 0); Sepia : constant Color := +(112, 66, 20); Shamrock_green : constant Color := +(0, 158, 96); Shocking_pink : constant Color := +(252, 15, 192); Sienna : constant Color := +(136, 45, 23); Silver : constant Color := +(192, 192, 192); Skobeloff : constant Color := +(0, 122, 116); Sky_blue : constant Color := +(135, 206, 235); Sky_magenta : constant Color := +(207, 113, 175); Slate_gray : constant Color := +(112, 128, 144); Smalt : constant Color := +(0, 51, 153); Smoky_black : constant Color := +(16, 12, 8); Snow : constant Color := +(255, 250, 250); Splashed_white : constant Color := +(254, 253, 255); Spring_bud : constant Color := +(167, 252, 0); Steel_blue : constant Color := +(70, 130, 180); Straw : constant Color := +(228, 117, 111); Sunglow : constant Color := +(255, 204, 51); Sunset : constant Color := +(250, 214, 165); Tan : constant Color := +(210, 180, 140); Tangelo : constant Color := +(249, 77, 0); Tangerine : constant Color := +(242, 133, 0); Tangerine_yellow : constant Color := +(255, 204, 0); Taupe : constant Color := +(72, 60, 50); Taupe_gray : constant Color := +(139, 133, 137); Tea_green : constant Color := +(208, 240, 192); Tea_rose_orange : constant Color := +(248, 131, 121); Tea_rose : constant Color := +(244, 194, 194); Teal : constant Color := +(0, 128, 128); Teal_blue : constant Color := +(54, 117, 136); Tenne : constant Color := +(205, 87, 0); Tawny : constant Color := +(205, 87, 0); Terra_cotta : constant Color := +(226, 114, 91); Thistle : constant Color := +(216, 191, 216); Thulian_pink : constant Color := +(222, 111, 161); Tiffany_Blue : constant Color := +(10, 186, 181); Tomato : constant Color := +(255, 99, 71); Torch_red : constant Color := +(253, 14, 53); Tropical_rain_forest : constant Color := +(0, 117, 94); Turkish_Rose : constant Color := +(181, 114, 129); Turquoise : constant Color := +(48, 213, 200); Turquoise_blue : constant Color := +(0, 191, 255); Tuscan_red : constant Color := +(123, 54, 54); Twilight_lavender : constant Color := +(138, 73, 107); Tyrian_purple : constant Color := +(102, 2, 60); Ube : constant Color := +(136, 120, 195); Ultramarine : constant Color := +(18, 10, 143); Ultramarine_blue : constant Color := +(65, 102, 245); Ultra_pink : constant Color := +(255, 111, 255); Umber : constant Color := +(99, 81, 71); United_Nations_blue : constant Color := +(91, 146, 229); Upsdell_red : constant Color := +(174, 22, 32); UP_Forest_green : constant Color := +(1, 68, 33); UP_Maroon : constant Color := +(123, 17, 19); Vegas_Gold : constant Color := +(197, 179, 88); Venetian_red : constant Color := +(200, 8, 21); Vermilion : constant Color := +(227, 66, 51); Violet_wheel : constant Color := +(128, 0, 255); Violet_web : constant Color := +(238, 130, 238); Violet_RYB : constant Color := +(134, 1, 175); Viridian : constant Color := +(64, 130, 109); Vivid_auburn : constant Color := +(147, 39, 36); Vivid_burgundy : constant Color := +(159, 29, 53); Vivid_violet : constant Color := +(153, 0, 255); Warm_black : constant Color := +(0, 66, 66); Wenge : constant Color := +(100, 84, 82); Wheat : constant Color := +(245, 222, 179); White_smoke : constant Color := +(245, 245, 245); Wild_blue_yonder : constant Color := +(162, 173, 208); Wisteria : constant Color := +(201, 160, 220); Xanadu : constant Color := +(115, 134, 120); Yale_Blue : constant Color := +(15, 77, 146); Yellow_process : constant Color := +(255, 239, 0); Yellow_RYB : constant Color := +(254, 254, 51); Yellow_green : constant Color := +(154, 205, 50); end openGL.Palette;
----------------------------------------------------------------------- -- api_server -- Example of REST API server -- Copyright (C) 2016 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with ASF.Server.Web; with ASF.Servlets.Rest; with ASF.Servlets.Files; with ASF.Applications; with ASF.Rest; with Util.Log.Loggers; with Monitor; with EL.Contexts.Default; procedure API_Server is CONFIG_PATH : constant String := "samples.properties"; Api : aliased ASF.Servlets.Rest.Rest_Servlet; Files : aliased ASF.Servlets.Files.File_Servlet; App : aliased ASF.Servlets.Servlet_Registry; WS : ASF.Server.Web.AWS_Container; Ctx : EL.Contexts.Default.Default_Context; Log : constant Util.Log.Loggers.Logger := Util.Log.Loggers.Create ("Api_Server"); begin Util.Log.Loggers.Initialize (CONFIG_PATH); App.Set_Init_Parameter (ASF.Applications.VIEW_DIR, "samples/web/monitor"); -- Register the servlets and filters App.Add_Servlet (Name => "api", Server => Api'Unchecked_Access); App.Add_Servlet (Name => "files", Server => Files'Unchecked_Access); -- Define servlet mappings App.Add_Mapping (Name => "api", Pattern => "/api/*"); App.Add_Mapping (Name => "files", Pattern => "*.html"); App.Add_Mapping (Name => "files", Pattern => "*.css"); App.Add_Mapping (Name => "files", Pattern => "*.js"); -- Monitor.Mon_API.Register (App, "api", Ctx); ASF.Rest.Register (App, Monitor.API_Get_Values.Definition); ASF.Rest.Register (App, Monitor.API_Put_Value.Definition); WS.Register_Application ("/monitor", App'Unchecked_Access); Log.Info ("Connect you browser to: http://localhost:8080/monitor/index.html"); WS.Start; delay 6000.0; end API_Server;
-- ___ _ ___ _ _ -- -- / __| |/ (_) | | Common SKilL implementation -- -- \__ \ ' <| | | |__ iterator over all instances -- -- |___/_|\_\_|_|____| by: Timm Felden -- -- -- pragma Ada_2012; with Skill.Types; with Skill.Types.Pools; with Skill.Iterators.Type_Hierarchy_Iterator; with Skill.Iterators.Static_Data; package Skill.Iterators.Type_Order is use Skill.Types; use Skill.Iterators; -- @note in contrast to c++, this implementation uses type erasure as I dont -- see how to solve elaboration otherwise type Iterator is tagged record Ts : aliased Type_Hierarchy_Iterator.Iterator; Data : aliased Static_Data.Iterator; end record; procedure Init (This : access Iterator'Class; First : Skill.Types.Pools.Pool); function Element (This : access Iterator'Class) return Annotation is (This.Data.Element); function Has_Next (This : access Iterator'Class) return Boolean is (This.Data.Has_Next); function Next (This : access Iterator'Class) return Annotation; end Skill.Iterators.Type_Order;