blob_id
stringlengths 40
40
| directory_id
stringlengths 40
40
| path
stringlengths 4
721
| content_id
stringlengths 40
40
| detected_licenses
listlengths 0
57
| license_type
stringclasses 2
values | repo_name
stringlengths 5
91
| snapshot_id
stringlengths 40
40
| revision_id
stringlengths 40
40
| branch_name
stringclasses 321
values | visit_date
timestamp[ns]date 2016-08-12 09:31:09
2023-09-06 10:45:07
| revision_date
timestamp[ns]date 2010-09-28 14:01:40
2023-09-06 06:22:19
| committer_date
timestamp[ns]date 2010-09-28 14:01:40
2023-09-06 06:22:19
| github_id
int64 426
681M
| star_events_count
int64 101
243k
| fork_events_count
int64 0
110k
| gha_license_id
stringclasses 23
values | gha_event_created_at
timestamp[ns]date 2012-06-28 18:51:49
2023-09-14 21:59:16
⌀ | gha_created_at
timestamp[ns]date 2008-02-11 22:55:26
2023-08-10 11:14:58
⌀ | gha_language
stringclasses 147
values | src_encoding
stringclasses 26
values | language
stringclasses 2
values | is_vendor
bool 2
classes | is_generated
bool 2
classes | length_bytes
int64 6
10.2M
| extension
stringclasses 115
values | filename
stringlengths 3
113
| content
stringlengths 6
10.2M
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1d27878840126a1a828a3518d455cfc79afcc288
|
f9e7d65cb784c01a0200145ba8d289afe41d4a56
|
/include/i2c_slave.h
|
3145d4679bfe1c1ca34dcc28a512896f03cdc661
|
[
"BSD-3-Clause"
] |
permissive
|
FrameworkComputer/EmbeddedController
|
ad7086769e87d0a4179eae96a7c9ff5e383ff54e
|
f6d6b927eed71550d3475411cfc3e59abe5cef2a
|
refs/heads/hx20-hx30
| 2023-08-08T20:45:10.621169
| 2023-05-26T07:03:59
| 2023-05-26T07:03:59
| 447,021,040
| 846
| 48
|
BSD-3-Clause
| 2023-05-26T07:04:59
| 2022-01-12T00:11:14
|
C
|
UTF-8
|
C
| false
| false
| 619
|
h
|
i2c_slave.h
|
/* Copyright 2019 The Chromium OS Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
/* I2C slave interface for Chrome EC */
#ifndef __CROS_EC_I2CSLV_H
#define __CROS_EC_I2CSLV_H
/* Data structure to define I2C slave port configuration. */
struct i2c_slv_port_t {
const char *name; /* Port name */
int port; /* Port */
uint8_t slave_adr; /* slave address(7-bit without R/W) */
};
extern const struct i2c_slv_port_t i2c_slv_ports[];
extern const unsigned int i2c_slvs_used;
#endif /* __CROS_EC_I2CSLV_H */
|
84a1ec4468da8a6118dd4e93c6ebb6bacf939022
|
cfa39a4c71a733f39bf6d1f32ef540d3a49d608c
|
/tests/unistd/isatty.c
|
5f7edfe886ed95901e0da2192251040459e06f3b
|
[
"MIT"
] |
permissive
|
redox-os/relibc
|
7d622ae036ccfedc31cbb19e7453f9caa1df873c
|
1ef79540776f2290924e5d996ef38c13e9f1d505
|
refs/heads/master
| 2023-08-31T01:42:51.820667
| 2023-06-13T11:34:49
| 2023-06-13T11:34:49
| 123,522,329
| 834
| 73
|
MIT
| 2023-03-08T03:47:15
| 2018-03-02T02:58:07
|
Rust
|
UTF-8
|
C
| false
| false
| 638
|
c
|
isatty.c
|
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include "test_helpers.h"
int main(void) {
int status = isatty(STDOUT_FILENO);
if (status == 1) {
puts("'Tis a tty :D");
} else if (status == 0) {
if (errno == ENOTTY) {
// I wouldn't consider stdout not being a TTY an error
// (CI runners, etc.)
puts("Whatever a tty is, it's not me");
} else {
perror("isatty");
exit(EXIT_FAILURE);
}
} else {
printf("isatty returned %d, unexpected result\n", status);
exit(EXIT_FAILURE);
}
}
|
fe0a060b9229e22225d83e8055ad1c97c9b4476d
|
24acbcc7b5ad20d2cea61b2b2b8190befe7f5bce
|
/Code/Timing/problem.h
|
12c796995105c1ee187e15a74cb53125c059b4c4
|
[
"MIT"
] |
permissive
|
heineman/algorithms-nutshell-2ed
|
a08e2136fb3f9199e119a8aebca1be09a02b86f4
|
6bdaf7ee2878f69a2df00ae7a3274f5d43d24605
|
refs/heads/master
| 2022-09-04T20:53:52.422824
| 2021-12-29T02:34:44
| 2021-12-29T02:34:44
| 43,086,309
| 577
| 226
| null | null | null | null |
UTF-8
|
C
| false
| false
| 1,298
|
h
|
problem.h
|
/**
* @file problem.h Define interface to problem statement
* @brief
* Each problem statement is defined by four methods:
* <ol>
* <li> void prepareInput (int, int, char **)
* <li> void execute()
* <li> void postInputProcessing ()
* <li> void problemUsage()
* </ol>
*
*
* @author George Heineman
* @date 6/15/08
*/
#ifndef _PROBLEM_H
#define _PROBLEM_H
/**
* To use this timing library, your code must provide the following methods:
*
* void problemUsage()
*
* shows what is expected
*
* void prepareInput (int inputSize, int argc, char **argv);
*
* prepare the input and process extra command line arguments
* make sure that you reset optind to 0 if you process args.
*
*
* void postInputProcessing()
*
* performs post-solution processing
*
* void execute()
*
* begin the problem
*
*/
/** Whether run is to be executing in verbose mode. */
extern int verbose;
/** Most important parameter is the number of elements selected. */
extern int numElements;
/** Ensure that COUNT macro adds checks for nil check. */
#ifdef COUNT
#define isNil(p) (p==0&ADD_NIL_COMP)
#else
#define isNil(p) (p==0)
#endif /* COUNT */
#endif /* _PROBLEM_H */
|
3ac16b2e2cf7bf9788d19ba7ccb9bfb0da7d70b6
|
7e10520d82c002eb808df28ff0d3d9f4fdb9bda0
|
/pio/spi/spi_loopback.c
|
ac5897f9ced4d1078e8f44190da090385a23a339
|
[
"BSD-3-Clause"
] |
permissive
|
raspberrypi/pico-examples
|
3229b4320c9fe1acaacb73afba5378921196ab06
|
eca13acf57916a0bd5961028314006983894fc84
|
refs/heads/master
| 2023-09-03T19:53:49.865239
| 2023-06-11T20:15:45
| 2023-06-11T20:15:45
| 331,381,105
| 2,195
| 749
|
BSD-3-Clause
| 2023-09-14T16:25:25
| 2021-01-20T17:31:36
|
C
|
UTF-8
|
C
| false
| false
| 2,148
|
c
|
spi_loopback.c
|
/**
* Copyright (c) 2020 Raspberry Pi (Trading) Ltd.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#include <stdlib.h>
#include <stdio.h>
#include "pico/stdlib.h"
#include "pio_spi.h"
// This program instantiates a PIO SPI with each of the four possible
// CPOL/CPHA combinations, with the serial input and output pin mapped to the
// same GPIO. Any data written into the state machine's TX FIFO should then be
// serialised, deserialised, and reappear in the state machine's RX FIFO.
#define PIN_SCK 18
#define PIN_MOSI 16
#define PIN_MISO 16 // same as MOSI, so we get loopback
#define BUF_SIZE 20
void test(const pio_spi_inst_t *spi) {
static uint8_t txbuf[BUF_SIZE];
static uint8_t rxbuf[BUF_SIZE];
printf("TX:");
for (int i = 0; i < BUF_SIZE; ++i) {
txbuf[i] = rand() >> 16;
rxbuf[i] = 0;
printf(" %02x", (int) txbuf[i]);
}
printf("\n");
pio_spi_write8_read8_blocking(spi, txbuf, rxbuf, BUF_SIZE);
printf("RX:");
bool mismatch = false;
for (int i = 0; i < BUF_SIZE; ++i) {
printf(" %02x", (int) rxbuf[i]);
mismatch = mismatch || rxbuf[i] != txbuf[i];
}
if (mismatch)
printf("\nNope\n");
else
printf("\nOK\n");
}
int main() {
stdio_init_all();
pio_spi_inst_t spi = {
.pio = pio0,
.sm = 0
};
float clkdiv = 31.25f; // 1 MHz @ 125 clk_sys
uint cpha0_prog_offs = pio_add_program(spi.pio, &spi_cpha0_program);
uint cpha1_prog_offs = pio_add_program(spi.pio, &spi_cpha1_program);
for (int cpha = 0; cpha <= 1; ++cpha) {
for (int cpol = 0; cpol <= 1; ++cpol) {
printf("CPHA = %d, CPOL = %d\n", cpha, cpol);
pio_spi_init(spi.pio, spi.sm,
cpha ? cpha1_prog_offs : cpha0_prog_offs,
8, // 8 bits per SPI frame
clkdiv,
cpha,
cpol,
PIN_SCK,
PIN_MOSI,
PIN_MISO
);
test(&spi);
sleep_ms(10);
}
}
}
|
ee796d63453d036a364ccf52c80a10f9ae1775e1
|
9ceacf33fd96913cac7ef15492c126d96cae6911
|
/usr.sbin/eigrpd/interface.c
|
d395fc3a26cc86f5f829888ff8786104b9f9e014
|
[] |
no_license
|
openbsd/src
|
ab97ef834fd2d5a7f6729814665e9782b586c130
|
9e79f3a0ebd11a25b4bff61e900cb6de9e7795e9
|
refs/heads/master
| 2023-09-02T18:54:56.624627
| 2023-09-02T15:16:12
| 2023-09-02T15:16:12
| 66,966,208
| 3,394
| 1,235
| null | 2023-08-08T02:42:25
| 2016-08-30T18:18:25
|
C
|
UTF-8
|
C
| false
| false
| 18,028
|
c
|
interface.c
|
/* $OpenBSD: interface.c,v 1.26 2023/03/08 04:43:13 guenther Exp $ */
/*
* Copyright (c) 2015 Renato Westphal <renato@openbsd.org>
* Copyright (c) 2005 Claudio Jeker <claudio@openbsd.org>
* Copyright (c) 2004, 2005 Esben Norby <norby@openbsd.org>
*
* Permission to use, copy, modify, and 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.
*/
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/ioctl.h>
#include <arpa/inet.h>
#include <ctype.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "eigrpd.h"
#include "eigrpe.h"
#include "log.h"
static __inline int iface_id_compare(struct eigrp_iface *,
struct eigrp_iface *);
static struct iface *if_new(struct eigrpd_conf *, struct kif *);
static void if_del(struct iface *);
static struct if_addr *if_addr_lookup(struct if_addr_head *, struct kaddr *);
static void eigrp_if_start(struct eigrp_iface *);
static void eigrp_if_reset(struct eigrp_iface *);
static void eigrp_if_hello_timer(int, short, void *);
static void eigrp_if_start_hello_timer(struct eigrp_iface *);
static void eigrp_if_stop_hello_timer(struct eigrp_iface *);
static int if_join_ipv4_group(struct iface *, struct in_addr *);
static int if_leave_ipv4_group(struct iface *, struct in_addr *);
static int if_join_ipv6_group(struct iface *, struct in6_addr *);
static int if_leave_ipv6_group(struct iface *, struct in6_addr *);
RB_GENERATE(iface_id_head, eigrp_iface, id_tree, iface_id_compare)
struct iface_id_head ifaces_by_id = RB_INITIALIZER(&ifaces_by_id);
static __inline int
iface_id_compare(struct eigrp_iface *a, struct eigrp_iface *b)
{
return (a->ifaceid - b->ifaceid);
}
static struct iface *
if_new(struct eigrpd_conf *xconf, struct kif *kif)
{
struct iface *iface;
if ((iface = calloc(1, sizeof(*iface))) == NULL)
fatal("if_new: calloc");
TAILQ_INIT(&iface->ei_list);
TAILQ_INIT(&iface->addr_list);
strlcpy(iface->name, kif->ifname, sizeof(iface->name));
/* get type */
if (kif->flags & IFF_POINTOPOINT)
iface->type = IF_TYPE_POINTOPOINT;
if (kif->flags & IFF_BROADCAST &&
kif->flags & IFF_MULTICAST)
iface->type = IF_TYPE_BROADCAST;
if (kif->flags & IFF_LOOPBACK)
iface->type = IF_TYPE_POINTOPOINT;
/* get index and flags */
iface->mtu = kif->mtu;
iface->ifindex = kif->ifindex;
iface->rdomain = kif->rdomain;
iface->flags = kif->flags;
iface->linkstate = kif->link_state;
iface->if_type = kif->if_type;
iface->baudrate = kif->baudrate;
TAILQ_INSERT_TAIL(&xconf->iface_list, iface, entry);
return (iface);
}
static void
if_del(struct iface *iface)
{
struct if_addr *if_addr;
log_debug("%s: interface %s", __func__, iface->name);
while ((if_addr = TAILQ_FIRST(&iface->addr_list)) != NULL) {
TAILQ_REMOVE(&iface->addr_list, if_addr, entry);
free(if_addr);
}
TAILQ_REMOVE(&econf->iface_list, iface, entry);
free(iface);
}
struct iface *
if_lookup(struct eigrpd_conf *xconf, unsigned int ifindex)
{
struct iface *iface;
TAILQ_FOREACH(iface, &xconf->iface_list, entry)
if (iface->ifindex == ifindex)
return (iface);
return (NULL);
}
void
if_addr_new(struct iface *iface, struct kaddr *ka)
{
struct if_addr *if_addr;
struct eigrp_iface *ei;
if (ka->af == AF_INET6 && IN6_IS_ADDR_LINKLOCAL(&ka->addr.v6)) {
iface->linklocal = ka->addr.v6;
if_update(iface, AF_INET6);
return;
}
if (if_addr_lookup(&iface->addr_list, ka) != NULL)
return;
if ((if_addr = calloc(1, sizeof(*if_addr))) == NULL)
fatal("if_addr_new: calloc");
if_addr->af = ka->af;
if_addr->addr = ka->addr;
if_addr->prefixlen = ka->prefixlen;
if_addr->dstbrd = ka->dstbrd;
TAILQ_INSERT_TAIL(&iface->addr_list, if_addr, entry);
TAILQ_FOREACH(ei, &iface->ei_list, i_entry)
if (ei->state == IF_STA_ACTIVE && ei->eigrp->af == if_addr->af)
eigrpe_orig_local_route(ei, if_addr, 0);
if (if_addr->af == AF_INET)
if_update(iface, AF_INET);
}
void
if_addr_del(struct iface *iface, struct kaddr *ka)
{
struct if_addr *if_addr;
struct eigrp_iface *ei;
int af = ka->af;
if (ka->af == AF_INET6 &&
IN6_ARE_ADDR_EQUAL(&iface->linklocal, &ka->addr.v6)) {
memset(&iface->linklocal, 0, sizeof(iface->linklocal));
if_update(iface, AF_INET6);
return;
}
if_addr = if_addr_lookup(&iface->addr_list, ka);
if (if_addr == NULL)
return;
TAILQ_FOREACH(ei, &iface->ei_list, i_entry)
if (ei->state == IF_STA_ACTIVE && ei->eigrp->af == if_addr->af)
eigrpe_orig_local_route(ei, if_addr, 1);
TAILQ_REMOVE(&iface->addr_list, if_addr, entry);
free(if_addr);
if (af == AF_INET)
if_update(iface, AF_INET);
}
static struct if_addr *
if_addr_lookup(struct if_addr_head *addr_list, struct kaddr *ka)
{
struct if_addr *if_addr;
int af = ka->af;
TAILQ_FOREACH(if_addr, addr_list, entry)
if (!eigrp_addrcmp(af, &if_addr->addr, &ka->addr) &&
if_addr->prefixlen == ka->prefixlen &&
!eigrp_addrcmp(af, &if_addr->dstbrd, &ka->dstbrd))
return (if_addr);
return (NULL);
}
in_addr_t
if_primary_addr(struct iface *iface)
{
struct if_addr *if_addr;
TAILQ_FOREACH(if_addr, &iface->addr_list, entry)
if (if_addr->af == AF_INET)
return (if_addr->addr.v4.s_addr);
return (INADDR_ANY);
}
uint8_t
if_primary_addr_prefixlen(struct iface *iface)
{
struct if_addr *if_addr;
TAILQ_FOREACH(if_addr, &iface->addr_list, entry)
if (if_addr->af == AF_INET)
return (if_addr->prefixlen);
return (0);
}
/* up/down events */
void
if_update(struct iface *iface, int af)
{
struct eigrp_iface *ei;
int link_ok;
int addr_ok, addr4_ok = 0, addr6_ok = 0;
struct if_addr *if_addr;
link_ok = (iface->flags & IFF_UP) &&
LINK_STATE_IS_UP(iface->linkstate);
/*
* NOTE: for EIGRPv4, each interface should have at least one valid
* IP address otherwise they can not be enabled in the routing domain.
*/
TAILQ_FOREACH(if_addr, &iface->addr_list, entry) {
if (if_addr->af == AF_INET) {
addr4_ok = 1;
break;
}
}
/* for IPv6 the link-local address is enough. */
if (IN6_IS_ADDR_LINKLOCAL(&iface->linklocal))
addr6_ok = 1;
TAILQ_FOREACH(ei, &iface->ei_list, i_entry) {
if (af != AF_UNSPEC && ei->eigrp->af != af)
continue;
switch (ei->eigrp->af) {
case AF_INET:
addr_ok = addr4_ok;
break;
case AF_INET6:
addr_ok = addr6_ok;
break;
default:
fatalx("if_update: unknown af");
}
if (ei->state == IF_STA_DOWN) {
if (!link_ok || !addr_ok)
continue;
ei->state = IF_STA_ACTIVE;
eigrp_if_start(ei);
} else if (ei->state == IF_STA_ACTIVE) {
if (link_ok && addr_ok)
continue;
ei->state = IF_STA_DOWN;
eigrp_if_reset(ei);
}
}
}
struct eigrp_iface *
eigrp_if_new(struct eigrpd_conf *xconf, struct eigrp *eigrp, struct kif *kif)
{
struct iface *iface;
struct eigrp_iface *ei;
static uint32_t ifacecnt = 1;
iface = if_lookup(xconf, kif->ifindex);
if (iface == NULL)
iface = if_new(xconf, kif);
if ((ei = calloc(1, sizeof(*ei))) == NULL)
fatal("eigrp_if_new: calloc");
ei->state = IF_STA_DOWN;
/* get next unused ifaceid */
while (eigrp_if_lookup_id(ifacecnt++))
;
ei->ifaceid = ifacecnt;
ei->eigrp = eigrp;
ei->iface = iface;
if (ei->iface->flags & IFF_LOOPBACK)
ei->passive = 1;
TAILQ_INIT(&ei->nbr_list);
TAILQ_INIT(&ei->update_list);
TAILQ_INIT(&ei->query_list);
TAILQ_INIT(&ei->summary_list);
TAILQ_INSERT_TAIL(&iface->ei_list, ei, i_entry);
TAILQ_INSERT_TAIL(&eigrp->ei_list, ei, e_entry);
if (RB_INSERT(iface_id_head, &ifaces_by_id, ei) != NULL)
fatalx("eigrp_if_new: RB_INSERT(ifaces_by_id) failed");
return (ei);
}
void
eigrp_if_del(struct eigrp_iface *ei)
{
struct summary_addr *summary;
RB_REMOVE(iface_id_head, &ifaces_by_id, ei);
TAILQ_REMOVE(&ei->eigrp->ei_list, ei, e_entry);
TAILQ_REMOVE(&ei->iface->ei_list, ei, i_entry);
while ((summary = TAILQ_FIRST(&ei->summary_list)) != NULL) {
TAILQ_REMOVE(&ei->summary_list, summary, entry);
free(summary);
}
message_list_clr(&ei->query_list);
message_list_clr(&ei->update_list);
if (ei->state == IF_STA_ACTIVE)
eigrp_if_reset(ei);
if (TAILQ_EMPTY(&ei->iface->ei_list))
if_del(ei->iface);
free(ei);
}
struct eigrp_iface *
eigrp_if_lookup(struct iface *iface, int af, uint16_t as)
{
struct eigrp_iface *ei;
TAILQ_FOREACH(ei, &iface->ei_list, i_entry)
if (ei->eigrp->af == af &&
ei->eigrp->as == as)
return (ei);
return (NULL);
}
struct eigrp_iface *
eigrp_if_lookup_id(uint32_t ifaceid)
{
struct eigrp_iface e;
e.ifaceid = ifaceid;
return (RB_FIND(iface_id_head, &ifaces_by_id, &e));
}
static void
eigrp_if_start(struct eigrp_iface *ei)
{
struct eigrp *eigrp = ei->eigrp;
struct timeval now;
struct if_addr *if_addr;
union eigrpd_addr addr;
log_debug("%s: %s as %u family %s", __func__, ei->iface->name,
eigrp->as, af_name(eigrp->af));
gettimeofday(&now, NULL);
ei->uptime = now.tv_sec;
/* init the dummy self neighbor */
memset(&addr, 0, sizeof(addr));
ei->self = nbr_new(ei, &addr, 0, 1);
nbr_init(ei->self);
TAILQ_FOREACH(if_addr, &ei->iface->addr_list, entry) {
if (if_addr->af != eigrp->af)
continue;
eigrpe_orig_local_route(ei, if_addr, 0);
}
if (ei->passive)
return;
switch (eigrp->af) {
case AF_INET:
if (if_join_ipv4_group(ei->iface, &global.mcast_addr_v4))
return;
break;
case AF_INET6:
if (if_join_ipv6_group(ei->iface, &global.mcast_addr_v6))
return;
break;
default:
fatalx("eigrp_if_start: unknown af");
}
evtimer_set(&ei->hello_timer, eigrp_if_hello_timer, ei);
eigrp_if_start_hello_timer(ei);
}
static void
eigrp_if_reset(struct eigrp_iface *ei)
{
struct eigrp *eigrp = ei->eigrp;
struct nbr *nbr;
log_debug("%s: %s as %u family %s", __func__, ei->iface->name,
eigrp->as, af_name(eigrp->af));
/* the rde will withdraw the connected route for us */
while ((nbr = TAILQ_FIRST(&ei->nbr_list)) != NULL)
nbr_del(nbr);
if (ei->passive)
return;
/* try to cleanup */
switch (eigrp->af) {
case AF_INET:
if_leave_ipv4_group(ei->iface, &global.mcast_addr_v4);
break;
case AF_INET6:
if_leave_ipv6_group(ei->iface, &global.mcast_addr_v6);
break;
default:
fatalx("eigrp_if_reset: unknown af");
}
eigrp_if_stop_hello_timer(ei);
}
/* timers */
static void
eigrp_if_hello_timer(int fd, short event, void *arg)
{
struct eigrp_iface *ei = arg;
struct timeval tv;
send_hello(ei, NULL, 0);
/* reschedule hello_timer */
timerclear(&tv);
tv.tv_sec = ei->hello_interval;
if (evtimer_add(&ei->hello_timer, &tv) == -1)
fatal("eigrp_if_hello_timer");
}
static void
eigrp_if_start_hello_timer(struct eigrp_iface *ei)
{
struct timeval tv;
timerclear(&tv);
tv.tv_sec = ei->hello_interval;
if (evtimer_add(&ei->hello_timer, &tv) == -1)
fatal("eigrp_if_start_hello_timer");
}
static void
eigrp_if_stop_hello_timer(struct eigrp_iface *ei)
{
if (evtimer_pending(&ei->hello_timer, NULL) &&
evtimer_del(&ei->hello_timer) == -1)
fatal("eigrp_if_stop_hello_timer");
}
struct ctl_iface *
if_to_ctl(struct eigrp_iface *ei)
{
static struct ctl_iface ictl;
struct timeval now;
struct nbr *nbr;
ictl.af = ei->eigrp->af;
ictl.as = ei->eigrp->as;
memcpy(ictl.name, ei->iface->name, sizeof(ictl.name));
ictl.ifindex = ei->iface->ifindex;
switch (ei->eigrp->af) {
case AF_INET:
ictl.addr.v4.s_addr = if_primary_addr(ei->iface);
ictl.prefixlen = if_primary_addr_prefixlen(ei->iface);
break;
case AF_INET6:
ictl.addr.v6 = ei->iface->linklocal;
if (!IN6_IS_ADDR_UNSPECIFIED(&ei->iface->linklocal))
ictl.prefixlen = 64;
else
ictl.prefixlen = 0;
break;
default:
fatalx("if_to_ctl: unknown af");
}
ictl.flags = ei->iface->flags;
ictl.linkstate = ei->iface->linkstate;
ictl.mtu = ei->iface->mtu;
ictl.type = ei->iface->type;
ictl.if_type = ei->iface->if_type;
ictl.baudrate = ei->iface->baudrate;
ictl.delay = ei->delay;
ictl.bandwidth = ei->bandwidth;
ictl.hello_holdtime = ei->hello_holdtime;
ictl.hello_interval = ei->hello_interval;
ictl.splithorizon = ei->splithorizon;
ictl.passive = ei->passive;
ictl.nbr_cnt = 0;
gettimeofday(&now, NULL);
if (ei->state != IF_STA_DOWN && ei->uptime != 0)
ictl.uptime = now.tv_sec - ei->uptime;
else
ictl.uptime = 0;
TAILQ_FOREACH(nbr, &ei->nbr_list, entry)
if (!(nbr->flags & (F_EIGRP_NBR_PENDING|F_EIGRP_NBR_SELF)))
ictl.nbr_cnt++;
return (&ictl);
}
/* misc */
void
if_set_sockbuf(int fd)
{
int bsize;
bsize = 65535;
while (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &bsize,
sizeof(bsize)) == -1)
bsize /= 2;
if (bsize != 65535)
log_warnx("%s: recvbuf size only %d", __func__, bsize);
bsize = 65535;
while (setsockopt(fd, SOL_SOCKET, SO_SNDBUF, &bsize,
sizeof(bsize)) == -1)
bsize /= 2;
if (bsize != 65535)
log_warnx("%s: sendbuf size only %d", __func__, bsize);
}
static int
if_join_ipv4_group(struct iface *iface, struct in_addr *addr)
{
struct ip_mreq mreq;
if (iface->group_count_v4++ != 0)
/* already joined */
return (0);
log_debug("%s: interface %s addr %s", __func__, iface->name,
inet_ntoa(*addr));
mreq.imr_multiaddr = *addr;
mreq.imr_interface.s_addr = if_primary_addr(iface);
if (setsockopt(global.eigrp_socket_v4, IPPROTO_IP, IP_ADD_MEMBERSHIP,
(void *)&mreq, sizeof(mreq)) == -1) {
log_warn("%s: error IP_ADD_MEMBERSHIP, interface %s address %s",
__func__, iface->name, inet_ntoa(*addr));
return (-1);
}
return (0);
}
static int
if_leave_ipv4_group(struct iface *iface, struct in_addr *addr)
{
struct ip_mreq mreq;
if (--iface->group_count_v4 != 0)
/* others still joined */
return (0);
log_debug("%s: interface %s addr %s", __func__, iface->name,
inet_ntoa(*addr));
mreq.imr_multiaddr = *addr;
mreq.imr_interface.s_addr = if_primary_addr(iface);
if (setsockopt(global.eigrp_socket_v4, IPPROTO_IP, IP_DROP_MEMBERSHIP,
(void *)&mreq, sizeof(mreq)) == -1) {
log_warn("%s: error IP_DROP_MEMBERSHIP, interface %s "
"address %s", iface->name, __func__, inet_ntoa(*addr));
return (-1);
}
return (0);
}
int
if_set_ipv4_mcast_ttl(int fd, uint8_t ttl)
{
if (setsockopt(fd, IPPROTO_IP, IP_MULTICAST_TTL,
(char *)&ttl, sizeof(ttl)) == -1) {
log_warn("%s: error setting IP_MULTICAST_TTL to %d",
__func__, ttl);
return (-1);
}
return (0);
}
int
if_set_ipv4_mcast(struct iface *iface)
{
in_addr_t addr;
addr = if_primary_addr(iface);
if (setsockopt(global.eigrp_socket_v4, IPPROTO_IP, IP_MULTICAST_IF,
&addr, sizeof(addr)) == -1) {
log_warn("%s: error setting IP_MULTICAST_IF, interface %s",
__func__, iface->name);
return (-1);
}
return (0);
}
int
if_set_ipv4_mcast_loop(int fd)
{
uint8_t loop = 0;
if (setsockopt(fd, IPPROTO_IP, IP_MULTICAST_LOOP,
(char *)&loop, sizeof(loop)) == -1) {
log_warn("%s: error setting IP_MULTICAST_LOOP", __func__);
return (-1);
}
return (0);
}
int
if_set_ipv4_recvif(int fd, int enable)
{
if (setsockopt(fd, IPPROTO_IP, IP_RECVIF, &enable,
sizeof(enable)) == -1) {
log_warn("%s: error setting IP_RECVIF", __func__);
return (-1);
}
return (0);
}
int
if_set_ipv4_hdrincl(int fd)
{
int hincl = 1;
if (setsockopt(fd, IPPROTO_IP, IP_HDRINCL, &hincl, sizeof(hincl)) == -1) {
log_warn("%s: error setting IP_HDRINCL", __func__);
return (-1);
}
return (0);
}
static int
if_join_ipv6_group(struct iface *iface, struct in6_addr *addr)
{
struct ipv6_mreq mreq;
if (iface->group_count_v6++ != 0)
/* already joined */
return (0);
log_debug("%s: interface %s addr %s", __func__, iface->name,
log_in6addr(addr));
mreq.ipv6mr_multiaddr = *addr;
mreq.ipv6mr_interface = iface->ifindex;
if (setsockopt(global.eigrp_socket_v6, IPPROTO_IPV6, IPV6_JOIN_GROUP,
&mreq, sizeof(mreq)) == -1) {
log_warn("%s: error IPV6_JOIN_GROUP, interface %s address %s",
__func__, iface->name, log_in6addr(addr));
return (-1);
}
return (0);
}
static int
if_leave_ipv6_group(struct iface *iface, struct in6_addr *addr)
{
struct ipv6_mreq mreq;
if (--iface->group_count_v6 != 0)
/* others still joined */
return (0);
log_debug("%s: interface %s addr %s", __func__, iface->name,
log_in6addr(addr));
mreq.ipv6mr_multiaddr = *addr;
mreq.ipv6mr_interface = iface->ifindex;
if (setsockopt(global.eigrp_socket_v6, IPPROTO_IPV6, IPV6_LEAVE_GROUP,
(void *)&mreq, sizeof(mreq)) == -1) {
log_warn("%s: error IPV6_LEAVE_GROUP, interface %s address %s",
__func__, iface->name, log_in6addr(addr));
return (-1);
}
return (0);
}
int
if_set_ipv6_mcast(struct iface *iface)
{
if (setsockopt(global.eigrp_socket_v6, IPPROTO_IPV6, IPV6_MULTICAST_IF,
&iface->ifindex, sizeof(iface->ifindex)) == -1) {
log_warn("%s: error setting IPV6_MULTICAST_IF, interface %s",
__func__, iface->name);
return (-1);
}
return (0);
}
int
if_set_ipv6_mcast_loop(int fd)
{
unsigned int loop = 0;
if (setsockopt(fd, IPPROTO_IPV6, IPV6_MULTICAST_LOOP,
(unsigned int *)&loop, sizeof(loop)) == -1) {
log_warn("%s: error setting IPV6_MULTICAST_LOOP", __func__);
return (-1);
}
return (0);
}
int
if_set_ipv6_pktinfo(int fd, int enable)
{
if (setsockopt(fd, IPPROTO_IPV6, IPV6_RECVPKTINFO, &enable,
sizeof(enable)) == -1) {
log_warn("%s: error setting IPV6_RECVPKTINFO", __func__);
return (-1);
}
return (0);
}
int
if_set_ipv6_dscp(int fd, int dscp)
{
if (setsockopt(fd, IPPROTO_IPV6, IPV6_TCLASS, &dscp,
sizeof(dscp)) == -1) {
log_warn("%s: error setting IPV6_TCLASS", __func__);
return (-1);
}
return (0);
}
|
04171ee974b53e1d16bac3d1729f38f55a128bb7
|
ecce427678ecff2a93a47f3b1b664202c7d27617
|
/src/game/behaviors/star_door.inc.c
|
4390efcbbe398d291fd71806f521e66f76198f1a
|
[] |
no_license
|
sm64pc/sm64ex
|
ecf37f31b3f7426c4874254660d856030d789714
|
54cd27ccee45a2403b45f07a00d6043c51149969
|
refs/heads/nightly
| 2023-08-11T12:14:34.424168
| 2023-07-01T11:45:50
| 2023-07-01T11:45:50
| 262,091,731
| 795
| 238
| null | 2023-07-01T11:45:51
| 2020-05-07T15:43:27
|
C
|
UTF-8
|
C
| false
| false
| 1,577
|
c
|
star_door.inc.c
|
// star_door.c.inc
void star_door_update_pos(void) {
o->oVelX = (o->oUnkBC) * coss(o->oMoveAngleYaw);
o->oVelZ = (o->oUnkBC) * -sins(o->oMoveAngleYaw);
o->oPosX += o->oVelX;
o->oPosZ += o->oVelZ;
}
void bhv_star_door_loop(void) {
UNUSED u8 pad[4];
struct Object *sp18;
sp18 = cur_obj_nearest_object_with_behavior(bhvStarDoor);
switch (o->oAction) {
case 0:
cur_obj_become_tangible();
if (0x30000 & o->oInteractStatus)
o->oAction = 1;
if (sp18 != NULL && sp18->oAction != 0)
o->oAction = 1;
break;
case 1:
if (o->oTimer == 0 && (s16)(o->oMoveAngleYaw) >= 0) {
cur_obj_play_sound_2(SOUND_GENERAL_STAR_DOOR_OPEN);
queue_rumble_data(35, 30);
}
cur_obj_become_intangible();
o->oUnkBC = -8.0f;
star_door_update_pos();
if (o->oTimer >= 16)
o->oAction++;
break;
case 2:
if (o->oTimer >= 31)
o->oAction++;
break;
case 3:
if (o->oTimer == 0 && (s16)(o->oMoveAngleYaw) >= 0) {
cur_obj_play_sound_2(SOUND_GENERAL_STAR_DOOR_CLOSE);
queue_rumble_data(35, 30);
}
o->oUnkBC = 8.0f;
star_door_update_pos();
if (o->oTimer >= 16)
o->oAction++;
break;
case 4:
o->oInteractStatus = 0;
o->oAction = 0;
break;
}
}
|
9d4ec0377e85da33670af6f7b105a3b1076f1e4e
|
99bdb3251fecee538e0630f15f6574054dfc1468
|
/bsp/airm2m/air105/libraries/HAL_Driver/Inc/core_spi.h
|
2821babfe453068252accb4e47798acf36315473
|
[
"Apache-2.0",
"Zlib",
"LicenseRef-scancode-proprietary-license",
"MIT",
"BSD-3-Clause",
"X11",
"BSD-4-Clause-UC",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
RT-Thread/rt-thread
|
03a7c52c2aeb1b06a544143b0e803d72f47d1ece
|
3602f891211904a27dcbd51e5ba72fefce7326b2
|
refs/heads/master
| 2023-09-01T04:10:20.295801
| 2023-08-31T16:20:55
| 2023-08-31T16:20:55
| 7,408,108
| 9,599
| 5,805
|
Apache-2.0
| 2023-09-14T13:37:26
| 2013-01-02T14:49:21
|
C
|
UTF-8
|
C
| false
| false
| 2,204
|
h
|
core_spi.h
|
/*
* Copyright (c) 2022 OpenLuat & AirM2M
*
* 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.
*/
#ifndef __CORE_SPI_H__
#define __CORE_SPI_H__
#include "bsp_common.h"
void SPI_MasterInit(uint8_t SpiID, uint8_t DataBit, uint8_t Mode, uint32_t Speed, CBFuncEx_t CB, void *pUserData);
int32_t SPI_Transfer(uint8_t SpiID, const uint8_t *TxData, uint8_t *RxData, uint32_t Len, uint8_t UseDMA);
/*
* polling传输,不发生线程调度
*/
int32_t SPI_BlockTransfer(uint8_t SpiID, const uint8_t *TxData, uint8_t *RxData, uint32_t Len);
/*
* 类似spiflash的cmd+data型传输用,先发WLen数据,忽略Rx数据,再接收RLen数据
*/
int32_t SPI_FlashBlockTransfer(uint8_t SpiID, const uint8_t *TxData, uint32_t WLen, uint8_t *RxData, uint32_t RLen);
void SPI_DMATxInit(uint8_t SpiID, uint8_t Stream, uint32_t Channel);
void SPI_DMARxInit(uint8_t SpiID, uint8_t Stream, uint32_t Channel);
void SPI_TransferStop(uint8_t UartID);
uint8_t SPI_IsTransferBusy(uint8_t UartID);
void SPI_SetNewConfig(uint8_t SpiID, uint32_t Speed, uint8_t NewMode);
void SPI_SetCallbackFun(uint8_t SpiID, CBFuncEx_t CB, void *pUserData);
void SPI_SetTxOnlyFlag(uint8_t SpiID, uint8_t OnOff);
#endif
|
9df66b30cec1ad8c18f78a19d648a09485dffa0e
|
676acab8ff535019faff7da3afb8eecc3fa127f5
|
/src/hal/gps/gps.h
|
42c2a8fee9d95544303630c72e573084437b3c89
|
[
"Apache-2.0"
] |
permissive
|
Firmament-Autopilot/FMT-Firmware
|
f8c324577245bd7e91af436954b4ce9421acbb41
|
0212fe89820376bfbedaded519552f6b011a7b8a
|
refs/heads/master
| 2023-09-01T11:37:46.194145
| 2023-08-29T06:33:10
| 2023-08-29T06:33:10
| 402,557,689
| 351
| 143
|
Apache-2.0
| 2023-09-12T05:28:39
| 2021-09-02T20:42:56
|
C
|
UTF-8
|
C
| false
| false
| 3,592
|
h
|
gps.h
|
/******************************************************************************
* Copyright 2020 The Firmament Authors. All Rights Reserved.
*
* 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.
*****************************************************************************/
#ifndef GPS_H__
#define GPS_H__
#include <firmament.h>
#ifdef __cplusplus
extern "C" {
#endif
/* gps read pos */
#define GPS_READ_REPORT 0
/* gps command */
#define GPS_CMD_INIT 0x10
#define GPS_CMD_OPEN 0x11
#define GPS_CMD_CLOSE 0x12
#define GPS_CMD_CHECK_READY 0x20
typedef struct {
uint32_t timestamp_position; /**< Timestamp for position information */
int32_t lat; /**< Latitude in 1E-7 degrees */
int32_t lon; /**< Longitude in 1E-7 degrees */
int32_t alt; /**< Altitude in 1E-3 meters (millimeters) above MSL */
uint32_t timestamp_variance;
float s_variance_m_s; /**< speed accuracy estimate m/s */
float c_variance_rad; /**< course accuracy estimate rad */
uint8_t fix_type; /**< 0-1: no fix, 2: 2D fix, 3: 3D fix. Some applications will not use the value of this field unless it is at least two, so always correctly fill in the fix. */
float eph; /**< GPS HDOP horizontal dilution of position in m */
float epv; /**< GPS VDOP horizontal dilution of position in m */
uint16_t noise_per_ms; /**< */
uint16_t jamming_indicator; /**< */
uint32_t timestamp_velocity; /**< Timestamp for velocity informations */
float vel_m_s; /**< GPS ground speed (m/s) */
float vel_n_m_s; /**< North velocity in m/s */
float vel_e_m_s; /**< East velocity in m/s */
float vel_d_m_s; /**< Down velocity in m/s */
float cog_rad; /**< Course over ground (NOT heading, but direction of movement) in rad, -PI..PI */
uint8_t vel_ned_valid; /**< Flag to indicate if NED speed is valid */
uint32_t timestamp_time; /**< Timestamp for time information */
uint32_t time_gps_usec; /**< Timestamp (microseconds in GPS format), this is the timestamp which comes from the gps module */
uint8_t satellites_used; /**< Number of satellites used */
float hdop;
float ndop;
float edop;
float vdop;
float tdop;
uint32_t alt_ellipsoid;
} gps_report_t;
struct gps_device {
struct rt_device parent;
const struct gps_ops* ops;
};
typedef struct gps_device* gps_dev_t;
/* gps driver opeations */
struct gps_ops {
/**
* @brief gps control function (optional)
* @param dev gps device
* @param cmd operation command
* @param arg command argument
*/
rt_err_t (*gps_control)(gps_dev_t dev, int cmd, void* arg);
/**
* @brief gps read function
* @param dev gps device
* @param report gps report buffer
*/
rt_size_t (*gps_read)(gps_dev_t dev, gps_report_t* report);
};
rt_err_t hal_gps_register(gps_dev_t gps_dev, const char* name, rt_uint32_t flag, void* data);
#ifdef __cplusplus
}
#endif
#endif /* GPS_H__ */
|
d82c57b73b706475698e0370753987d6bd748afc
|
7eaf54a78c9e2117247cb2ab6d3a0c20719ba700
|
/SOFTWARE/A64-TERES/u-boot_new/sunxi_spl/boot0/load_mmc/load_boot1_from_sdmmc.c
|
9eb096356e3f384e72afd28938857349088b9622
|
[
"GPL-2.0-or-later",
"LicenseRef-scancode-free-unknown",
"Apache-2.0"
] |
permissive
|
OLIMEX/DIY-LAPTOP
|
ae82f4ee79c641d9aee444db9a75f3f6709afa92
|
a3fafd1309135650bab27f5eafc0c32bc3ca74ee
|
refs/heads/rel3
| 2023-08-04T01:54:19.483792
| 2023-04-03T07:18:12
| 2023-04-03T07:18:12
| 80,094,055
| 507
| 92
|
Apache-2.0
| 2023-04-03T07:05:59
| 2017-01-26T07:25:50
|
C
|
UTF-8
|
C
| false
| false
| 6,274
|
c
|
load_boot1_from_sdmmc.c
|
/*
************************************************************************************************************************
* eGON
* the Embedded GO-ON Bootloader System
*
* Copyright(C), 2006-2009, SoftWinners Microelectronic Co., Ltd.
* All Rights Reserved
*
* File Name : load_boot1_from_sdmmc.c
*
* Author : Gary.Wang
*
* Version : 1.1.0
*
* Date : 2009.12.08
*
* Description :
*
* Others : None at present.
*
*
* History :
*
* <Author> <time> <version> <description>
*
* Gary.Wang 2009.12.08 1.1.0 build the file
*
************************************************************************************************************************
*/
#include "common.h"
#include "spare_head.h"
#include "private_boot0.h"
#include "private_uboot.h"
#include <asm/arch/mmc_boot0.h>
extern __s32 check_magic( __u32 *mem_base, const char *magic );
extern __s32 check_sum( __u32 *mem_base, __u32 size );
extern const boot0_file_head_t BT0_head;
typedef struct _boot_sdcard_info_t
{
__s32 card_ctrl_num; //总共的卡的个数
__s32 boot_offset; //指定卡启动之后,逻辑和物理分区的管理
__s32 card_no[4]; //当前启动的卡号, 16-31:GPIO编号,0-15:实际卡控制器编号
__s32 speed_mode[4]; //卡的速度模式,0:低速,其它:高速
__s32 line_sel[4]; //卡的线制,0: 1线,其它,4线
__s32 line_count[4]; //卡使用线的个数
}
boot_sdcard_info_t;
extern const boot0_file_head_t BT0_head;
/*******************************************************************************
*函数名称: load_boot1_from_sdmmc
*函数原型:int32 load_boot1_from_sdmmc( __u8 card_no )
*函数功能: 将一份好的Boot1从sdmmc flash中载入到SRAM中。
*入口参数: void
*返 回 值: OK 载入并校验成功
* ERROR 载入并校验失败
*备 注:
*******************************************************************************/
__s32 load_boot1_from_sdmmc( char *buf)
{
__u32 length;
__s32 card_no, i, boot0_copy;
struct spare_boot_head_t *bfh = (struct spare_boot_head_t *) CONFIG_SYS_TEXT_BASE;;
boot_sdcard_info_t *sdcard_info = (boot_sdcard_info_t *)buf;
i = BT0_head.boot_head.platform[0] & 0xf;
boot0_copy = (BT0_head.boot_head.platform[0]>>4) & 0xf;
printf("card boot number = %d, boot0 copy = %d\n", i, boot0_copy);
//for(i=0;i<4;i++)
//{
/* open sdmmc */
card_no = i;
printf("card no is %d\n", card_no);
if(card_no < 0)
{
printf("bad card number %d in card boot\n", card_no);
goto __card_op_fail__;
}
printf("sdcard %d line count %d\n", card_no, sdcard_info->line_sel[i] );
if(!sdcard_info->line_sel[i])
{
sdcard_info->line_sel[i] = 4;
}
if( sunxi_mmc_init( card_no, sdcard_info->line_sel[i], BT0_head.prvt_head.storage_gpio, 16, (void *)(sdcard_info) ) == -1) //高速卡,4线配置
{
printf("Fail in Init sdmmc.\n");
goto __card_op_fail__;
}
printf("sdcard %d init ok\n", card_no);
#ifndef CONFIG_SUNXI_SECURE_SYSTEM
/* load 1k uboot head */
if( mmc_bread( card_no, UBOOT_START_SECTOR_IN_SDMMC, 1024/512, (void *)CONFIG_SYS_TEXT_BASE ) != (1024/512))
{
printf("Fail in reading uboot head.\n");
goto __card_op_fail__;
}
/* check head */
if( check_magic( (__u32 *)CONFIG_SYS_TEXT_BASE, UBOOT_MAGIC ) != 0 )
{
printf("ERROR! NOT find the head of uboot.\n");
goto __card_op_fail__;
}
/* check length */
length = bfh->boot_head.length;
printf("The size of uboot is %x.\n", length );
if( ( length & ( 8 * 1024 - 1 ) ) != 0 )
{
printf("boot0 length is NOT align.\n");
goto __card_op_fail__;
}
if( mmc_bread( card_no, UBOOT_START_SECTOR_IN_SDMMC, length/512, (void *)CONFIG_SYS_TEXT_BASE )!= (length/512))
{
printf("Fail in reading uboot head.\n");
goto __card_op_fail__;
}
/* 检查校验和 */
if( check_sum( (__u32 *)CONFIG_SYS_TEXT_BASE, length ) != 0 )
{
printf("Fail in checking uboot.\n");
goto __card_op_fail__;
}
#else
uint start_sector = UBOOT_START_SECTOR_IN_SDMMC - (UBOOT_START_SECTOR_PRE_IN_SDMMC - UBOOT_START_SECTOR_IN_SDMMC);
do
{
start_sector += UBOOT_START_SECTOR_PRE_IN_SDMMC - UBOOT_START_SECTOR_IN_SDMMC;
if(start_sector > UBOOT_START_SECTOR_PRE_IN_SDMMC)
{
printf("read all u-boot blk failed\n");
goto __card_op_fail__;
}
/* load 1k uboot head */
if( mmc_bread( card_no, start_sector, 1024/512, (void *)CONFIG_SYS_TEXT_BASE ) != (1024/512))
{
printf("Fail in reading uboot head.\n");
continue;
}
/* check head */
if( check_magic( (__u32 *)CONFIG_SYS_TEXT_BASE, UBOOT_MAGIC ) != 0 )
{
printf("ERROR! NOT find the head of uboot.\n");
continue;
}
/* check length */
length = bfh->boot_head.length;
printf("The size of uboot is %x.\n", length );
if( ( length & ( 8 * 1024 - 1 ) ) != 0 )
{
printf("boot0 length is NOT align.\n");
continue;
}
if( mmc_bread( card_no, start_sector, length/512, (void *)CONFIG_SYS_TEXT_BASE )!= (length/512))
{
printf("Fail in reading uboot head.\n");
continue;
}
/* 检查校验和 */
if( check_sum( (__u32 *)CONFIG_SYS_TEXT_BASE, length ) != 0 )
{
printf("Fail in checking uboot.\n");
continue;
}
break;
}
while(1);
#endif
if(i == 0)
{
bfh->boot_data.storage_type = 1;
}
else
{
bfh->boot_data.storage_type = 2;
set_mmc_para(2,(void *)&BT0_head.prvt_head.storage_data);
}
printf("Succeed in loading uboot from sdmmc flash.\n");
sunxi_mmc_exit( card_no, BT0_head.prvt_head.storage_gpio, 16 );
return 0;
__card_op_fail__:
sunxi_mmc_exit(card_no, BT0_head.prvt_head.storage_gpio, 16 );
return -1;
}
int load_boot1(void)
{
memcpy((void *)DRAM_PARA_STORE_ADDR, (void *)BT0_head.prvt_head.dram_para, SUNXI_DRAM_PARA_MAX * 4);
return load_boot1_from_sdmmc((char *)BT0_head.prvt_head.storage_data);
}
|
afdd3fde64a1a4c1dba9d2258871d3fdd8882740
|
7e41167bfae6d2c38689b7e0993b308e045cbd05
|
/file_cmds/gzip/unpack.c
|
dbad58825b9e92c6f8ceea48895c400788b65003
|
[
"BSD-3-Clause",
"curl",
"GPL-1.0-or-later",
"MIT",
"Python-2.0",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
holzschu/ios_system
|
7b18993dbcb33331c353e0257ca54847a5d1b1bb
|
6a83eb1c6c383a562fbe33a7e97677e88d305b51
|
refs/heads/master
| 2023-08-14T09:11:40.627903
| 2023-04-18T15:12:29
| 2023-04-18T15:12:29
| 113,187,304
| 882
| 155
|
BSD-3-Clause
| 2023-08-19T19:15:35
| 2017-12-05T13:42:50
|
C
|
UTF-8
|
C
| false
| false
| 10,464
|
c
|
unpack.c
|
/*-
* Copyright (c) 2009 Xin LI <delphij@FreeBSD.org>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. 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.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR 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 AUTHOR 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.
*
* $FreeBSD: src/usr.bin/gzip/unpack.c,v 1.3 2010/10/16 15:24:04 bcr Exp $
*/
/* This file is #included by gzip.c */
/*
* pack(1) file format:
*
* The first 7 bytes is the header:
* 00, 01 - Signature (US, RS), we already validated it earlier.
* 02..05 - Uncompressed size
* 06 - Level for the huffman tree (<=24)
*
* pack(1) will then store symbols (leaf) nodes count in each huffman
* tree levels, each level would consume 1 byte (See [1]).
*
* After the symbol count table, there is the symbol table, storing
* symbols represented by corresponding leaf node. EOB is not being
* explicitly transmitted (not necessary anyway) in the symbol table.
*
* Compressed data goes after the symbol table.
*
* NOTES
*
* [1] If we count EOB into the symbols, that would mean that we will
* have at most 256 symbols in the huffman tree. pack(1) rejects empty
* file and files that just repeats one character, which means that we
* will have at least 2 symbols. Therefore, pack(1) would reduce the
* last level symbol count by 2 which makes it a number in
* range [0..254], so all levels' symbol count would fit into 1 byte.
*/
#define PACK_HEADER_LENGTH 7
#define HTREE_MAXLEVEL 24
/*
* unpack descriptor
*
* Represent the huffman tree in a similar way that pack(1) would
* store in a packed file. We store all symbols in a linear table,
* and store pointers to each level's first symbol. In addition to
* that, maintain two counts for each level: inner nodes count and
* leaf nodes count.
*/
typedef struct {
int symbol_size; /* Size of the symbol table */
int treelevels; /* Levels for the huffman tree */
int *symbolsin; /* Table of leaf symbols count in
each level */
int *inodesin; /* Table of internal nodes count in
each level */
char *symbol; /* The symbol table */
char *symbol_eob; /* Pointer to the EOB symbol */
char **tree; /* Decoding huffman tree (pointers to
first symbol of each tree level */
off_t uncompressed_size; /* Uncompressed size */
FILE *fpIn; /* Input stream */
FILE *fpOut; /* Output stream */
} unpack_descriptor_t;
/*
* Release resource allocated to an unpack descriptor.
*
* Caller is responsible to make sure that all of these pointers are
* initialized (in our case, they all point to valid memory block).
* We don't zero out pointers here because nobody else would ever
* reference the memory block without scrubbing them.
*/
static void
unpack_descriptor_fini(unpack_descriptor_t *unpackd)
{
free(unpackd->symbolsin);
free(unpackd->inodesin);
free(unpackd->symbol);
free(unpackd->tree);
fclose(unpackd->fpIn);
fclose(unpackd->fpOut);
}
/*
* Recursively fill the internal node count table
*/
static void
unpackd_fill_inodesin(const unpack_descriptor_t *unpackd, int level)
{
/*
* The internal nodes would be 1/2 of total internal nodes and
* leaf nodes in the next level. For the last level there
* would be no internal node by definition.
*/
if (level < unpackd->treelevels) {
unpackd_fill_inodesin(unpackd, level + 1);
unpackd->inodesin[level] = (unpackd->inodesin[level + 1] +
unpackd->symbolsin[level + 1]) / 2;
} else
unpackd->inodesin[level] = 0;
}
/*
* Update counter for accepted bytes
*/
static void
accepted_bytes(off_t *bytes_in, off_t newbytes)
{
if (bytes_in != NULL)
(*bytes_in) += newbytes;
}
/*
* Read file header and construct the tree. Also, prepare the buffered I/O
* for decode routine.
*
* Return value is uncompressed size.
*/
static void
unpack_parse_header(int in, int out, char *pre, size_t prelen, off_t *bytes_in,
unpack_descriptor_t *unpackd)
{
unsigned char hdr[PACK_HEADER_LENGTH]; /* buffer for header */
ssize_t bytesread; /* Bytes read from the file */
int i, j, thisbyte;
/* Prepend the header buffer if we already read some data */
if (prelen != 0)
memcpy(hdr, pre, prelen);
/* Read in and fill the rest bytes of header */
bytesread = read(in, hdr + prelen, PACK_HEADER_LENGTH - prelen);
if (bytesread < 0)
maybe_err("Error reading pack header");
accepted_bytes(bytes_in, PACK_HEADER_LENGTH);
/* Obtain uncompressed length (bytes 2,3,4,5)*/
unpackd->uncompressed_size = 0;
for (i = 2; i <= 5; i++) {
unpackd->uncompressed_size <<= 8;
unpackd->uncompressed_size |= hdr[i];
}
/* Get the levels of the tree */
unpackd->treelevels = hdr[6];
if (unpackd->treelevels > HTREE_MAXLEVEL || unpackd->treelevels < 1)
maybe_errx("Huffman tree has insane levels");
/* Let libc take care for buffering from now on */
if ((unpackd->fpIn = fdopen(in, "r")) == NULL)
maybe_err("Can not fdopen() input stream");
if ((unpackd->fpOut = fdopen(out, "w")) == NULL)
maybe_err("Can not fdopen() output stream");
/* Allocate for the tables of bounds and the tree itself */
unpackd->inodesin =
calloc(unpackd->treelevels, sizeof(*(unpackd->inodesin)));
unpackd->symbolsin =
calloc(unpackd->treelevels, sizeof(*(unpackd->symbolsin)));
unpackd->tree =
calloc(unpackd->treelevels, (sizeof (*(unpackd->tree))));
if (unpackd->inodesin == NULL || unpackd->symbolsin == NULL ||
unpackd->tree == NULL)
maybe_err("calloc");
/* We count from 0 so adjust to match array upper bound */
unpackd->treelevels--;
/* Read the levels symbol count table and calculate total */
unpackd->symbol_size = 1; /* EOB */
for (i = 0; i <= unpackd->treelevels; i++) {
if ((thisbyte = fgetc(unpackd->fpIn)) == EOF)
maybe_err("File appears to be truncated");
unpackd->symbolsin[i] = (unsigned char)thisbyte;
unpackd->symbol_size += unpackd->symbolsin[i];
}
accepted_bytes(bytes_in, unpackd->treelevels);
if (unpackd->symbol_size > 256)
maybe_errx("Bad symbol table");
/* Allocate for the symbol table, point symbol_eob at the beginning */
unpackd->symbol_eob = unpackd->symbol = calloc(1, unpackd->symbol_size);
if (unpackd->symbol == NULL)
maybe_err("calloc");
/*
* Read in the symbol table, which contain [2, 256] symbols.
* In order to fit the count in one byte, pack(1) would offset
* it by reducing 2 from the actual number from the last level.
*
* We adjust the last level's symbol count by 1 here, because
* the EOB symbol is not being transmitted explicitly. Another
* adjustment would be done later afterward.
*/
unpackd->symbolsin[unpackd->treelevels]++;
for (i = 0; i <= unpackd->treelevels; i++) {
unpackd->tree[i] = unpackd->symbol_eob;
for (j = 0; j < unpackd->symbolsin[i]; j++) {
if ((thisbyte = fgetc(unpackd->fpIn)) == EOF)
maybe_errx("Symbol table truncated");
*unpackd->symbol_eob++ = (char)thisbyte;
}
accepted_bytes(bytes_in, unpackd->symbolsin[i]);
}
/* Now, take account for the EOB symbol as well */
unpackd->symbolsin[unpackd->treelevels]++;
/*
* The symbolsin table has been constructed now.
* Calculate the internal nodes count table based on it.
*/
unpackd_fill_inodesin(unpackd, 0);
}
/*
* Decode huffman stream, based on the huffman tree.
*/
static void
unpack_decode(const unpack_descriptor_t *unpackd, off_t *bytes_in)
{
int thislevel, thiscode, thisbyte, inlevelindex;
int i;
off_t bytes_out = 0;
const char *thissymbol; /* The symbol pointer decoded from stream */
/*
* Decode huffman. Fetch every bytes from the file, get it
* into 'thiscode' bit-by-bit, then output the symbol we got
* when one has been found.
*
* Assumption: sizeof(int) > ((max tree levels + 1) / 8).
* bad things could happen if not.
*/
thislevel = 0;
thiscode = thisbyte = 0;
while ((thisbyte = fgetc(unpackd->fpIn)) != EOF) {
accepted_bytes(bytes_in, 1);
/*
* Split one bit from thisbyte, from highest to lowest,
* feed the bit into thiscode, until we got a symbol from
* the tree.
*/
for (i = 7; i >= 0; i--) {
thiscode = (thiscode << 1) | ((thisbyte >> i) & 1);
/* Did we got a symbol? (referencing leaf node) */
if (thiscode >= unpackd->inodesin[thislevel]) {
inlevelindex =
thiscode - unpackd->inodesin[thislevel];
if (inlevelindex > unpackd->symbolsin[thislevel])
maybe_errx("File corrupt");
thissymbol =
&(unpackd->tree[thislevel][inlevelindex]);
if ((thissymbol == unpackd->symbol_eob) &&
(bytes_out == unpackd->uncompressed_size))
goto finished;
fputc((*thissymbol), unpackd->fpOut);
bytes_out++;
/* Prepare for next input */
thislevel = 0; thiscode = 0;
} else {
thislevel++;
if (thislevel > unpackd->treelevels)
maybe_errx("File corrupt");
}
}
}
finished:
if (bytes_out != unpackd->uncompressed_size)
maybe_errx("Premature EOF");
}
/* Handler for pack(1)'ed file */
static off_t
unpack(int in, int out, char *pre, size_t prelen, off_t *bytes_in)
{
unpack_descriptor_t unpackd;
in = dup(in);
if (in == -1)
maybe_err("dup");
out = dup(out);
if (out == -1)
maybe_err("dup");
unpack_parse_header(in, out, pre, prelen, bytes_in, &unpackd);
unpack_decode(&unpackd, bytes_in);
unpack_descriptor_fini(&unpackd);
/* If we reached here, the unpack was successful */
return (unpackd.uncompressed_size);
}
|
c03c71c381f2a6564c1336f0e6c1908c3f530fa5
|
50e95229b9a1161ac294137120aaba94c9eb06bc
|
/sources/ippcp/crypto_mb/include/crypto_mb/sm4.h
|
144fb6f56d7503b8a6bffcaf33aea58d3b408530
|
[
"Apache-2.0",
"Intel"
] |
permissive
|
intel/ipp-crypto
|
f0f05b87203705e82603db67bed5f8def13a5ee8
|
36e76e2388f3dd10cc440e213dfcf6ef59a0dfb8
|
refs/heads/develop
| 2023-09-04T08:15:06.851373
| 2023-07-27T12:47:12
| 2023-07-27T12:47:12
| 140,034,345
| 304
| 81
|
Apache-2.0
| 2023-08-30T17:18:36
| 2018-07-06T22:16:28
|
C
|
UTF-8
|
C
| false
| false
| 4,341
|
h
|
sm4.h
|
/*******************************************************************************
* Copyright (C) 2021 Intel Corporation
*
* 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.
*
*******************************************************************************/
#ifndef SM4_H
#define SM4_H
#include <crypto_mb/defs.h>
#include <crypto_mb/status.h>
#define SM4_LINES (16) /* Max number of buffers */
#define SM4_BLOCK_SIZE (16) /* SM4 data block size (bytes) */
#define SM4_KEY_SIZE (16) /* SM4 key size (bytes) */
#define SM4_ROUNDS (32) /* SM4 number of rounds */
#define SM4_XTS_MAX_SIZE ((1 << 20) * SM4_BLOCK_SIZE) /* SM4 max buffer size (bytes) */
typedef int8u sm4_key[SM4_KEY_SIZE];
typedef int8u sm4_xts_key[SM4_KEY_SIZE*2];
typedef int32u mbx_sm4_key_schedule[SM4_ROUNDS][SM4_LINES];
EXTERN_C mbx_status16 mbx_sm4_set_key_mb16(mbx_sm4_key_schedule* key_sched, const sm4_key* pa_key[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_xts_set_keys_mb16(mbx_sm4_key_schedule* key_sched1, mbx_sm4_key_schedule* key_sched2, const sm4_xts_key* pa_key[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_encrypt_ecb_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched);
EXTERN_C mbx_status16 mbx_sm4_decrypt_ecb_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched);
EXTERN_C mbx_status16 mbx_sm4_encrypt_cbc_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, const int8u* pa_iv[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_decrypt_cbc_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, const int8u* pa_iv[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_encrypt_ctr128_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, int8u* pa_ctr[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_decrypt_ctr128_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, int8u* pa_ctr[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_encrypt_ofb_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, int8u* pa_iv[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_decrypt_ofb_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, int8u* pa_iv[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_encrypt_cfb128_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, const int8u* pa_iv[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_decrypt_cfb128_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES], const mbx_sm4_key_schedule* key_sched, const int8u* pa_iv[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_xts_encrypt_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES],
const mbx_sm4_key_schedule* key_sched1, const mbx_sm4_key_schedule* key_sched2,
const int8u* pa_tweak[SM4_LINES]);
EXTERN_C mbx_status16 mbx_sm4_xts_decrypt_mb16(int8u* pa_out[SM4_LINES], const int8u* pa_inp[SM4_LINES], const int len[SM4_LINES],
const mbx_sm4_key_schedule* key_sched1, const mbx_sm4_key_schedule* key_sched2,
const int8u* pa_tweak[SM4_LINES]);
#endif /* SM4_H */
|
7648af3507d06bab981f329baf6e0790401ebbe2
|
5c72e3dec37038e313beab6250acaa54b4b03b93
|
/vioinput/sys/KeyMap.c
|
5f7752b73492aa52f1f7454b5d7aa60ded438fe1
|
[
"BSD-3-Clause",
"GPL-1.0-or-later"
] |
permissive
|
virtio-win/kvm-guest-drivers-windows
|
eb29c92b6949d6bfb0ee8c70004e359180ee2398
|
19a79901f36aa552b85f8b4c3c9645ebe90d9ec5
|
refs/heads/master
| 2023-09-06T00:50:32.529282
| 2023-08-25T10:21:53
| 2023-08-31T07:30:16
| 2,524,933
| 1,424
| 294
|
BSD-3-Clause
| 2023-08-26T16:02:39
| 2011-10-06T09:06:41
|
C
|
UTF-8
|
C
| false
| false
| 28,479
|
c
|
KeyMap.c
|
/*
* EV_KEY EVDEV code to HID usage code map
*
* Copyright (c) 2016-2017 Red Hat, Inc.
*
* Author(s):
* Ladi Prosek <lprosek@redhat.com>
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met :
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. 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.
* 3. Neither the names of the copyright holders nor the names of their 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 HOLDERS 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.
*/
#include "precomp.h"
#include "Hid.h"
static const ULONG ReportCodeToUsageCodeTable[] =
{
/* KEY_RESERVED */ 0x00,
/* KEY_ESC */ 0x29,
/* KEY_1 */ 0x1E,
/* KEY_2 */ 0x1F,
/* KEY_3 */ 0x20,
/* KEY_4 */ 0x21,
/* KEY_5 */ 0x22,
/* KEY_6 */ 0x23,
/* KEY_7 */ 0x24,
/* KEY_8 */ 0x25,
/* KEY_9 */ 0x26,
/* KEY_0 */ 0x27,
/* KEY_MINUS */ 0x2D,
/* KEY_EQUAL */ 0x2E,
/* KEY_BACKSPACE */ 0x2A,
/* KEY_TAB */ 0x2B,
/* KEY_Q */ 0x14,
/* KEY_W */ 0x1A,
/* KEY_E */ 0x08,
/* KEY_R */ 0x15,
/* KEY_T */ 0x17,
/* KEY_Y */ 0x1C,
/* KEY_U */ 0x18,
/* KEY_I */ 0x0C,
/* KEY_O */ 0x12,
/* KEY_P */ 0x13,
/* KEY_LEFTBRACE */ 0x2F,
/* KEY_RIGHTBRACE */ 0x30,
/* KEY_ENTER */ 0x28,
/* KEY_LEFTCTRL */ 0xE0,
/* KEY_A */ 0x04,
/* KEY_S */ 0x16,
/* KEY_D */ 0x07,
/* KEY_F */ 0x09,
/* KEY_G */ 0x0A,
/* KEY_H */ 0x0B,
/* KEY_J */ 0x0D,
/* KEY_K */ 0x0E,
/* KEY_L */ 0x0F,
/* KEY_SEMICOLON */ 0x33,
/* KEY_APOSTROPHE */ 0x34,
/* KEY_GRAVE */ 0x35,
/* KEY_LEFTSHIFT */ 0xE1,
/* KEY_BACKSLASH */ 0x32,
/* KEY_Z */ 0x1D,
/* KEY_X */ 0x1B,
/* KEY_C */ 0x06,
/* KEY_V */ 0x19,
/* KEY_B */ 0x05,
/* KEY_N */ 0x11,
/* KEY_M */ 0x10,
/* KEY_COMMA */ 0x36,
/* KEY_DOT */ 0x37,
/* KEY_SLASH */ 0x38,
/* KEY_RIGHTSHIFT */ 0xE5,
/* KEY_KPASTERISK */ 0x55,
/* KEY_LEFTALT */ 0xE2,
/* KEY_SPACE */ 0x2C,
/* KEY_CAPSLOCK */ 0x39,
/* KEY_F1 */ 0x3A,
/* KEY_F2 */ 0x3B,
/* KEY_F3 */ 0x3C,
/* KEY_F4 */ 0x3D,
/* KEY_F5 */ 0x3E,
/* KEY_F6 */ 0x3F,
/* KEY_F7 */ 0x40,
/* KEY_F8 */ 0x41,
/* KEY_F9 */ 0x42,
/* KEY_F10 */ 0x43,
/* KEY_NUMLOCK */ 0x53,
/* KEY_SCROLLLOCK */ 0x47,
/* KEY_KP7 */ 0x5F,
/* KEY_KP8 */ 0x60,
/* KEY_KP9 */ 0x61,
/* KEY_KPMINUS */ 0x56,
/* KEY_KP4 */ 0x5C,
/* KEY_KP5 */ 0x5D,
/* KEY_KP6 */ 0x5E,
/* KEY_KPPLUS */ 0x57,
/* KEY_KP1 */ 0x59,
/* KEY_KP2 */ 0x5A,
/* KEY_KP3 */ 0x5B,
/* KEY_KP0 */ 0x62,
/* KEY_KPDOT */ 0x63,
/* unused */ 0x00,
/* KEY_ZENKAKUHANKAKU */ 0x94,
/* KEY_102ND */ 0x64,
/* KEY_F11 */ 0x44,
/* KEY_F12 */ 0x45,
/* KEY_RO */ 0x87,
/* KEY_KATAKANA */ 0x92,
/* KEY_HIRAGANA */ 0x93,
/* KEY_HENKAN */ 0x8A,
/* KEY_KATAKANAHIRAGANA */ 0x88,
/* KEY_MUHENKAN */ 0x8B,
/* KEY_KPJPCOMMA */ 0x8C,
/* KEY_KPENTER */ 0x58,
/* KEY_RIGHTCTRL */ 0xE4,
/* KEY_KPSLASH */ 0x54,
/* KEY_SYSRQ */ 0x46,
/* KEY_RIGHTALT */ 0xE6,
/* KEY_LINEFEED */ 0x00,
/* KEY_HOME */ 0x4A,
/* KEY_UP */ 0x52,
/* KEY_PAGEUP */ 0x4B,
/* KEY_LEFT */ 0x50,
/* KEY_RIGHT */ 0x4F,
/* KEY_END */ 0x4D,
/* KEY_DOWN */ 0x51,
/* KEY_PAGEDOWN */ 0x4E,
/* KEY_INSERT */ 0x49,
/* KEY_DELETE */ 0x4C,
/* KEY_MACRO */ 0x00,
/* KEY_MUTE */ KEY_TYPE_CONSUMER | 0xE2,
/* KEY_VOLUMEDOWN */ KEY_TYPE_CONSUMER | 0xEA,
/* KEY_VOLUMEUP */ KEY_TYPE_CONSUMER | 0xE9,
/* KEY_POWER */ KEY_TYPE_CONSUMER | 0x30,
/* KEY_KPEQUAL */ 0x67,
/* KEY_KPPLUSMINUS */ 0x00,
/* KEY_PAUSE */ 0x48,
/* KEY_SCALE */ 0x00,
/* KEY_KPCOMMA */ 0x85,
/* KEY_HANGEUL */ 0x90,
/* KEY_HANJA */ 0x91,
/* KEY_YEN */ 0x89,
/* KEY_LEFTMETA */ 0xE3,
/* KEY_RIGHTMETA */ 0xE7,
/* KEY_COMPOSE */ 0x65,
/* KEY_STOP */ KEY_TYPE_CONSUMER | 0x226,
/* KEY_AGAIN */ 0x79,
/* KEY_PROPS */ 0x76,
/* KEY_UNDO */ 0x7A,
/* KEY_FRONT */ 0x77,
/* KEY_COPY */ 0x7C,
/* KEY_OPEN */ 0x74,
/* KEY_PASTE */ 0x7D,
/* KEY_FIND */ 0xF4,
/* KEY_CUT */ 0x7B,
/* KEY_HELP */ 0x75,
/* KEY_MENU */ 0x65,
/* KEY_CALC */ KEY_TYPE_CONSUMER | 0x192,
/* KEY_SETUP */ 0x00,
/* KEY_SLEEP */ KEY_TYPE_CONSUMER | 0x32,
/* KEY_WAKEUP */ 0x00,
/* KEY_FILE */ KEY_TYPE_CONSUMER | 0x194,
/* KEY_SENDFILE */ 0x00,
/* KEY_DELETEFILE */ 0x00,
/* KEY_XFER */ 0x00,
/* KEY_PROG1 */ 0x00,
/* KEY_PROG2 */ 0x00,
/* KEY_WWW */ KEY_TYPE_CONSUMER | 0x196,
/* KEY_MSDOS */ 0x00,
/* KEY_COFFEE */ KEY_TYPE_CONSUMER | 0x19E,
/* KEY_ROTATE_DISPLAY */ 0x00,
/* KEY_CYCLEWINDOWS */ 0x00,
/* KEY_MAIL */ KEY_TYPE_CONSUMER | 0x18A,
/* KEY_BOOKMARKS */ KEY_TYPE_CONSUMER | 0x182,
/* KEY_COMPUTER */ 0x00,
/* KEY_BACK */ KEY_TYPE_CONSUMER | 0x224,
/* KEY_FORWARD */ KEY_TYPE_CONSUMER | 0x225,
/* KEY_CLOSECD */ 0x00,
/* KEY_EJECTCD */ KEY_TYPE_CONSUMER | 0xB8,
/* KEY_EJECTCLOSECD */ 0x00,
/* KEY_NEXTSONG */ KEY_TYPE_CONSUMER | 0xB5,
/* KEY_PLAYPAUSE */ KEY_TYPE_CONSUMER | 0xCD,
/* KEY_PREVIOUSSONG */ KEY_TYPE_CONSUMER | 0xB6,
/* KEY_STOPCD */ KEY_TYPE_CONSUMER | 0xB7,
/* KEY_RECORD */ KEY_TYPE_CONSUMER | 0xB2,
/* KEY_REWIND */ KEY_TYPE_CONSUMER | 0xB4,
/* KEY_PHONE */ KEY_TYPE_CONSUMER | 0x8C,
/* KEY_ISO */ 0x00,
/* KEY_CONFIG */ KEY_TYPE_CONSUMER | 0x183,
/* KEY_HOMEPAGE */ KEY_TYPE_CONSUMER | 0x223,
/* KEY_REFRESH */ KEY_TYPE_CONSUMER | 0x227,
/* KEY_EXIT */ KEY_TYPE_CONSUMER | 0x94,
/* KEY_MOVE */ 0x00,
/* KEY_EDIT */ KEY_TYPE_CONSUMER | 0x23D,
/* KEY_SCROLLUP */ KEY_TYPE_CONSUMER | 0x233,
/* KEY_SCROLLDOWN */ KEY_TYPE_CONSUMER | 0x234,
/* KEY_KPLEFTPAREN */ 0xB6,
/* KEY_KPRIGHTPAREN */ 0xB7,
/* KEY_NEW */ KEY_TYPE_CONSUMER | 0x201,
/* KEY_REDO */ KEY_TYPE_CONSUMER | 0x279,
/* KEY_F13 */ 0x68,
/* KEY_F14 */ 0x69,
/* KEY_F15 */ 0x6A,
/* KEY_F16 */ 0x6B,
/* KEY_F17 */ 0x6C,
/* KEY_F18 */ 0x6D,
/* KEY_F19 */ 0x6E,
/* KEY_F20 */ 0x6F,
/* KEY_F21 */ 0x70,
/* KEY_F22 */ 0x71,
/* KEY_F23 */ 0x72,
/* KEY_F24 */ 0x73,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_PLAYCD */ 0x00,
/* KEY_PAUSECD */ 0x00,
/* KEY_PROG3 */ 0x00,
/* KEY_PROG4 */ 0x00,
/* KEY_DASHBOARD */ 0x00,
/* KEY_SUSPEND */ 0x00,
/* KEY_CLOSE */ KEY_TYPE_CONSUMER | 0x203,
/* KEY_PLAY */ KEY_TYPE_CONSUMER | 0xB0,
/* KEY_FASTFORWARD */ KEY_TYPE_CONSUMER | 0xB3,
/* KEY_BASSBOOST */ KEY_TYPE_CONSUMER | 0xE5,
/* KEY_PRINT */ KEY_TYPE_CONSUMER | 0x208,
/* KEY_HP */ 0x00,
/* KEY_CAMERA */ KEY_TYPE_CONSUMER | 0x65,
/* KEY_SOUND */ 0x00,
/* KEY_QUESTION */ 0x00,
/* KEY_EMAIL */ 0x00,
/* KEY_CHAT */ KEY_TYPE_CONSUMER | 0x199,
/* KEY_SEARCH */ KEY_TYPE_CONSUMER | 0x221,
/* KEY_CONNECT */ 0x00,
/* KEY_FINANCE */ KEY_TYPE_CONSUMER | 0x191,
/* KEY_SPORT */ 0x00,
/* KEY_SHOP */ 0x00,
/* KEY_ALTERASE */ 0x00,
/* KEY_CANCEL */ KEY_TYPE_CONSUMER | 0x25F,
/* KEY_BRIGHTNESSDOWN */ KEY_TYPE_CONSUMER | 0x70,
/* KEY_BRIGHTNESSUP */ KEY_TYPE_CONSUMER | 0x6F,
/* KEY_MEDIA */ 0x00,
/* KEY_SWITCHVIDEOMODE */ 0x00,
/* KEY_KBDILLUMTOGGLE */ KEY_TYPE_CONSUMER | 0x35,
/* KEY_KBDILLUMDOWN */ 0x00,
/* KEY_KBDILLUMUP */ 0x00,
/* KEY_SEND */ KEY_TYPE_CONSUMER | 0x28C,
/* KEY_REPLY */ KEY_TYPE_CONSUMER | 0x289,
/* KEY_FORWARDMAIL */ KEY_TYPE_CONSUMER | 0x28B,
/* KEY_SAVE */ KEY_TYPE_CONSUMER | 0x207,
/* KEY_DOCUMENTS */ KEY_TYPE_CONSUMER | 0x1A7,
/* KEY_BATTERY */ 0x00,
/* KEY_BLUETOOTH */ 0x00,
/* KEY_WLAN */ 0x00,
/* KEY_UWB */ 0x00,
/* KEY_UNKNOWN */ 0x00,
/* KEY_VIDEO_NEXT */ KEY_TYPE_CONSUMER | 0x82,
/* KEY_VIDEO_PREV */ 0x00,
/* KEY_BRIGHTNESS_CYCLE */ 0x00,
/* KEY_BRIGHTNESS_AUTO */ KEY_TYPE_CONSUMER | 0x75,
/* KEY_DISPLAY_OFF */ 0x00,
/* KEY_WWAN */ 0x00,
/* KEY_RFKILL */ 0x00,
/* KEY_MICMUTE */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_OK */ 0x00,
/* KEY_SELECT */ KEY_TYPE_CONSUMER | 0x41,
/* KEY_GOTO */ KEY_TYPE_CONSUMER | 0x222,
/* KEY_CLEAR */ 0x00,
/* KEY_POWER2 */ 0x00,
/* KEY_OPTION */ 0x00,
/* KEY_INFO */ KEY_TYPE_CONSUMER | 0x60,
/* KEY_TIME */ 0x00,
/* KEY_VENDOR */ 0x00,
/* KEY_ARCHIVE */ 0x00,
/* KEY_PROGRAM */ KEY_TYPE_CONSUMER | 0x8D,
/* KEY_CHANNEL */ 0x00,
/* KEY_FAVORITES */ 0x00,
/* KEY_EPG */ 0x00,
/* KEY_PVR */ KEY_TYPE_CONSUMER | 0x9A,
/* KEY_MHP */ 0x00,
/* KEY_LANGUAGE */ 0x00,
/* KEY_TITLE */ 0x00,
/* KEY_SUBTITLE */ KEY_TYPE_CONSUMER | 0x61,
/* KEY_ANGLE */ 0x00,
/* KEY_ZOOM */ KEY_TYPE_CONSUMER | 0x6D,
/* KEY_MODE */ 0x00,
/* KEY_KEYBOARD */ KEY_TYPE_CONSUMER | 0x1AE,
/* KEY_SCREEN */ 0x00,
/* KEY_PC */ KEY_TYPE_CONSUMER | 0x88,
/* KEY_TV */ KEY_TYPE_CONSUMER | 0x89,
/* KEY_TV2 */ KEY_TYPE_CONSUMER | 0x97,
/* KEY_VCR */ KEY_TYPE_CONSUMER | 0x92,
/* KEY_VCR2 */ KEY_TYPE_CONSUMER | 0xA0,
/* KEY_SAT */ KEY_TYPE_CONSUMER | 0x98,
/* KEY_SAT2 */ 0x00,
/* KEY_CD */ KEY_TYPE_CONSUMER | 0x91,
/* KEY_TAPE */ KEY_TYPE_CONSUMER | 0x96,
/* KEY_RADIO */ 0x00,
/* KEY_TUNER */ KEY_TYPE_CONSUMER | 0x93,
/* KEY_PLAYER */ KEY_TYPE_CONSUMER | 0x193,
/* KEY_TEXT */ 0x00,
/* KEY_DVD */ KEY_TYPE_CONSUMER | 0x8B,
/* KEY_AUX */ 0x00,
/* KEY_MP3 */ 0x00,
/* KEY_AUDIO */ KEY_TYPE_CONSUMER | 0x1B7,
/* KEY_VIDEO */ KEY_TYPE_CONSUMER | 0x1B8,
/* KEY_DIRECTORY */ 0x00,
/* KEY_LIST */ 0x00,
/* KEY_MEMO */ KEY_TYPE_CONSUMER | 0x90,
/* KEY_CALENDAR */ KEY_TYPE_CONSUMER | 0x18E,
/* KEY_RED */ KEY_TYPE_CONSUMER | 0x69,
/* KEY_GREEN */ KEY_TYPE_CONSUMER | 0x6A,
/* KEY_YELLOW */ KEY_TYPE_CONSUMER | 0x6C,
/* KEY_BLUE */ KEY_TYPE_CONSUMER | 0x6B,
/* KEY_CHANNELUP */ KEY_TYPE_CONSUMER | 0x9C,
/* KEY_CHANNELDOWN */ KEY_TYPE_CONSUMER | 0x9D,
/* KEY_FIRST */ 0x00,
/* KEY_LAST */ KEY_TYPE_CONSUMER | 0x83,
/* KEY_AB */ 0x00,
/* KEY_NEXT */ KEY_TYPE_CONSUMER | 0x1A3,
/* KEY_RESTART */ KEY_TYPE_CONSUMER | 0x31,
/* KEY_SLOW */ KEY_TYPE_CONSUMER | 0xF5,
/* KEY_SHUFFLE */ KEY_TYPE_CONSUMER | 0xB9,
/* KEY_BREAK */ 0x00,
/* KEY_PREVIOUS */ KEY_TYPE_CONSUMER | 0x1A4,
/* KEY_DIGITS */ 0x00,
/* KEY_TEEN */ 0x00,
/* KEY_TWEN */ 0x00,
/* KEY_VIDEOPHONE */ KEY_TYPE_CONSUMER | 0x8E,
/* KEY_GAMES */ KEY_TYPE_CONSUMER | 0x8F,
/* KEY_ZOOMIN */ KEY_TYPE_CONSUMER | 0x22D,
/* KEY_ZOOMOUT */ KEY_TYPE_CONSUMER | 0x22E,
/* KEY_ZOOMRESET */ KEY_TYPE_CONSUMER | 0x22F,
/* KEY_WORDPROCESSOR */ KEY_TYPE_CONSUMER | 0x184,
/* KEY_EDITOR */ KEY_TYPE_CONSUMER | 0x185,
/* KEY_SPREADSHEET */ KEY_TYPE_CONSUMER | 0x186,
/* KEY_GRAPHICSEDITOR */ KEY_TYPE_CONSUMER | 0x187,
/* KEY_PRESENTATION */ KEY_TYPE_CONSUMER | 0x188,
/* KEY_DATABASE */ KEY_TYPE_CONSUMER | 0x189,
/* KEY_NEWS */ KEY_TYPE_CONSUMER | 0x18B,
/* KEY_VOICEMAIL */ KEY_TYPE_CONSUMER | 0x18C,
/* KEY_ADDRESSBOOK */ KEY_TYPE_CONSUMER | 0x18D,
/* KEY_MESSENGER */ KEY_TYPE_CONSUMER | 0x1BC,
/* KEY_DISPLAYTOGGLE */ KEY_TYPE_CONSUMER | 0x72,
/* KEY_SPELLCHECK */ KEY_TYPE_CONSUMER | 0x1AB,
/* KEY_LOGOFF */ KEY_TYPE_CONSUMER | 0x19C,
/* KEY_DOLLAR */ 0x00,
/* KEY_EURO */ 0x00,
/* KEY_FRAMEBACK */ 0x00,
/* KEY_FRAMEFORWARD */ 0x00,
/* KEY_CONTEXT_MENU */ 0x00,
/* KEY_MEDIA_REPEAT */ KEY_TYPE_CONSUMER | 0xBC,
/* KEY_10CHANNELSUP */ 0x00,
/* KEY_10CHANNELSDOWN */ 0x00,
/* KEY_IMAGES */ KEY_TYPE_CONSUMER | 0x1B6,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_DEL_EOL */ 0x00,
/* KEY_DEL_EOS */ 0x00,
/* KEY_INS_LINE */ 0x00,
/* KEY_DEL_LINE */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_FN */ 0x00,
/* KEY_FN_ESC */ 0x00,
/* KEY_FN_F1 */ 0x00,
/* KEY_FN_F2 */ 0x00,
/* KEY_FN_F3 */ 0x00,
/* KEY_FN_F4 */ 0x00,
/* KEY_FN_F5 */ 0x00,
/* KEY_FN_F6 */ 0x00,
/* KEY_FN_F7 */ 0x00,
/* KEY_FN_F8 */ 0x00,
/* KEY_FN_F9 */ 0x00,
/* KEY_FN_F10 */ 0x00,
/* KEY_FN_F11 */ 0x00,
/* KEY_FN_F12 */ 0x00,
/* KEY_FN_1 */ 0x00,
/* KEY_FN_2 */ 0x00,
/* KEY_FN_D */ 0x00,
/* KEY_FN_E */ 0x00,
/* KEY_FN_F */ 0x00,
/* KEY_FN_S */ 0x00,
/* KEY_FN_B */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_BRL_DOT1 */ 0x00,
/* KEY_BRL_DOT2 */ 0x00,
/* KEY_BRL_DOT3 */ 0x00,
/* KEY_BRL_DOT4 */ 0x00,
/* KEY_BRL_DOT5 */ 0x00,
/* KEY_BRL_DOT6 */ 0x00,
/* KEY_BRL_DOT7 */ 0x00,
/* KEY_BRL_DOT8 */ 0x00,
/* KEY_BRL_DOT9 */ 0x00,
/* KEY_BRL_DOT10 */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_NUMERIC_0 */ 0x00,
/* KEY_NUMERIC_1 */ 0x00,
/* KEY_NUMERIC_2 */ 0x00,
/* KEY_NUMERIC_3 */ 0x00,
/* KEY_NUMERIC_4 */ 0x00,
/* KEY_NUMERIC_5 */ 0x00,
/* KEY_NUMERIC_6 */ 0x00,
/* KEY_NUMERIC_7 */ 0x00,
/* KEY_NUMERIC_8 */ 0x00,
/* KEY_NUMERIC_9 */ 0x00,
/* KEY_NUMERIC_STAR */ 0x00,
/* KEY_NUMERIC_POUND */ 0x00,
/* KEY_NUMERIC_A */ 0x00,
/* KEY_NUMERIC_B */ 0x00,
/* KEY_NUMERIC_C */ 0x00,
/* KEY_NUMERIC_D */ 0x00,
/* KEY_CAMERA_FOCUS */ 0x00,
/* KEY_WPS_BUTTON */ 0x00,
/* KEY_TOUCHPAD_TOGGLE */ 0x00,
/* KEY_TOUCHPAD_ON */ 0x00,
/* KEY_TOUCHPAD_OFF */ 0x00,
/* KEY_CAMERA_ZOOMIN */ 0x00,
/* KEY_CAMERA_ZOOMOUT */ 0x00,
/* KEY_CAMERA_UP */ 0x00,
/* KEY_CAMERA_DOWN */ 0x00,
/* KEY_CAMERA_LEFT */ 0x00,
/* KEY_CAMERA_RIGHT */ 0x00,
/* KEY_ATTENDANT_ON */ 0x00,
/* KEY_ATTENDANT_OFF */ 0x00,
/* KEY_ATTENDANT_TOGGLE */ 0x00,
/* KEY_LIGHTS_TOGGLE */ 0x00,
/* unused */ 0x00,
/* BTN_DPAD_UP */ 0x00,
/* BTN_DPAD_DOWN */ 0x00,
/* BTN_DPAD_LEFT */ 0x00,
/* BTN_DPAD_RIGHT */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_ALS_TOGGLE */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_BUTTONCONFIG */ KEY_TYPE_CONSUMER | 0x181,
/* KEY_TASKMANAGER */ KEY_TYPE_CONSUMER | 0x18F,
/* KEY_JOURNAL */ KEY_TYPE_CONSUMER | 0x190,
/* KEY_CONTROLPANEL */ KEY_TYPE_CONSUMER | 0x19F,
/* KEY_APPSELECT */ KEY_TYPE_CONSUMER | 0x1A2,
/* KEY_SCREENSAVER */ KEY_TYPE_CONSUMER | 0x1B1,
/* KEY_VOICECOMMAND */ KEY_TYPE_CONSUMER | 0xCF,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_BRIGHTNESS_MIN */ KEY_TYPE_CONSUMER | 0x73,
/* KEY_BRIGHTNESS_MAX */ KEY_TYPE_CONSUMER | 0x74,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* unused */ 0x00,
/* KEY_KBDINPUTASSIST_PREV */ KEY_TYPE_CONSUMER | 0x2C7,
/* KEY_KBDINPUTASSIST_NEXT */ KEY_TYPE_CONSUMER | 0x2C8,
/* KEY_KBDINPUTASSIST_PREVGROUP */ KEY_TYPE_CONSUMER | 0x2C9,
/* KEY_KBDINPUTASSIST_NEXTGROUP */ KEY_TYPE_CONSUMER | 0x2CA,
/* KEY_KBDINPUTASSIST_ACCEPT */ KEY_TYPE_CONSUMER | 0x2CB,
/* KEY_KBDINPUTASSIST_CANCEL */ KEY_TYPE_CONSUMER | 0x2CC,
};
ULONG
HIDKeyboardEventCodeToUsageCode(
USHORT uEventCode)
{
if (uEventCode < (sizeof(ReportCodeToUsageCodeTable) / sizeof(ReportCodeToUsageCodeTable[0])))
{
return ReportCodeToUsageCodeTable[uEventCode];
}
return 0;
}
|
b28b792c6138b98e4efc725cfe170c9c8987994a
|
c21ad867752435377c599fb34df6d9074e2f014d
|
/sql-odbc/src/odfesqlodbc/statement.h
|
96e34ad6631e15af6ba0631259bdabe429024077
|
[
"LGPL-2.0-only",
"Apache-2.0"
] |
permissive
|
opendistro-for-elasticsearch/sql
|
e7f5c3a4bd232237b837aa7b9c5704c33c80547b
|
a549025e42e71fb3146f0ba2a1705cbd3fa2db9c
|
refs/heads/develop
| 2023-09-03T03:47:50.986152
| 2022-07-14T20:06:32
| 2022-07-14T20:06:32
| 162,486,600
| 639
| 215
|
Apache-2.0
| 2022-07-19T21:52:44
| 2018-12-19T20:20:57
|
Java
|
UTF-8
|
C
| false
| false
| 19,435
|
h
|
statement.h
|
#ifndef __STATEMENT_H__
#define __STATEMENT_H__
#include <time.h>
#include "bind.h"
#include "descriptor.h"
#include "es_helper.h"
#include "es_odbc.h"
#include "es_types.h"
#include "tuple.h"
// C Interface
#ifdef __cplusplus
extern "C" {
#endif
enum {
CancelRequestSet = 1L,
CancelRequestAccepted = (1L << 1),
CancelCompleted = (1L << 2)
};
typedef enum {
STMT_ALLOCATED, /* The statement handle is allocated, but
* not used so far */
STMT_READY, /* the statement is waiting to be executed */
STMT_DESCRIBED, /* ODBC states that it is legal to call
* e.g. SQLDescribeCol before a call to
* SQLExecute, but after SQLPrepare. To
* get all the necessary information in
* such a case, we parse the query _before_
* the actual call to SQLExecute, and the
* result set contains only column information,
* but no actual data. */
STMT_FINISHED, /* statement execution has finished */
STMT_EXECUTING /* statement execution is still going on */
} STMT_Status;
/*
* ERROR status code
*
* The code for warnings must be minus
* and LOWEST_STMT_ERROR must be set to
* the least code number.
* The code for STMT_OK is 0 and error
* codes follow after it.
*/
enum {
LOWEST_STMT_ERROR = (-6)
/* minus values mean warning returns */
,
STMT_ERROR_IN_ROW = (-6),
STMT_OPTION_VALUE_CHANGED = (-5),
STMT_ROW_VERSION_CHANGED = (-4),
STMT_POS_BEFORE_RECORDSET = (-3),
STMT_TRUNCATED = (-2),
STMT_INFO_ONLY = (-1)
/* not an error message,
* just a notification
* to be returned by
* SQLError
*/
,
STMT_OK = 0,
STMT_EXEC_ERROR,
STMT_STATUS_ERROR,
STMT_SEQUENCE_ERROR,
STMT_NO_MEMORY_ERROR,
STMT_COLNUM_ERROR,
STMT_NO_STMTSTRING,
STMT_ERROR_TAKEN_FROM_BACKEND,
STMT_INTERNAL_ERROR,
STMT_STILL_EXECUTING,
STMT_NOT_IMPLEMENTED_ERROR,
STMT_BAD_PARAMETER_NUMBER_ERROR,
STMT_OPTION_OUT_OF_RANGE_ERROR,
STMT_INVALID_COLUMN_NUMBER_ERROR,
STMT_RESTRICTED_DATA_TYPE_ERROR,
STMT_INVALID_CURSOR_STATE_ERROR,
STMT_CREATE_TABLE_ERROR,
STMT_QUERY_SYNTAX_ERROR,
STMT_NO_CURSOR_NAME,
STMT_INVALID_CURSOR_NAME,
STMT_INVALID_ARGUMENT_NO,
STMT_ROW_OUT_OF_RANGE,
STMT_OPERATION_CANCELLED,
STMT_INVALID_CURSOR_POSITION,
STMT_VALUE_OUT_OF_RANGE,
STMT_OPERATION_INVALID,
STMT_PROGRAM_TYPE_OUT_OF_RANGE,
STMT_BAD_ERROR,
STMT_INVALID_OPTION_IDENTIFIER,
STMT_RETURN_NULL_WITHOUT_INDICATOR,
STMT_INVALID_DESCRIPTOR_IDENTIFIER,
STMT_OPTION_NOT_FOR_THE_DRIVER,
STMT_FETCH_OUT_OF_RANGE,
STMT_COUNT_FIELD_INCORRECT,
STMT_INVALID_NULL_ARG,
STMT_NO_RESPONSE,
STMT_COMMUNICATION_ERROR,
STMT_STRING_CONVERSION_ERROR
};
/* statement types */
enum {
STMT_TYPE_UNKNOWN = -2,
STMT_TYPE_OTHER = -1,
STMT_TYPE_SELECT = 0,
STMT_TYPE_WITH,
STMT_TYPE_PROCCALL,
STMT_TYPE_TRANSACTION,
STMT_TYPE_DECLARE,
STMT_TYPE_FETCH,
STMT_TYPE_CLOSE,
STMT_TYPE_INSERT,
STMT_TYPE_UPDATE,
STMT_TYPE_DELETE,
STMT_TYPE_CREATE,
STMT_TYPE_ALTER,
STMT_TYPE_DROP,
STMT_TYPE_GRANT,
STMT_TYPE_REVOKE,
STMT_TYPE_LOCK,
STMT_TYPE_PREPARE,
STMT_TYPE_EXECUTE,
STMT_TYPE_DEALLOCATE,
STMT_TYPE_ANALYZE,
STMT_TYPE_NOTIFY,
STMT_TYPE_EXPLAIN,
STMT_TYPE_SET,
STMT_TYPE_RESET,
STMT_TYPE_MOVE,
STMT_TYPE_COPY,
STMT_TYPE_START,
STMT_TYPE_SPECIAL
};
#define STMT_UPDATE(stmt) ((stmt)->statement_type > STMT_TYPE_PROCCALL)
/* Parsing status */
enum {
STMT_PARSE_NONE = 0,
STMT_PARSE_COMPLETE /* the driver parsed the statement */
,
STMT_PARSE_INCOMPLETE,
STMT_PARSE_FATAL,
STMT_PARSE_MASK = 3L,
STMT_PARSED_OIDS = (1L << 2),
STMT_FOUND_KEY = (1L << 3),
STMT_HAS_ROW_DESCRIPTION = (1L << 4) /* already got the col info */
,
STMT_REFLECTED_ROW_DESCRIPTION = (1L << 5)
};
/* transition status */
enum {
STMT_TRANSITION_UNALLOCATED = 0,
STMT_TRANSITION_ALLOCATED = 1,
STMT_TRANSITION_FETCH_SCROLL = 6,
STMT_TRANSITION_EXTENDED_FETCH = 7
};
/* Result style */
enum { STMT_FETCH_NONE = 0, STMT_FETCH_NORMAL, STMT_FETCH_EXTENDED };
#define ES_NUM_NORMAL_KEYS 2
typedef RETCODE (*NeedDataCallfunc)(RETCODE, void *);
typedef struct {
NeedDataCallfunc func;
void *data;
} NeedDataCallback;
/*
* ProcessedStmt represents a fragment of the original SQL query, after
* converting ? markers to $n style, processing ODBC escapes, and splitting
* a multi-statement into individual statements. Each individual statement
* is represented by one ProcessedStmt struct.
*/
struct ProcessedStmt {
struct ProcessedStmt *next;
char *query;
int num_params; /* number of parameter markers in this,
* fragment or -1 if not known */
};
typedef struct ProcessedStmt ProcessedStmt;
/******** Statement Handle ***********/
struct StatementClass_ {
ConnectionClass *hdbc; /* pointer to ConnectionClass this
* statement belongs to */
QResultClass *result; /* result of the current statement */
QResultClass *curres; /* the current result in the chain */
HSTMT *phstmt;
StatementOptions options;
StatementOptions options_orig;
/* attached descriptor handles */
DescriptorClass *ard;
DescriptorClass *apd;
DescriptorClass *ird;
DescriptorClass *ipd;
/* implicit descriptor handles */
DescriptorClass ardi;
DescriptorClass irdi;
DescriptorClass apdi;
DescriptorClass ipdi;
STMT_Status status;
char *__error_message;
int __error_number;
ES_ErrorInfo *eserror;
SQLLEN currTuple; /* current absolute row number (GetData,
* SetPos, SQLFetch) */
GetDataInfo gdata_info;
SQLLEN save_rowset_size; /* saved rowset size in case of
* change/FETCH_NEXT */
SQLLEN rowset_start; /* start of rowset (an absolute row
* number) */
SQLSETPOSIROW bind_row; /* current offset for Multiple row/column
* binding */
Int2 current_col; /* current column for GetData -- used to
* handle multiple calls */
SQLLEN last_fetch_count; /* number of rows retrieved in
* last fetch/extended fetch */
int lobj_fd; /* fd of the current large object */
char *statement; /* if non--null pointer to the SQL
* statement that has been executed */
/*
* processed_statements is the SQL after splitting multi-statement into
* parts, and replacing ? markers with $n style markers, or injecting the
* values in UseServerSidePrepare=0 mode.
*/
ProcessedStmt *processed_statements;
TABLE_INFO **ti;
Int2 ntab;
Int2 num_key_fields;
Int2 statement_type; /* According to the defines above */
Int2 num_params;
Int2 data_at_exec; /* Number of params needing SQLPutData */
UDWORD iflag; /* ESAPI_AllocStmt parameter */
PutDataInfo pdata_info;
po_ind_t parse_status;
po_ind_t proc_return;
po_ind_t put_data; /* Has SQLPutData been called ? */
po_ind_t catalog_result; /* Is this a result of catalog function ? */
po_ind_t prepare; /* is this a prepared statement ? */
po_ind_t prepared; /* is this statement already
* prepared at the server ? */
po_ind_t external; /* Allocated via SQLAllocHandle() */
po_ind_t transition_status; /* Transition status */
po_ind_t multi_statement; /* -1:unknown 0:single 1:multi */
po_ind_t rb_or_tc; /* rollback on error */
po_ind_t
discard_output_params; /* discard output parameters on parse stage */
po_ind_t cancel_info; /* cancel information */
po_ind_t ref_CC_error; /* refer to CC_error ? */
po_ind_t lock_CC_for_rb; /* lock CC for statement rollback ? */
po_ind_t join_info; /* have joins ? */
po_ind_t parse_method; /* parse_statement is forced or ? */
esNAME cursor_name;
char *plan_name;
unsigned char miscinfo;
unsigned char execinfo;
po_ind_t updatable;
SQLLEN diag_row_count;
char *load_statement; /* to (re)load updatable individual rows */
ssize_t from_pos;
ssize_t load_from_pos;
ssize_t where_pos;
SQLLEN last_fetch_count_include_ommitted;
time_t stmt_time;
struct tm localtime;
/* SQL_NEED_DATA Callback list */
StatementClass *execute_delegate;
StatementClass *execute_parent;
UInt2 allocated_callbacks;
UInt2 num_callbacks;
NeedDataCallback *callbacks;
void *cs;
};
#define SC_get_conn(a) ((a)->hdbc)
void SC_init_Result(StatementClass *self);
void SC_set_Result(StatementClass *self, QResultClass *res);
#define SC_get_Result(a) ((a)->result)
#define SC_set_Curres(a, b) ((a)->curres = b)
#define SC_get_Curres(a) ((a)->curres)
#define SC_get_ARD(a) ((a)->ard)
#define SC_get_APD(a) ((a)->apd)
#define SC_get_IRD(a) ((a)->ird)
#define SC_get_IPD(a) ((a)->ipd)
#define SC_get_ARDF(a) (&(SC_get_ARD(a)->ardf))
#define SC_get_APDF(a) (&(SC_get_APD(a)->apdf))
#define SC_get_IRDF(a) (&(SC_get_IRD(a)->irdf))
#define SC_get_IPDF(a) (&(SC_get_IPD(a)->ipdf))
#define SC_get_ARDi(a) (&((a)->ardi))
#define SC_get_APDi(a) (&((a)->apdi))
#define SC_get_IRDi(a) (&((a)->irdi))
#define SC_get_IPDi(a) (&((a)->ipdi))
#define SC_get_GDTI(a) (&((a)->gdata_info))
#define SC_get_PDTI(a) (&((a)->pdata_info))
#define SC_get_errornumber(a) ((a)->__error_number)
#define SC_set_errornumber(a, n) ((a)->__error_number = n)
#define SC_get_errormsg(a) ((a)->__error_message)
#define SC_is_prepare_statement(a) (0 != ((a)->prepare & PREPARE_STATEMENT))
#define SC_get_prepare_method(a) ((a)->prepare & (~PREPARE_STATEMENT))
#define SC_parsed_status(a) ((a)->parse_status & STMT_PARSE_MASK)
#define SC_set_parse_status(a, s) ((a)->parse_status |= s)
#define SC_update_not_ready(a) \
(SC_parsed_status(a) == STMT_PARSE_NONE \
|| 0 == ((a)->parse_status & STMT_PARSED_OIDS))
#define SC_update_ready(a) \
(SC_parsed_status(a) == STMT_PARSE_COMPLETE \
&& 0 != ((a)->parse_status & STMT_FOUND_KEY) && (a)->updatable)
#define SC_set_checked_hasoids(a, b) \
((a)->parse_status |= (STMT_PARSED_OIDS | (b ? STMT_FOUND_KEY : 0)))
#define SC_checked_hasoids(a) (0 != ((a)->parse_status & STMT_PARSED_OIDS))
#define SC_set_delegate(p, c) \
((p)->execute_delegate = c, (c)->execute_parent = p)
#define SC_is_updatable(s) (0 < ((s)->updatable))
#define SC_reset_updatable(s) ((s)->updatable = -1)
#define SC_set_updatable(s, b) ((s)->updatable = (b))
#define SC_clear_parse_method(s) ((s)->parse_method = 0)
#define SC_is_parse_forced(s) (0 != ((s)->parse_method & 1L))
#define SC_set_parse_forced(s) ((s)->parse_method |= 1L)
#define SC_cursor_is_valid(s) (NAME_IS_VALID((s)->cursor_name))
#define SC_cursor_name(s) (SAFE_NAME((s)->cursor_name))
void SC_reset_delegate(RETCODE, StatementClass *);
#define SC_is_lower_case(a, b) \
((a)->options.metadata_id || (b)->connInfo.lower_case_identifier)
#define SC_MALLOC_return_with_error(t, tp, s, a, m, r) \
do { \
if (t = (tp *)malloc(s), NULL == t) { \
SC_set_error(a, STMT_NO_MEMORY_ERROR, m, "SC_MALLOC"); \
return r; \
} \
} while (0)
#define SC_MALLOC_gexit_with_error(t, tp, s, a, m, r) \
do { \
if (t = (tp *)malloc(s), NULL == t) { \
SC_set_error(a, STMT_NO_MEMORY_ERROR, m, "SC_MALLOC"); \
r; \
goto cleanup; \
} \
} while (0)
#define SC_REALLOC_return_with_error(t, tp, s, a, m, r) \
do { \
tp *tmp; \
if (tmp = (tp *)realloc(t, s), NULL == tmp) { \
SC_set_error(a, STMT_NO_MEMORY_ERROR, m, "SC_REALLOC"); \
return r; \
} \
t = tmp; \
} while (0)
#define SC_REALLOC_gexit_with_error(t, tp, s, a, m, r) \
do { \
tp *tmp; \
if (tmp = (tp *)realloc(t, s), NULL == tmp) { \
SC_set_error(a, STMT_NO_MEMORY_ERROR, m, __FUNCTION__); \
r; \
goto cleanup; \
} \
t = tmp; \
} while (0)
/* options for SC_free_params() */
#define STMT_FREE_PARAMS_ALL 0
#define STMT_FREE_PARAMS_DATA_AT_EXEC_ONLY 1
/* prepare state */
enum {
NON_PREPARE_STATEMENT = 0,
PREPARE_STATEMENT = 1,
PREPARE_BY_THE_DRIVER = (1L << 1),
NAMED_PARSE_REQUEST = (3L << 1),
PARSE_TO_EXEC_ONCE = (4L << 1),
PARSE_REQ_FOR_INFO = (5L << 1)
};
/* prepared state */
enum { NOT_PREPARED = 0, PREPARED, EXECUTED };
/* misc info */
#define SC_set_fetchcursor(a) ((a)->miscinfo |= (1L << 1))
#define SC_no_fetchcursor(a) ((a)->miscinfo &= ~(1L << 1))
#define SC_is_fetchcursor(a) (((a)->miscinfo & (1L << 1)) != 0)
#define SC_miscinfo_clear(a) ((a)->miscinfo = 0)
#define SC_set_with_hold(a) ((a)->execinfo |= 1L)
#define SC_set_without_hold(a) ((a)->execinfo &= (~1L))
#define SC_is_with_hold(a) (((a)->execinfo & 1L) != 0)
#define SC_set_readonly(a) ((a)->execinfo |= (1L << 1))
#define SC_set_no_readonly(a) ((a)->execinfo &= ~(1L << 1))
#define SC_is_readonly(a) (((a)->execinfo & (1L << 1)) != 0)
#define SC_execinfo_clear(a) (((a)->execinfo = 0)
#define STMT_HAS_OUTER_JOIN 1L
#define STMT_HAS_INNER_JOIN (1L << 1)
#define SC_has_join(a) (0 != (a)->join_info)
#define SC_has_outer_join(a) (0 != (STMT_HAS_OUTER_JOIN & (a)->join_info))
#define SC_has_inner_join(a) (0 != (STMT_HAS_INNER_JOIN & (a)->join_info))
#define SC_set_outer_join(a) ((a)->join_info |= STMT_HAS_OUTER_JOIN)
#define SC_set_inner_join(a) ((a)->join_info |= STMT_HAS_INNER_JOIN)
#define SC_start_tc_stmt(a) ((a)->rb_or_tc = (1L << 1))
#define SC_is_tc_stmt(a) (((a)->rb_or_tc & (1L << 1)) != 0)
#define SC_start_rb_stmt(a) ((a)->rb_or_tc = (1L << 2))
#define SC_is_rb_stmt(a) (((a)->rb_or_tc & (1L << 2)) != 0)
#define SC_unref_CC_error(a) (((a)->ref_CC_error) = FALSE)
#define SC_ref_CC_error(a) (((a)->ref_CC_error) = TRUE)
#define SC_can_parse_statement(a) (STMT_TYPE_SELECT == (a)->statement_type)
/*
* DECLARE CURSOR + FETCH can only be used with SELECT-type queries. And
* it's not currently supported with array-bound parameters.
*/
#define SC_may_use_cursor(a) \
(SC_get_APDF(a)->paramset_size <= 1 \
&& (STMT_TYPE_SELECT == (a)->statement_type \
|| STMT_TYPE_WITH == (a)->statement_type))
#define SC_may_fetch_rows(a) \
(STMT_TYPE_SELECT == (a)->statement_type \
|| STMT_TYPE_WITH == (a)->statement_type)
/* For Multi-thread */
#define INIT_STMT_CS(x) XPlatformInitializeCriticalSection(&((x)->cs))
#define ENTER_STMT_CS(x) XPlatformEnterCriticalSection(((x)->cs))
#define TRY_ENTER_STMT_CS(x) XPlatformTryEnterCriticalSection(&((x)->cs))
#define LEAVE_STMT_CS(x) XPlatformLeaveCriticalSection(((x)->cs))
#define DELETE_STMT_CS(x) XPlatformDeleteCriticalSection(&((x)->cs))
/* Statement prototypes */
StatementClass *SC_Constructor(ConnectionClass *);
void InitializeStatementOptions(StatementOptions *opt);
char SC_Destructor(StatementClass *self);
BOOL SC_opencheck(StatementClass *self, const char *func);
RETCODE SC_initialize_and_recycle(StatementClass *self);
void SC_initialize_cols_info(StatementClass *self, BOOL DCdestroy,
BOOL parseReset);
void SC_reset_result_for_rerun(StatementClass *self);
int statement_type(const char *statement);
char SC_unbind_cols(StatementClass *self);
char SC_recycle_statement(StatementClass *self);
void SC_clear_error(StatementClass *self);
void SC_set_error(StatementClass *self, int errnum, const char *msg,
const char *func);
void SC_set_errormsg(StatementClass *self, const char *msg);
void SC_error_copy(StatementClass *self, const StatementClass *from, BOOL);
void SC_full_error_copy(StatementClass *self, const StatementClass *from, BOOL);
void SC_set_prepared(StatementClass *self, int);
void SC_set_planname(StatementClass *self, const char *plan_name);
void SC_set_rowset_start(StatementClass *self, SQLLEN, BOOL);
void SC_inc_rowset_start(StatementClass *self, SQLLEN);
RETCODE SC_initialize_stmts(StatementClass *self, BOOL);
RETCODE SC_fetch(StatementClass *self);
void SC_log_error(const char *func, const char *desc,
const StatementClass *self);
time_t SC_get_time(StatementClass *self);
struct tm *SC_get_localtime(StatementClass *self);
int SC_Create_bookmark(StatementClass *stmt, BindInfoClass *bookmark,
Int4 row_pos, Int4 currTuple, const KeySet *keyset);
int SC_set_current_col(StatementClass *self, int col);
BOOL SC_SetExecuting(StatementClass *self, BOOL on);
BOOL SC_SetCancelRequest(StatementClass *self);
BOOL SC_connection_lost_check(StatementClass *stmt, const char *funcname);
void SC_set_errorinfo(StatementClass *self, QResultClass *res, int errkind);
RETCODE dequeueNeedDataCallback(RETCODE, StatementClass *self);
void cancelNeedDataState(StatementClass *self);
/*
* Macros to convert global index <-> relative index in resultset/rowset
*/
/* a global index to the relative index in a rowset */
#define SC_get_rowset_start(stmt) ((stmt)->rowset_start)
#define GIdx2RowIdx(gidx, stmt) (gidx - (stmt)->rowset_start)
/* a global index to the relative index in a resultset(not a rowset) */
#define GIdx2CacheIdx(gidx, s, r) \
(gidx - (QR_has_valid_base(r) ? ((s)->rowset_start - (r)->base) : 0))
#define GIdx2KResIdx(gidx, s, r) \
(gidx - (QR_has_valid_base(r) ? ((s)->rowset_start - (r)->key_base) : 0))
/* a relative index in a rowset to the global index */
#define RowIdx2GIdx(ridx, stmt) (ridx + (stmt)->rowset_start)
/* a relative index in a resultset to the global index */
#define CacheIdx2GIdx(ridx, stmt, res) \
(ridx - (res)->base + (stmt)->rowset_start)
#define KResIdx2GIdx(ridx, stmt, res) \
(ridx - (res)->key_base + (stmt)->rowset_start)
#define BOOKMARK_SHIFT 1
#define SC_make_int4_bookmark(b) ((b < 0) ? (b) : (b + BOOKMARK_SHIFT))
#define SC_resolve_int4_bookmark(b) ((b < 0) ? (b) : (b - BOOKMARK_SHIFT))
#ifdef __cplusplus
}
#endif
#endif /* __STATEMENT_H__ */
|
80bbd81205908bec087adfb4335d758bb3cf6509
|
f84321cbc44eadc437dddeb4e3529ddcc1c5bcae
|
/mpi/bugs/land_integer.c
|
c29e4cb584a278c7499ef9c8ed6ceab2c3a16d0f
|
[
"MIT"
] |
permissive
|
jeffhammond/HPCInfo
|
7d08fda4ab3a6301f6c7853bd72c7fbe06639f9f
|
8aff33b946cbd978b951f22c1b5a9140587be95e
|
refs/heads/master
| 2023-08-17T01:45:51.607023
| 2023-08-11T05:28:50
| 2023-08-11T05:28:50
| 12,674,497
| 261
| 60
|
MIT
| 2023-04-19T14:47:20
| 2013-09-08T01:45:33
|
C
|
UTF-8
|
C
| false
| false
| 325
|
c
|
land_integer.c
|
#include <stdio.h>
#include <stdlib.h>
#include <mpi.h>
int main(void)
{
MPI_Init(NULL,NULL);
int me, np;
MPI_Comm_rank(MPI_COMM_WORLD,&me);
MPI_Comm_size(MPI_COMM_WORLD,&np);
MPI_Fint i = me;
MPI_Allreduce(MPI_IN_PLACE, &i, 1, MPI_INTEGER, MPI_LAND, MPI_COMM_WORLD);
return MPI_Finalize();
}
|
149e7d97689ced35977ed7489e4e4cf444aff2b6
|
5aa8006a9a48e999fa5d5092fe893b16b84b7999
|
/src/lib/log-c2rust/log-c2rust.h
|
9aaa11207f59caa2616deed572d0e041ac7310d8
|
[
"LicenseRef-scancode-public-domain"
] |
permissive
|
shadow/shadow
|
5a18451ac5a288f82f199ea59bc5adb783de9d7d
|
021dbe7672dbfede4c8093ccd260c61cd3986731
|
refs/heads/main
| 2023-09-02T19:47:30.119593
| 2023-09-01T00:18:23
| 2023-09-01T00:18:23
| 1,759,835
| 1,309
| 252
|
NOASSERTION
| 2023-09-14T19:17:48
| 2011-05-17T08:18:57
|
Rust
|
UTF-8
|
C
| false
| false
| 207
|
h
|
log-c2rust.h
|
#ifndef LOG_C2RUST_H
#define LOG_C2RUST_H
#include "lib/logger/logger.h"
// Create a logger that delegates to Rust's `log` crate.
Logger* rustlogger_new();
void rustlogger_destroy(Logger* logger);
#endif
|
2b4774b6ea2b18624671bcea62053fbc764d2a0e
|
9ac9479f8df2d9fda560a4d05357d2bd3518e98c
|
/native/CefMessageRouter_N.h
|
fe9d3a063b742afcccf56e0f3ca67f9562146248
|
[
"BSD-3-Clause"
] |
permissive
|
JetBrains/jcef
|
e6861656ff686b6de46b45b6ba14c3ece7da0294
|
4a605f44671a1d28217e57bb70ce3f86e6e8e017
|
refs/heads/master
| 2023-09-01T02:58:33.153526
| 2022-06-13T02:50:04
| 2022-06-15T23:03:34
| 157,432,009
| 157
| 35
|
NOASSERTION
| 2023-04-07T09:07:04
| 2018-11-13T19:08:56
|
Java
|
UTF-8
|
C
| false
| true
| 2,276
|
h
|
CefMessageRouter_N.h
|
/* DO NOT EDIT THIS FILE - it is machine generated */
#include <jni.h>
/* Header for class org_cef_browser_CefMessageRouter_N */
#ifndef _Included_org_cef_browser_CefMessageRouter_N
#define _Included_org_cef_browser_CefMessageRouter_N
#ifdef __cplusplus
extern "C" {
#endif
/*
* Class: org_cef_browser_CefMessageRouter_N
* Method: N_Create
* Signature:
* (Lorg/cef/browser/CefMessageRouter/CefMessageRouterConfig;)Lorg/cef/browser/CefMessageRouter_N;
*/
JNIEXPORT jobject JNICALL
Java_org_cef_browser_CefMessageRouter_1N_N_1Create(JNIEnv*, jclass, jobject);
/*
* Class: org_cef_browser_CefMessageRouter_N
* Method: N_Dispose
* Signature: (J)V
*/
JNIEXPORT void JNICALL
Java_org_cef_browser_CefMessageRouter_1N_N_1Dispose(JNIEnv*, jobject, jlong);
/*
* Class: org_cef_browser_CefMessageRouter_N
* Method: N_AddHandler
* Signature: (JLorg/cef/handler/CefMessageRouterHandler;Z)Z
*/
JNIEXPORT jboolean JNICALL
Java_org_cef_browser_CefMessageRouter_1N_N_1AddHandler(JNIEnv*,
jobject,
jlong,
jobject,
jboolean);
/*
* Class: org_cef_browser_CefMessageRouter_N
* Method: N_RemoveHandler
* Signature: (JLorg/cef/handler/CefMessageRouterHandler;)Z
*/
JNIEXPORT jboolean JNICALL
Java_org_cef_browser_CefMessageRouter_1N_N_1RemoveHandler(JNIEnv*,
jobject,
jlong,
jobject);
/*
* Class: org_cef_browser_CefMessageRouter_N
* Method: N_CancelPending
* Signature:
* (JLorg/cef/browser/CefBrowser;Lorg/cef/handler/CefMessageRouterHandler;)V
*/
JNIEXPORT void JNICALL
Java_org_cef_browser_CefMessageRouter_1N_N_1CancelPending(JNIEnv*,
jobject,
jlong,
jobject,
jobject);
#ifdef __cplusplus
}
#endif
#endif
|
04e2ecc6f6103b483b3edf50425f40037b46e59c
|
7eaf54a78c9e2117247cb2ab6d3a0c20719ba700
|
/SOFTWARE/A64-TERES/linux-a64/sound/soc/au1x/psc.h
|
b16b2e02e0c9dec6dac5450ab922255059ee2283
|
[
"LicenseRef-scancode-free-unknown",
"Apache-2.0",
"Linux-syscall-note",
"GPL-2.0-only",
"GPL-1.0-or-later"
] |
permissive
|
OLIMEX/DIY-LAPTOP
|
ae82f4ee79c641d9aee444db9a75f3f6709afa92
|
a3fafd1309135650bab27f5eafc0c32bc3ca74ee
|
refs/heads/rel3
| 2023-08-04T01:54:19.483792
| 2023-04-03T07:18:12
| 2023-04-03T07:18:12
| 80,094,055
| 507
| 92
|
Apache-2.0
| 2023-04-03T07:05:59
| 2017-01-26T07:25:50
|
C
|
UTF-8
|
C
| false
| false
| 1,350
|
h
|
psc.h
|
/*
* Alchemy ALSA ASoC audio support.
*
* (c) 2007-2011 MSC Vertriebsges.m.b.H.,
* Manuel Lauss <manuel.lauss@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
*/
#ifndef _AU1X_PCM_H
#define _AU1X_PCM_H
struct au1xpsc_audio_data {
void __iomem *mmio;
unsigned long cfg;
unsigned long rate;
struct snd_soc_dai_driver dai_drv;
unsigned long pm[2];
struct mutex lock;
int dmaids[2];
};
/* easy access macros */
#define PSC_CTRL(x) ((unsigned long)((x)->mmio) + PSC_CTRL_OFFSET)
#define PSC_SEL(x) ((unsigned long)((x)->mmio) + PSC_SEL_OFFSET)
#define I2S_STAT(x) ((unsigned long)((x)->mmio) + PSC_I2SSTAT_OFFSET)
#define I2S_CFG(x) ((unsigned long)((x)->mmio) + PSC_I2SCFG_OFFSET)
#define I2S_PCR(x) ((unsigned long)((x)->mmio) + PSC_I2SPCR_OFFSET)
#define AC97_CFG(x) ((unsigned long)((x)->mmio) + PSC_AC97CFG_OFFSET)
#define AC97_CDC(x) ((unsigned long)((x)->mmio) + PSC_AC97CDC_OFFSET)
#define AC97_EVNT(x) ((unsigned long)((x)->mmio) + PSC_AC97EVNT_OFFSET)
#define AC97_PCR(x) ((unsigned long)((x)->mmio) + PSC_AC97PCR_OFFSET)
#define AC97_RST(x) ((unsigned long)((x)->mmio) + PSC_AC97RST_OFFSET)
#define AC97_STAT(x) ((unsigned long)((x)->mmio) + PSC_AC97STAT_OFFSET)
#endif
|
72af8d77a354d5d0584cfcb2566aa0077b80c70d
|
78297bc868d588dd7a16cfea059ef7365ba18622
|
/lib/api/include/irods/getRemoteZoneResc.h
|
bdab3c470877f764fc15299edd25d992ea0ab911
|
[
"BSD-3-Clause"
] |
permissive
|
irods/irods
|
ab72a41fdf05a4a905c3e3a97bb7ba3c2a6ae52d
|
f3ccaa842218e477395ebcf553639134433b63ee
|
refs/heads/main
| 2023-09-01T20:12:33.322002
| 2023-08-23T18:22:59
| 2023-08-31T13:41:31
| 14,724,975
| 381
| 167
|
NOASSERTION
| 2023-09-11T18:18:14
| 2013-11-26T18:10:18
|
C++
|
UTF-8
|
C
| false
| false
| 342
|
h
|
getRemoteZoneResc.h
|
#ifndef GET_REMOTE_ZONE_RESC_H__
#define GET_REMOTE_ZONE_RESC_H__
#define REMOTE_CREATE "remoteCreate"
#define REMOTE_OPEN "remoteOpen"
#include "irods/rcConnect.h"
#include "irods/rodsDef.h"
#ifdef __cplusplus
extern "C"
#endif
int rcGetRemoteZoneResc( rcComm_t *conn, dataObjInp_t *dataObjInp, rodsHostAddr_t **rescAddr );
#endif
|
b7170f813236edc9bf6c20dd73f092e2a6649508
|
0577a46d8d28e1fd8636893bbdd2b18270bb8eb8
|
/update_notifier/thirdparty/wxWidgets/docs/doxygen/overviews/windowids.h
|
ad8bce1720773a972e6c4e31ccf8bdc6bf9d47de
|
[
"BSD-3-Clause",
"LicenseRef-scancode-other-copyleft",
"WxWindows-exception-3.1",
"LGPL-2.0-or-later",
"GPL-1.0-or-later",
"IJG",
"GPL-2.0-only",
"LGPL-2.0-only"
] |
permissive
|
ric2b/Vivaldi-browser
|
388a328b4cb838a4c3822357a5529642f86316a5
|
87244f4ee50062e59667bf8b9ca4d5291b6818d7
|
refs/heads/master
| 2022-12-21T04:44:13.804535
| 2022-12-17T16:30:35
| 2022-12-17T16:30:35
| 86,637,416
| 166
| 41
|
BSD-3-Clause
| 2021-03-31T18:49:30
| 2017-03-29T23:09:05
| null |
UTF-8
|
C
| false
| false
| 3,874
|
h
|
windowids.h
|
/////////////////////////////////////////////////////////////////////////////
// Name: windowids.h
// Purpose: topic overview
// Author: wxWidgets team
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
/**
@page overview_windowids Window IDs
@tableofcontents
When creating a new wxWindow-derived class or adding a menu item, its ID must
be specified. An ID is just a unique (at least locally, i.e. inside the same
top level window) integer allowing to find the window or menu item later and to
distinguish between events from different objects.
If applicable, stock IDs such as ::wxID_EXIT (for menu item) or ::wxID_OK (for
a button) should be used, see @ref page_stockitems for the full list of such
IDs.
If the value of an ID is not important, ::wxID_ANY should be used, telling
wxWidgets to allocate a unique ID automatically. All such
automatically-assigned IDs are negative and so won't conflict with any
user-defined IDs as long as they are positive.
If you do care about the ID value but don't want to specify it as a literal in
your code, you can use wxWindow::NewControlId() to create an ID that had never
been returned by this function before. Such IDs are also negative.
Finally, you can just define your own IDs. Typically this is done by using a
C++ enum to automatically ensure their uniqueness. If you do this, please note
that your custom IDs must be positive to avoid clashes with the automatically
assigned IDs discussed above and should @e not have values 0 or 1, that can
result in surprising behaviour under some platforms. Finally, you also need to
avoid defining IDs in the range from ::wxID_LOWEST to ::wxID_HIGHEST which is
reserved for wxWidgets-defined IDs, see ::wxStandardID for more details.
To avoid all these restrictions, it is best to avoid using hard-coded IDs at
all, they are not needed when using wxEvtHandler::Bind() for event handling
(unlike with the previously used event tables).
@see wxIdManager, wxWindow::NewControlId(), wxWindow::UnreserveControlId()
@section overview_windowids_type Data Types
A wxWindowID is just the integer type for a window ID. It should be used
almost everywhere. To help keep track of the count for the automatically
generated IDs, a new type, wxWindowIDRef exists, that can take the place of
wxWindowID where needed. When an ID is first created, it is marked as reserved.
When assigning it to a wxWindowIDRef, the usage count of the ID is increased,
or set to 1 if it is currently reserved. Assigning the same ID to several
wxWindowIDRefs will keep track of the count. As the wxWindowIDRef gets
destroyed or its value changes, it will decrease the count of the used ID. When
there are no more wxWindowIDRef types with the created ID, the ID is considered
free and can then be used again by wxWindow::NewControlId.
If a created ID is not assigned to a wxWindowIDRef, then it remains reserved
until it is unreserved manually with wxWindow::UnreserveControlId. However, if
it is assigned to a wxWindowIDRef, then it will be unreserved automatically and
will be considered free when the count is 0, and should NOT be manually
unreserved.
wxWindowIDRef can store both automatic IDs from wxWindow::NewControlId and
normal IDs. Reference counting is only done for the automatic IDs. Also,
wxWindowIDRef has conversion operators that allow it to be treated just like a
wxWindowID.
@section overview_windowids_using Using wxWindowIDRef
A wxWindowIDRef should be used in place of a wxWindowID where you want to make
sure the ID is not created again by wxWindow::NewControlId at least until the
wxWindowIDRef is destroyed, usually when the associated object is destroyed.
This is done already for windows, menu items, and tool bar items. It should
only be used in the main thread, as it is not thread safe.
*/
|
ae75faa34da3c8dc4280596f355a5c8c5e547c56
|
fe2c2c0b23fa5dcdfbdf53261c49aabde5760819
|
/include/gt/gthe3_regs.h
|
b969e86b478dee0e968074eb8a0e79588a6f82ff
|
[
"BSD-2-Clause-Views",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
corundum/corundum
|
fde50818fa2ea64ee311db22cecb1da578760a03
|
ed4a26e2cbc0a429c45d5cd5ddf1177f86838914
|
refs/heads/master
| 2023-08-11T02:37:40.480657
| 2023-07-14T01:45:01
| 2023-07-14T01:45:01
| 197,059,490
| 828
| 194
|
NOASSERTION
| 2023-07-07T07:30:53
| 2019-07-15T19:27:33
|
Verilog
|
UTF-8
|
C
| false
| false
| 113,626
|
h
|
gthe3_regs.h
|
// SPDX-License-Identifier: BSD-2-Clause-Views
/*
* Copyright (c) 2022-2023 The Regents of the University of California
*/
#ifndef GTHE3_REGS_H
#define GTHE3_REGS_H
#include <limits.h>
#ifndef BIT_MASK
#define BIT_MASK(h, l) \
((~0UL << ((l) & (sizeof(1UL)*CHAR_BIT-1))) & \
(~0UL >> (((-(h)-1) & (sizeof(1UL)*CHAR_BIT-1)))))
#endif
// common registers
#define GTHE3_COM_QPLL0_CFG0_ADDR 0x0008
#define GTHE3_COM_QPLL0_CFG0_MSB 15
#define GTHE3_COM_QPLL0_CFG0_LSB 0
#define GTHE3_COM_QPLL0_CFG0_MASK BIT_MASK(GTHE3_COM_QPLL0_CFG0_MSB, GTHE3_COM_QPLL0_CFG0_LSB)
#define GTHE3_COM_COMMON_CFG0_ADDR 0x0009
#define GTHE3_COM_COMMON_CFG0_MSB 15
#define GTHE3_COM_COMMON_CFG0_LSB 0
#define GTHE3_COM_COMMON_CFG0_MASK BIT_MASK(GTHE3_COM_COMMON_CFG0_MSB, GTHE3_COM_COMMON_CFG0_LSB)
#define GTHE3_COM_RSVD_ATTR0_ADDR 0x000B
#define GTHE3_COM_RSVD_ATTR0_MSB 15
#define GTHE3_COM_RSVD_ATTR0_LSB 0
#define GTHE3_COM_RSVD_ATTR0_MASK BIT_MASK(GTHE3_COM_RSVD_ATTR0_MSB, GTHE3_COM_RSVD_ATTR0_LSB)
#define GTHE3_COM_QPLL0_CFG1_ADDR 0x0010
#define GTHE3_COM_QPLL0_CFG1_MSB 15
#define GTHE3_COM_QPLL0_CFG1_LSB 0
#define GTHE3_COM_QPLL0_CFG1_MASK BIT_MASK(GTHE3_COM_QPLL0_CFG1_MSB, GTHE3_COM_QPLL0_CFG1_LSB)
#define GTHE3_COM_QPLL0_CFG2_ADDR 0x0011
#define GTHE3_COM_QPLL0_CFG2_MSB 15
#define GTHE3_COM_QPLL0_CFG2_LSB 0
#define GTHE3_COM_QPLL0_CFG2_MASK BIT_MASK(GTHE3_COM_QPLL0_CFG2_MSB, GTHE3_COM_QPLL0_CFG2_LSB)
#define GTHE3_COM_QPLL0_LOCK_CFG_ADDR 0x0012
#define GTHE3_COM_QPLL0_LOCK_CFG_MSB 15
#define GTHE3_COM_QPLL0_LOCK_CFG_LSB 0
#define GTHE3_COM_QPLL0_LOCK_CFG_MASK BIT_MASK(GTHE3_COM_QPLL0_LOCK_CFG_MSB, GTHE3_COM_QPLL0_LOCK_CFG_LSB)
#define GTHE3_COM_QPLL0_INIT_CFG0_ADDR 0x0013
#define GTHE3_COM_QPLL0_INIT_CFG0_MSB 15
#define GTHE3_COM_QPLL0_INIT_CFG0_LSB 0
#define GTHE3_COM_QPLL0_INIT_CFG0_MASK BIT_MASK(GTHE3_COM_QPLL0_INIT_CFG0_MSB, GTHE3_COM_QPLL0_INIT_CFG0_LSB)
#define GTHE3_COM_QPLL0_INIT_CFG1_ADDR 0x0014
#define GTHE3_COM_QPLL0_INIT_CFG1_MSB 15
#define GTHE3_COM_QPLL0_INIT_CFG1_LSB 8
#define GTHE3_COM_QPLL0_INIT_CFG1_MASK BIT_MASK(GTHE3_COM_QPLL0_INIT_CFG1_MSB, GTHE3_COM_QPLL0_INIT_CFG1_LSB)
#define GTHE3_COM_QPLL0_FBDIV_ADDR 0x0014
#define GTHE3_COM_QPLL0_FBDIV_MSB 7
#define GTHE3_COM_QPLL0_FBDIV_LSB 0
#define GTHE3_COM_QPLL0_FBDIV_MASK BIT_MASK(GTHE3_COM_QPLL0_FBDIV_MSB, GTHE3_COM_QPLL0_FBDIV_LSB)
#define GTHE3_COM_QPLL0_CFG3_ADDR 0x0015
#define GTHE3_COM_QPLL0_CFG3_MSB 15
#define GTHE3_COM_QPLL0_CFG3_LSB 0
#define GTHE3_COM_QPLL0_CFG3_MASK BIT_MASK(GTHE3_COM_QPLL0_CFG3_MSB, GTHE3_COM_QPLL0_CFG3_LSB)
#define GTHE3_COM_QPLL0_CP_ADDR 0x0016
#define GTHE3_COM_QPLL0_CP_MSB 9
#define GTHE3_COM_QPLL0_CP_LSB 0
#define GTHE3_COM_QPLL0_CP_MASK BIT_MASK(GTHE3_COM_QPLL0_CP_MSB, GTHE3_COM_QPLL0_CP_LSB)
#define GTHE3_COM_QPLL0_REFCLK_DIV_ADDR 0x0018
#define GTHE3_COM_QPLL0_REFCLK_DIV_MSB 11
#define GTHE3_COM_QPLL0_REFCLK_DIV_LSB 7
#define GTHE3_COM_QPLL0_REFCLK_DIV_MASK BIT_MASK(GTHE3_COM_QPLL0_REFCLK_DIV_MSB, GTHE3_COM_QPLL0_REFCLK_DIV_LSB)
#define GTHE3_COM_QPLL0_REFCLK_DIV_1 16
#define GTHE3_COM_QPLL0_REFCLK_DIV_2 0
#define GTHE3_COM_QPLL0_REFCLK_DIV_3 1
#define GTHE3_COM_QPLL0_REFCLK_DIV_4 2
#define GTHE3_COM_QPLL0_REFCLK_DIV_5 3
#define GTHE3_COM_QPLL0_REFCLK_DIV_6 5
#define GTHE3_COM_QPLL0_REFCLK_DIV_8 6
#define GTHE3_COM_QPLL0_REFCLK_DIV_10 7
#define GTHE3_COM_QPLL0_REFCLK_DIV_12 13
#define GTHE3_COM_QPLL0_REFCLK_DIV_16 14
#define GTHE3_COM_QPLL0_REFCLK_DIV_20 15
#define GTHE3_COM_QPLL0_LPF_ADDR 0x0019
#define GTHE3_COM_QPLL0_LPF_MSB 9
#define GTHE3_COM_QPLL0_LPF_LSB 0
#define GTHE3_COM_QPLL0_LPF_MASK BIT_MASK(GTHE3_COM_QPLL0_LPF_MSB, GTHE3_COM_QPLL0_LPF_LSB)
#define GTHE3_COM_QPLL0_CFG1_G3_ADDR 0x001A
#define GTHE3_COM_QPLL0_CFG1_G3_MSB 15
#define GTHE3_COM_QPLL0_CFG1_G3_LSB 0
#define GTHE3_COM_QPLL0_CFG1_G3_MASK BIT_MASK(GTHE3_COM_QPLL0_CFG1_G3_MSB, GTHE3_COM_QPLL0_CFG1_G3_LSB)
#define GTHE3_COM_QPLL0_CFG2_G3_ADDR 0x001B
#define GTHE3_COM_QPLL0_CFG2_G3_MSB 15
#define GTHE3_COM_QPLL0_CFG2_G3_LSB 0
#define GTHE3_COM_QPLL0_CFG2_G3_MASK BIT_MASK(GTHE3_COM_QPLL0_CFG2_G3_MSB, GTHE3_COM_QPLL0_CFG2_G3_LSB)
#define GTHE3_COM_QPLL0_LPF_G3_ADDR 0x001C
#define GTHE3_COM_QPLL0_LPF_G3_MSB 9
#define GTHE3_COM_QPLL0_LPF_G3_LSB 0
#define GTHE3_COM_QPLL0_LPF_G3_MASK BIT_MASK(GTHE3_COM_QPLL0_LPF_G3_MSB, GTHE3_COM_QPLL0_LPF_G3_LSB)
#define GTHE3_COM_QPLL0_LOCK_CFG_G3_ADDR 0x001D
#define GTHE3_COM_QPLL0_LOCK_CFG_G3_MSB 15
#define GTHE3_COM_QPLL0_LOCK_CFG_G3_LSB 0
#define GTHE3_COM_QPLL0_LOCK_CFG_G3_MASK BIT_MASK(GTHE3_COM_QPLL0_LOCK_CFG_G3_MSB, GTHE3_COM_QPLL0_LOCK_CFG_G3_LSB)
#define GTHE3_COM_RSVD_ATTR1_ADDR 0x001E
#define GTHE3_COM_RSVD_ATTR1_MSB 15
#define GTHE3_COM_RSVD_ATTR1_LSB 0
#define GTHE3_COM_RSVD_ATTR1_MASK BIT_MASK(GTHE3_COM_RSVD_ATTR1_MSB, GTHE3_COM_RSVD_ATTR1_LSB)
#define GTHE3_COM_QPLL0_FBDIV_G3_ADDR 0x001F
#define GTHE3_COM_QPLL0_FBDIV_G3_MSB 15
#define GTHE3_COM_QPLL0_FBDIV_G3_LSB 8
#define GTHE3_COM_QPLL0_FBDIV_G3_MASK BIT_MASK(GTHE3_COM_QPLL0_FBDIV_G3_MSB, GTHE3_COM_QPLL0_FBDIV_G3_LSB)
#define GTHE3_COM_RXRECCLKOUT0_SEL_ADDR 0x001F
#define GTHE3_COM_RXRECCLKOUT0_SEL_MSB 1
#define GTHE3_COM_RXRECCLKOUT0_SEL_LSB 0
#define GTHE3_COM_RXRECCLKOUT0_SEL_MASK BIT_MASK(GTHE3_COM_RXRECCLKOUT0_SEL_MSB, GTHE3_COM_RXRECCLKOUT0_SEL_LSB)
#define GTHE3_COM_QPLL0_SDM_CFG0_ADDR 0x0020
#define GTHE3_COM_QPLL0_SDM_CFG0_MSB 15
#define GTHE3_COM_QPLL0_SDM_CFG0_LSB 0
#define GTHE3_COM_QPLL0_SDM_CFG0_MASK BIT_MASK(GTHE3_COM_QPLL0_SDM_CFG0_MSB, GTHE3_COM_QPLL0_SDM_CFG0_LSB)
#define GTHE3_COM_QPLL0_SDM_CFG1_ADDR 0x0021
#define GTHE3_COM_QPLL0_SDM_CFG1_MSB 15
#define GTHE3_COM_QPLL0_SDM_CFG1_LSB 0
#define GTHE3_COM_QPLL0_SDM_CFG1_MASK BIT_MASK(GTHE3_COM_QPLL0_SDM_CFG1_MSB, GTHE3_COM_QPLL0_SDM_CFG1_LSB)
#define GTHE3_COM_SDM0INITSEED0_0_ADDR 0x0022
#define GTHE3_COM_SDM0INITSEED0_0_MSB 15
#define GTHE3_COM_SDM0INITSEED0_0_LSB 0
#define GTHE3_COM_SDM0INITSEED0_0_MASK BIT_MASK(GTHE3_COM_SDM0INITSEED0_0_MSB, GTHE3_COM_SDM0INITSEED0_0_LSB)
#define GTHE3_COM_SDM0INITSEED0_1_ADDR 0x0023
#define GTHE3_COM_SDM0INITSEED0_1_MSB 8
#define GTHE3_COM_SDM0INITSEED0_1_LSB 0
#define GTHE3_COM_SDM0INITSEED0_1_MASK BIT_MASK(GTHE3_COM_SDM0INITSEED0_1_MSB, GTHE3_COM_SDM0INITSEED0_1_LSB)
#define GTHE3_COM_QPLL0_SDM_CFG2_ADDR 0x0024
#define GTHE3_COM_QPLL0_SDM_CFG2_MSB 15
#define GTHE3_COM_QPLL0_SDM_CFG2_LSB 0
#define GTHE3_COM_QPLL0_SDM_CFG2_MASK BIT_MASK(GTHE3_COM_QPLL0_SDM_CFG2_MSB, GTHE3_COM_QPLL0_SDM_CFG2_LSB)
#define GTHE3_COM_QPLL0_CP_G3_ADDR 0x0025
#define GTHE3_COM_QPLL0_CP_G3_MSB 9
#define GTHE3_COM_QPLL0_CP_G3_LSB 0
#define GTHE3_COM_QPLL0_CP_G3_MASK BIT_MASK(GTHE3_COM_QPLL0_CP_G3_MSB, GTHE3_COM_QPLL0_CP_G3_LSB)
#define GTHE3_COM_SDM0DATA1_0_ADDR 0x0028
#define GTHE3_COM_SDM0DATA1_0_MSB 15
#define GTHE3_COM_SDM0DATA1_0_LSB 0
#define GTHE3_COM_SDM0DATA1_0_MASK BIT_MASK(GTHE3_COM_SDM0DATA1_0_MSB, GTHE3_COM_SDM0DATA1_0_LSB)
#define GTHE3_COM_SDM0_WIDTH_PIN_SEL_ADDR 0x0029
#define GTHE3_COM_SDM0_WIDTH_PIN_SEL_MSB 10
#define GTHE3_COM_SDM0_WIDTH_PIN_SEL_LSB 10
#define GTHE3_COM_SDM0_WIDTH_PIN_SEL_MASK BIT_MASK(GTHE3_COM_SDM0_WIDTH_PIN_SEL_MSB, GTHE3_COM_SDM0_WIDTH_PIN_SEL_LSB)
#define GTHE3_COM_SDM0_DATA_PIN_SEL_ADDR 0x0029
#define GTHE3_COM_SDM0_DATA_PIN_SEL_MSB 9
#define GTHE3_COM_SDM0_DATA_PIN_SEL_LSB 9
#define GTHE3_COM_SDM0_DATA_PIN_SEL_MASK BIT_MASK(GTHE3_COM_SDM0_DATA_PIN_SEL_MSB, GTHE3_COM_SDM0_DATA_PIN_SEL_LSB)
#define GTHE3_COM_SDM0DATA1_1_ADDR 0x0029
#define GTHE3_COM_SDM0DATA1_1_MSB 8
#define GTHE3_COM_SDM0DATA1_1_LSB 0
#define GTHE3_COM_SDM0DATA1_1_MASK BIT_MASK(GTHE3_COM_SDM0DATA1_1_MSB, GTHE3_COM_SDM0DATA1_1_LSB)
#define GTHE3_COM_QPLL0_CFG4_ADDR 0x0030
#define GTHE3_COM_QPLL0_CFG4_MSB 15
#define GTHE3_COM_QPLL0_CFG4_LSB 0
#define GTHE3_COM_QPLL0_CFG4_MASK BIT_MASK(GTHE3_COM_QPLL0_CFG4_MSB, GTHE3_COM_QPLL0_CFG4_LSB)
#define GTHE3_COM_BIAS_CFG0_ADDR 0x0081
#define GTHE3_COM_BIAS_CFG0_MSB 15
#define GTHE3_COM_BIAS_CFG0_LSB 0
#define GTHE3_COM_BIAS_CFG0_MASK BIT_MASK(GTHE3_COM_BIAS_CFG0_MSB, GTHE3_COM_BIAS_CFG0_LSB)
#define GTHE3_COM_BIAS_CFG1_ADDR 0x0082
#define GTHE3_COM_BIAS_CFG1_MSB 15
#define GTHE3_COM_BIAS_CFG1_LSB 0
#define GTHE3_COM_BIAS_CFG1_MASK BIT_MASK(GTHE3_COM_BIAS_CFG1_MSB, GTHE3_COM_BIAS_CFG1_LSB)
#define GTHE3_COM_BIAS_CFG2_ADDR 0x0083
#define GTHE3_COM_BIAS_CFG2_MSB 15
#define GTHE3_COM_BIAS_CFG2_LSB 0
#define GTHE3_COM_BIAS_CFG2_MASK BIT_MASK(GTHE3_COM_BIAS_CFG2_MSB, GTHE3_COM_BIAS_CFG2_LSB)
#define GTHE3_COM_BIAS_CFG3_ADDR 0x0084
#define GTHE3_COM_BIAS_CFG3_MSB 15
#define GTHE3_COM_BIAS_CFG3_LSB 0
#define GTHE3_COM_BIAS_CFG3_MASK BIT_MASK(GTHE3_COM_BIAS_CFG3_MSB, GTHE3_COM_BIAS_CFG3_LSB)
#define GTHE3_COM_BIAS_CFG_RSVD_ADDR 0x0085
#define GTHE3_COM_BIAS_CFG_RSVD_MSB 9
#define GTHE3_COM_BIAS_CFG_RSVD_LSB 0
#define GTHE3_COM_BIAS_CFG_RSVD_MASK BIT_MASK(GTHE3_COM_BIAS_CFG_RSVD_MSB, GTHE3_COM_BIAS_CFG_RSVD_LSB)
#define GTHE3_COM_BIAS_CFG4_ADDR 0x0086
#define GTHE3_COM_BIAS_CFG4_MSB 15
#define GTHE3_COM_BIAS_CFG4_LSB 0
#define GTHE3_COM_BIAS_CFG4_MASK BIT_MASK(GTHE3_COM_BIAS_CFG4_MSB, GTHE3_COM_BIAS_CFG4_LSB)
#define GTHE3_COM_QPLL1_CFG0_ADDR 0x0088
#define GTHE3_COM_QPLL1_CFG0_MSB 15
#define GTHE3_COM_QPLL1_CFG0_LSB 0
#define GTHE3_COM_QPLL1_CFG0_MASK BIT_MASK(GTHE3_COM_QPLL1_CFG0_MSB, GTHE3_COM_QPLL1_CFG0_LSB)
#define GTHE3_COM_COMMON_CFG1_ADDR 0x0089
#define GTHE3_COM_COMMON_CFG1_MSB 15
#define GTHE3_COM_COMMON_CFG1_LSB 0
#define GTHE3_COM_COMMON_CFG1_MASK BIT_MASK(GTHE3_COM_COMMON_CFG1_MSB, GTHE3_COM_COMMON_CFG1_LSB)
#define GTHE3_COM_POR_CFG_ADDR 0x008B
#define GTHE3_COM_POR_CFG_MSB 15
#define GTHE3_COM_POR_CFG_LSB 0
#define GTHE3_COM_POR_CFG_MASK BIT_MASK(GTHE3_COM_POR_CFG_MSB, GTHE3_COM_POR_CFG_LSB)
#define GTHE3_COM_QPLL1_CFG1_ADDR 0x0090
#define GTHE3_COM_QPLL1_CFG1_MSB 15
#define GTHE3_COM_QPLL1_CFG1_LSB 0
#define GTHE3_COM_QPLL1_CFG1_MASK BIT_MASK(GTHE3_COM_QPLL1_CFG1_MSB, GTHE3_COM_QPLL1_CFG1_LSB)
#define GTHE3_COM_QPLL1_CFG2_ADDR 0x0091
#define GTHE3_COM_QPLL1_CFG2_MSB 15
#define GTHE3_COM_QPLL1_CFG2_LSB 0
#define GTHE3_COM_QPLL1_CFG2_MASK BIT_MASK(GTHE3_COM_QPLL1_CFG2_MSB, GTHE3_COM_QPLL1_CFG2_LSB)
#define GTHE3_COM_QPLL1_LOCK_CFG_ADDR 0x0092
#define GTHE3_COM_QPLL1_LOCK_CFG_MSB 15
#define GTHE3_COM_QPLL1_LOCK_CFG_LSB 0
#define GTHE3_COM_QPLL1_LOCK_CFG_MASK BIT_MASK(GTHE3_COM_QPLL1_LOCK_CFG_MSB, GTHE3_COM_QPLL1_LOCK_CFG_LSB)
#define GTHE3_COM_QPLL1_INIT_CFG0_ADDR 0x0093
#define GTHE3_COM_QPLL1_INIT_CFG0_MSB 15
#define GTHE3_COM_QPLL1_INIT_CFG0_LSB 0
#define GTHE3_COM_QPLL1_INIT_CFG0_MASK BIT_MASK(GTHE3_COM_QPLL1_INIT_CFG0_MSB, GTHE3_COM_QPLL1_INIT_CFG0_LSB)
#define GTHE3_COM_QPLL1_INIT_CFG1_ADDR 0x0094
#define GTHE3_COM_QPLL1_INIT_CFG1_MSB 15
#define GTHE3_COM_QPLL1_INIT_CFG1_LSB 8
#define GTHE3_COM_QPLL1_INIT_CFG1_MASK BIT_MASK(GTHE3_COM_QPLL1_INIT_CFG1_MSB, GTHE3_COM_QPLL1_INIT_CFG1_LSB)
#define GTHE3_COM_QPLL1_FBDIV_ADDR 0x0094
#define GTHE3_COM_QPLL1_FBDIV_MSB 7
#define GTHE3_COM_QPLL1_FBDIV_LSB 0
#define GTHE3_COM_QPLL1_FBDIV_MASK BIT_MASK(GTHE3_COM_QPLL1_FBDIV_MSB, GTHE3_COM_QPLL1_FBDIV_LSB)
#define GTHE3_COM_QPLL1_CFG3_ADDR 0x0095
#define GTHE3_COM_QPLL1_CFG3_MSB 15
#define GTHE3_COM_QPLL1_CFG3_LSB 0
#define GTHE3_COM_QPLL1_CFG3_MASK BIT_MASK(GTHE3_COM_QPLL1_CFG3_MSB, GTHE3_COM_QPLL1_CFG3_LSB)
#define GTHE3_COM_QPLL1_CP_ADDR 0x0096
#define GTHE3_COM_QPLL1_CP_MSB 9
#define GTHE3_COM_QPLL1_CP_LSB 0
#define GTHE3_COM_QPLL1_CP_MASK BIT_MASK(GTHE3_COM_QPLL1_CP_MSB, GTHE3_COM_QPLL1_CP_LSB)
#define GTHE3_COM_SARC_SEL_ADDR 0x0098
#define GTHE3_COM_SARC_SEL_MSB 13
#define GTHE3_COM_SARC_SEL_LSB 13
#define GTHE3_COM_SARC_SEL_MASK BIT_MASK(GTHE3_COM_SARC_SEL_MSB, GTHE3_COM_SARC_SEL_LSB)
#define GTHE3_COM_SARC_EN_ADDR 0x0098
#define GTHE3_COM_SARC_EN_MSB 12
#define GTHE3_COM_SARC_EN_LSB 12
#define GTHE3_COM_SARC_EN_MASK BIT_MASK(GTHE3_COM_SARC_EN_MSB, GTHE3_COM_SARC_EN_LSB)
#define GTHE3_COM_QPLL1_REFCLK_DIV_ADDR 0x0098
#define GTHE3_COM_QPLL1_REFCLK_DIV_MSB 11
#define GTHE3_COM_QPLL1_REFCLK_DIV_LSB 7
#define GTHE3_COM_QPLL1_REFCLK_DIV_MASK BIT_MASK(GTHE3_COM_QPLL1_REFCLK_DIV_MSB, GTHE3_COM_QPLL1_REFCLK_DIV_LSB)
#define GTHE3_COM_QPLL1_REFCLK_DIV_1 16
#define GTHE3_COM_QPLL1_REFCLK_DIV_2 0
#define GTHE3_COM_QPLL1_REFCLK_DIV_3 1
#define GTHE3_COM_QPLL1_REFCLK_DIV_4 2
#define GTHE3_COM_QPLL1_REFCLK_DIV_5 3
#define GTHE3_COM_QPLL1_REFCLK_DIV_6 5
#define GTHE3_COM_QPLL1_REFCLK_DIV_8 6
#define GTHE3_COM_QPLL1_REFCLK_DIV_10 7
#define GTHE3_COM_QPLL1_REFCLK_DIV_12 13
#define GTHE3_COM_QPLL1_REFCLK_DIV_16 14
#define GTHE3_COM_QPLL1_REFCLK_DIV_20 15
#define GTHE3_COM_QPLL1_LPF_ADDR 0x0099
#define GTHE3_COM_QPLL1_LPF_MSB 9
#define GTHE3_COM_QPLL1_LPF_LSB 0
#define GTHE3_COM_QPLL1_LPF_MASK BIT_MASK(GTHE3_COM_QPLL1_LPF_MSB, GTHE3_COM_QPLL1_LPF_LSB)
#define GTHE3_COM_QPLL1_CFG1_G3_ADDR 0x009A
#define GTHE3_COM_QPLL1_CFG1_G3_MSB 15
#define GTHE3_COM_QPLL1_CFG1_G3_LSB 0
#define GTHE3_COM_QPLL1_CFG1_G3_MASK BIT_MASK(GTHE3_COM_QPLL1_CFG1_G3_MSB, GTHE3_COM_QPLL1_CFG1_G3_LSB)
#define GTHE3_COM_QPLL1_CFG2_G3_ADDR 0x009B
#define GTHE3_COM_QPLL1_CFG2_G3_MSB 15
#define GTHE3_COM_QPLL1_CFG2_G3_LSB 0
#define GTHE3_COM_QPLL1_CFG2_G3_MASK BIT_MASK(GTHE3_COM_QPLL1_CFG2_G3_MSB, GTHE3_COM_QPLL1_CFG2_G3_LSB)
#define GTHE3_COM_QPLL1_LPF_G3_ADDR 0x009C
#define GTHE3_COM_QPLL1_LPF_G3_MSB 9
#define GTHE3_COM_QPLL1_LPF_G3_LSB 0
#define GTHE3_COM_QPLL1_LPF_G3_MASK BIT_MASK(GTHE3_COM_QPLL1_LPF_G3_MSB, GTHE3_COM_QPLL1_LPF_G3_LSB)
#define GTHE3_COM_QPLL1_LOCK_CFG_G3_ADDR 0x009D
#define GTHE3_COM_QPLL1_LOCK_CFG_G3_MSB 15
#define GTHE3_COM_QPLL1_LOCK_CFG_G3_LSB 0
#define GTHE3_COM_QPLL1_LOCK_CFG_G3_MASK BIT_MASK(GTHE3_COM_QPLL1_LOCK_CFG_G3_MSB, GTHE3_COM_QPLL1_LOCK_CFG_G3_LSB)
#define GTHE3_COM_RSVD_ATTR2_ADDR 0x009E
#define GTHE3_COM_RSVD_ATTR2_MSB 15
#define GTHE3_COM_RSVD_ATTR2_LSB 0
#define GTHE3_COM_RSVD_ATTR2_MASK BIT_MASK(GTHE3_COM_RSVD_ATTR2_MSB, GTHE3_COM_RSVD_ATTR2_LSB)
#define GTHE3_COM_QPLL1_FBDIV_G3_ADDR 0x009F
#define GTHE3_COM_QPLL1_FBDIV_G3_MSB 15
#define GTHE3_COM_QPLL1_FBDIV_G3_LSB 8
#define GTHE3_COM_QPLL1_FBDIV_G3_MASK BIT_MASK(GTHE3_COM_QPLL1_FBDIV_G3_MSB, GTHE3_COM_QPLL1_FBDIV_G3_LSB)
#define GTHE3_COM_RXRECCLKOUT1_SEL_ADDR 0x009F
#define GTHE3_COM_RXRECCLKOUT1_SEL_MSB 1
#define GTHE3_COM_RXRECCLKOUT1_SEL_LSB 0
#define GTHE3_COM_RXRECCLKOUT1_SEL_MASK BIT_MASK(GTHE3_COM_RXRECCLKOUT1_SEL_MSB, GTHE3_COM_RXRECCLKOUT1_SEL_LSB)
#define GTHE3_COM_QPLL1_SDM_CFG0_ADDR 0x00A0
#define GTHE3_COM_QPLL1_SDM_CFG0_MSB 15
#define GTHE3_COM_QPLL1_SDM_CFG0_LSB 0
#define GTHE3_COM_QPLL1_SDM_CFG0_MASK BIT_MASK(GTHE3_COM_QPLL1_SDM_CFG0_MSB, GTHE3_COM_QPLL1_SDM_CFG0_LSB)
#define GTHE3_COM_QPLL1_SDM_CFG1_ADDR 0x00A1
#define GTHE3_COM_QPLL1_SDM_CFG1_MSB 15
#define GTHE3_COM_QPLL1_SDM_CFG1_LSB 0
#define GTHE3_COM_QPLL1_SDM_CFG1_MASK BIT_MASK(GTHE3_COM_QPLL1_SDM_CFG1_MSB, GTHE3_COM_QPLL1_SDM_CFG1_LSB)
#define GTHE3_COM_SDM1INITSEED0_0_ADDR 0x00A2
#define GTHE3_COM_SDM1INITSEED0_0_MSB 15
#define GTHE3_COM_SDM1INITSEED0_0_LSB 0
#define GTHE3_COM_SDM1INITSEED0_0_MASK BIT_MASK(GTHE3_COM_SDM1INITSEED0_0_MSB, GTHE3_COM_SDM1INITSEED0_0_LSB)
#define GTHE3_COM_SDM1INITSEED0_1_ADDR 0x00A3
#define GTHE3_COM_SDM1INITSEED0_1_MSB 8
#define GTHE3_COM_SDM1INITSEED0_1_LSB 0
#define GTHE3_COM_SDM1INITSEED0_1_MASK BIT_MASK(GTHE3_COM_SDM1INITSEED0_1_MSB, GTHE3_COM_SDM1INITSEED0_1_LSB)
#define GTHE3_COM_QPLL1_SDM_CFG2_ADDR 0x00A4
#define GTHE3_COM_QPLL1_SDM_CFG2_MSB 15
#define GTHE3_COM_QPLL1_SDM_CFG2_LSB 0
#define GTHE3_COM_QPLL1_SDM_CFG2_MASK BIT_MASK(GTHE3_COM_QPLL1_SDM_CFG2_MSB, GTHE3_COM_QPLL1_SDM_CFG2_LSB)
#define GTHE3_COM_QPLL1_CP_G3_ADDR 0x00A5
#define GTHE3_COM_QPLL1_CP_G3_MSB 9
#define GTHE3_COM_QPLL1_CP_G3_LSB 0
#define GTHE3_COM_QPLL1_CP_G3_MASK BIT_MASK(GTHE3_COM_QPLL1_CP_G3_MSB, GTHE3_COM_QPLL1_CP_G3_LSB)
#define GTHE3_COM_SDM1DATA1_0_ADDR 0x00A8
#define GTHE3_COM_SDM1DATA1_0_MSB 15
#define GTHE3_COM_SDM1DATA1_0_LSB 0
#define GTHE3_COM_SDM1DATA1_0_MASK BIT_MASK(GTHE3_COM_SDM1DATA1_0_MSB, GTHE3_COM_SDM1DATA1_0_LSB)
#define GTHE3_COM_SDM1_WIDTH_PIN_SEL_ADDR 0x00A9
#define GTHE3_COM_SDM1_WIDTH_PIN_SEL_MSB 10
#define GTHE3_COM_SDM1_WIDTH_PIN_SEL_LSB 10
#define GTHE3_COM_SDM1_WIDTH_PIN_SEL_MASK BIT_MASK(GTHE3_COM_SDM1_WIDTH_PIN_SEL_MSB, GTHE3_COM_SDM1_WIDTH_PIN_SEL_LSB)
#define GTHE3_COM_SDM1_DATA_PIN_SEL_ADDR 0x00A9
#define GTHE3_COM_SDM1_DATA_PIN_SEL_MSB 9
#define GTHE3_COM_SDM1_DATA_PIN_SEL_LSB 9
#define GTHE3_COM_SDM1_DATA_PIN_SEL_MASK BIT_MASK(GTHE3_COM_SDM1_DATA_PIN_SEL_MSB, GTHE3_COM_SDM1_DATA_PIN_SEL_LSB)
#define GTHE3_COM_SDM1DATA1_1_ADDR 0x00A9
#define GTHE3_COM_SDM1DATA1_1_MSB 8
#define GTHE3_COM_SDM1DATA1_1_LSB 0
#define GTHE3_COM_SDM1DATA1_1_MASK BIT_MASK(GTHE3_COM_SDM1DATA1_1_MSB, GTHE3_COM_SDM1DATA1_1_LSB)
#define GTHE3_COM_RSVD_ATTR3_ADDR 0x00AD
#define GTHE3_COM_RSVD_ATTR3_MSB 15
#define GTHE3_COM_RSVD_ATTR3_LSB 0
#define GTHE3_COM_RSVD_ATTR3_MASK BIT_MASK(GTHE3_COM_RSVD_ATTR3_MSB, GTHE3_COM_RSVD_ATTR3_LSB)
#define GTHE3_COM_QPLL1_CFG4_ADDR 0x00B0
#define GTHE3_COM_QPLL1_CFG4_MSB 15
#define GTHE3_COM_QPLL1_CFG4_LSB 0
#define GTHE3_COM_QPLL1_CFG4_MASK BIT_MASK(GTHE3_COM_QPLL1_CFG4_MSB, GTHE3_COM_QPLL1_CFG4_LSB)
// channel registers
#define GTHE3_CH_CDR_SWAP_MODE_EN_ADDR 0x0002
#define GTHE3_CH_CDR_SWAP_MODE_EN_MSB 0
#define GTHE3_CH_CDR_SWAP_MODE_EN_LSB 0
#define GTHE3_CH_CDR_SWAP_MODE_EN_MASK BIT_MASK(GTHE3_CH_CDR_SWAP_MODE_EN_MSB, GTHE3_CH_CDR_SWAP_MODE_EN_LSB)
#define GTHE3_CH_RXBUFRESET_TIME_ADDR 0x0003
#define GTHE3_CH_RXBUFRESET_TIME_MSB 15
#define GTHE3_CH_RXBUFRESET_TIME_LSB 11
#define GTHE3_CH_RXBUFRESET_TIME_MASK BIT_MASK(GTHE3_CH_RXBUFRESET_TIME_MSB, GTHE3_CH_RXBUFRESET_TIME_LSB)
#define GTHE3_CH_EYE_SCAN_SWAP_EN_ADDR 0x0003
#define GTHE3_CH_EYE_SCAN_SWAP_EN_MSB 9
#define GTHE3_CH_EYE_SCAN_SWAP_EN_LSB 9
#define GTHE3_CH_EYE_SCAN_SWAP_EN_MASK BIT_MASK(GTHE3_CH_EYE_SCAN_SWAP_EN_MSB, GTHE3_CH_EYE_SCAN_SWAP_EN_LSB)
#define GTHE3_CH_RX_DATA_WIDTH_ADDR 0x0003
#define GTHE3_CH_RX_DATA_WIDTH_MSB 8
#define GTHE3_CH_RX_DATA_WIDTH_LSB 5
#define GTHE3_CH_RX_DATA_WIDTH_MASK BIT_MASK(GTHE3_CH_RX_DATA_WIDTH_MSB, GTHE3_CH_RX_DATA_WIDTH_LSB)
#define GTHE3_CH_RX_DATA_WIDTH_16 2
#define GTHE3_CH_RX_DATA_WIDTH_20 3
#define GTHE3_CH_RX_DATA_WIDTH_32 4
#define GTHE3_CH_RX_DATA_WIDTH_40 5
#define GTHE3_CH_RX_DATA_WIDTH_64 6
#define GTHE3_CH_RX_DATA_WIDTH_80 7
#define GTHE3_CH_RX_DATA_WIDTH_128 8
#define GTHE3_CH_RX_DATA_WIDTH_160 9
#define GTHE3_CH_RXCDRFREQRESET_TIME_ADDR 0x0003
#define GTHE3_CH_RXCDRFREQRESET_TIME_MSB 4
#define GTHE3_CH_RXCDRFREQRESET_TIME_LSB 0
#define GTHE3_CH_RXCDRFREQRESET_TIME_MASK BIT_MASK(GTHE3_CH_RXCDRFREQRESET_TIME_MSB, GTHE3_CH_RXCDRFREQRESET_TIME_LSB)
#define GTHE3_CH_RXCDRPHRESET_TIME_ADDR 0x0004
#define GTHE3_CH_RXCDRPHRESET_TIME_MSB 15
#define GTHE3_CH_RXCDRPHRESET_TIME_LSB 11
#define GTHE3_CH_RXCDRPHRESET_TIME_MASK BIT_MASK(GTHE3_CH_RXCDRPHRESET_TIME_MSB, GTHE3_CH_RXCDRPHRESET_TIME_LSB)
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_DISABLE_ADDR 0x0004
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_DISABLE_MSB 10
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_DISABLE_LSB 8
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_DISABLE_MASK BIT_MASK(GTHE3_CH_PCI3_RX_ELECIDLE_H2L_DISABLE_MSB, GTHE3_CH_PCI3_RX_ELECIDLE_H2L_DISABLE_LSB)
#define GTHE3_CH_RXDFELPMRESET_TIME_ADDR 0x0004
#define GTHE3_CH_RXDFELPMRESET_TIME_MSB 7
#define GTHE3_CH_RXDFELPMRESET_TIME_LSB 1
#define GTHE3_CH_RXDFELPMRESET_TIME_MASK BIT_MASK(GTHE3_CH_RXDFELPMRESET_TIME_MSB, GTHE3_CH_RXDFELPMRESET_TIME_LSB)
#define GTHE3_CH_RX_FABINT_USRCLK_FLOP_ADDR 0x0004
#define GTHE3_CH_RX_FABINT_USRCLK_FLOP_MSB 0
#define GTHE3_CH_RX_FABINT_USRCLK_FLOP_LSB 0
#define GTHE3_CH_RX_FABINT_USRCLK_FLOP_MASK BIT_MASK(GTHE3_CH_RX_FABINT_USRCLK_FLOP_MSB, GTHE3_CH_RX_FABINT_USRCLK_FLOP_LSB)
#define GTHE3_CH_RXPMARESET_TIME_ADDR 0x0005
#define GTHE3_CH_RXPMARESET_TIME_MSB 15
#define GTHE3_CH_RXPMARESET_TIME_LSB 11
#define GTHE3_CH_RXPMARESET_TIME_MASK BIT_MASK(GTHE3_CH_RXPMARESET_TIME_MSB, GTHE3_CH_RXPMARESET_TIME_LSB)
#define GTHE3_CH_PCI3_RX_ELECIDLE_LP4_DISABLE_ADDR 0x0005
#define GTHE3_CH_PCI3_RX_ELECIDLE_LP4_DISABLE_MSB 10
#define GTHE3_CH_PCI3_RX_ELECIDLE_LP4_DISABLE_LSB 10
#define GTHE3_CH_PCI3_RX_ELECIDLE_LP4_DISABLE_MASK BIT_MASK(GTHE3_CH_PCI3_RX_ELECIDLE_LP4_DISABLE_MSB, GTHE3_CH_PCI3_RX_ELECIDLE_LP4_DISABLE_LSB)
#define GTHE3_CH_PCI3_RX_ELECIDLE_EI2_ENABLE_ADDR 0x0005
#define GTHE3_CH_PCI3_RX_ELECIDLE_EI2_ENABLE_MSB 9
#define GTHE3_CH_PCI3_RX_ELECIDLE_EI2_ENABLE_LSB 9
#define GTHE3_CH_PCI3_RX_ELECIDLE_EI2_ENABLE_MASK BIT_MASK(GTHE3_CH_PCI3_RX_ELECIDLE_EI2_ENABLE_MSB, GTHE3_CH_PCI3_RX_ELECIDLE_EI2_ENABLE_LSB)
#define GTHE3_CH_PCI3_RX_FIFO_DISABLE_ADDR 0x0005
#define GTHE3_CH_PCI3_RX_FIFO_DISABLE_MSB 8
#define GTHE3_CH_PCI3_RX_FIFO_DISABLE_LSB 8
#define GTHE3_CH_PCI3_RX_FIFO_DISABLE_MASK BIT_MASK(GTHE3_CH_PCI3_RX_FIFO_DISABLE_MSB, GTHE3_CH_PCI3_RX_FIFO_DISABLE_LSB)
#define GTHE3_CH_RXPCSRESET_TIME_ADDR 0x0005
#define GTHE3_CH_RXPCSRESET_TIME_MSB 7
#define GTHE3_CH_RXPCSRESET_TIME_LSB 3
#define GTHE3_CH_RXPCSRESET_TIME_MASK BIT_MASK(GTHE3_CH_RXPCSRESET_TIME_MSB, GTHE3_CH_RXPCSRESET_TIME_LSB)
#define GTHE3_CH_RXELECIDLE_CFG_ADDR 0x0005
#define GTHE3_CH_RXELECIDLE_CFG_MSB 2
#define GTHE3_CH_RXELECIDLE_CFG_LSB 0
#define GTHE3_CH_RXELECIDLE_CFG_MASK BIT_MASK(GTHE3_CH_RXELECIDLE_CFG_MSB, GTHE3_CH_RXELECIDLE_CFG_LSB)
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_1 0
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_2 1
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_3 2
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_4 3
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_6 4
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_8 5
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_12 6
#define GTHE3_CH_RXELECIDLE_CFG_SIGCFG_16 7
#define GTHE3_CH_RXDFE_HB_CFG1_ADDR 0x0006
#define GTHE3_CH_RXDFE_HB_CFG1_MSB 15
#define GTHE3_CH_RXDFE_HB_CFG1_LSB 0
#define GTHE3_CH_RXDFE_HB_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_HB_CFG1_MSB, GTHE3_CH_RXDFE_HB_CFG1_LSB)
#define GTHE3_CH_TXPMARESET_TIME_ADDR 0x0009
#define GTHE3_CH_TXPMARESET_TIME_MSB 15
#define GTHE3_CH_TXPMARESET_TIME_LSB 11
#define GTHE3_CH_TXPMARESET_TIME_MASK BIT_MASK(GTHE3_CH_TXPMARESET_TIME_MSB, GTHE3_CH_TXPMARESET_TIME_LSB)
#define GTHE3_CH_RX_PMA_POWER_SAVE_ADDR 0x0009
#define GTHE3_CH_RX_PMA_POWER_SAVE_MSB 10
#define GTHE3_CH_RX_PMA_POWER_SAVE_LSB 10
#define GTHE3_CH_RX_PMA_POWER_SAVE_MASK BIT_MASK(GTHE3_CH_RX_PMA_POWER_SAVE_MSB, GTHE3_CH_RX_PMA_POWER_SAVE_LSB)
#define GTHE3_CH_TX_PMA_POWER_SAVE_ADDR 0x0009
#define GTHE3_CH_TX_PMA_POWER_SAVE_MSB 9
#define GTHE3_CH_TX_PMA_POWER_SAVE_LSB 9
#define GTHE3_CH_TX_PMA_POWER_SAVE_MASK BIT_MASK(GTHE3_CH_TX_PMA_POWER_SAVE_MSB, GTHE3_CH_TX_PMA_POWER_SAVE_LSB)
#define GTHE3_CH_TXPCSRESET_TIME_ADDR 0x0009
#define GTHE3_CH_TXPCSRESET_TIME_MSB 7
#define GTHE3_CH_TXPCSRESET_TIME_LSB 3
#define GTHE3_CH_TXPCSRESET_TIME_MASK BIT_MASK(GTHE3_CH_TXPCSRESET_TIME_MSB, GTHE3_CH_TXPCSRESET_TIME_LSB)
#define GTHE3_CH_WB_MODE_ADDR 0x000B
#define GTHE3_CH_WB_MODE_MSB 15
#define GTHE3_CH_WB_MODE_LSB 14
#define GTHE3_CH_WB_MODE_MASK BIT_MASK(GTHE3_CH_WB_MODE_MSB, GTHE3_CH_WB_MODE_LSB)
#define GTHE3_CH_RXPMACLK_SEL_ADDR 0x000B
#define GTHE3_CH_RXPMACLK_SEL_MSB 9
#define GTHE3_CH_RXPMACLK_SEL_LSB 8
#define GTHE3_CH_RXPMACLK_SEL_MASK BIT_MASK(GTHE3_CH_RXPMACLK_SEL_MSB, GTHE3_CH_RXPMACLK_SEL_LSB)
#define GTHE3_CH_RXPMACLK_SEL_DATA 0
#define GTHE3_CH_RXPMACLK_SEL_EYESCAN 1
#define GTHE3_CH_RXPMACLK_SEL_CROSSING 2
#define GTHE3_CH_TX_FABINT_USRCLK_FLOP_ADDR 0x000B
#define GTHE3_CH_TX_FABINT_USRCLK_FLOP_MSB 4
#define GTHE3_CH_TX_FABINT_USRCLK_FLOP_LSB 4
#define GTHE3_CH_TX_FABINT_USRCLK_FLOP_MASK BIT_MASK(GTHE3_CH_TX_FABINT_USRCLK_FLOP_MSB, GTHE3_CH_TX_FABINT_USRCLK_FLOP_LSB)
#define GTHE3_CH_TX_PROGCLK_SEL_ADDR 0x000C
#define GTHE3_CH_TX_PROGCLK_SEL_MSB 11
#define GTHE3_CH_TX_PROGCLK_SEL_LSB 10
#define GTHE3_CH_TX_PROGCLK_SEL_MASK BIT_MASK(GTHE3_CH_TX_PROGCLK_SEL_MSB, GTHE3_CH_TX_PROGCLK_SEL_LSB)
#define GTHE3_CH_TX_PROGCLK_SEL_POSTPI 0
#define GTHE3_CH_TX_PROGCLK_SEL_PREPI 1
#define GTHE3_CH_TX_PROGCLK_SEL_CPLL 2
#define GTHE3_CH_RXISCANRESET_TIME_ADDR 0x000C
#define GTHE3_CH_RXISCANRESET_TIME_MSB 9
#define GTHE3_CH_RXISCANRESET_TIME_LSB 5
#define GTHE3_CH_RXISCANRESET_TIME_MASK BIT_MASK(GTHE3_CH_RXISCANRESET_TIME_MSB, GTHE3_CH_RXISCANRESET_TIME_LSB)
#define GTHE3_CH_RXCDR_CFG0_ADDR 0x000E
#define GTHE3_CH_RXCDR_CFG0_MSB 15
#define GTHE3_CH_RXCDR_CFG0_LSB 0
#define GTHE3_CH_RXCDR_CFG0_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG0_MSB, GTHE3_CH_RXCDR_CFG0_LSB)
#define GTHE3_CH_RXCDR_CFG1_ADDR 0x000F
#define GTHE3_CH_RXCDR_CFG1_MSB 15
#define GTHE3_CH_RXCDR_CFG1_LSB 0
#define GTHE3_CH_RXCDR_CFG1_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG1_MSB, GTHE3_CH_RXCDR_CFG1_LSB)
#define GTHE3_CH_RXCDR_CFG2_ADDR 0x0010
#define GTHE3_CH_RXCDR_CFG2_MSB 15
#define GTHE3_CH_RXCDR_CFG2_LSB 0
#define GTHE3_CH_RXCDR_CFG2_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG2_MSB, GTHE3_CH_RXCDR_CFG2_LSB)
#define GTHE3_CH_RXCDR_CFG3_ADDR 0x0011
#define GTHE3_CH_RXCDR_CFG3_MSB 15
#define GTHE3_CH_RXCDR_CFG3_LSB 0
#define GTHE3_CH_RXCDR_CFG3_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG3_MSB, GTHE3_CH_RXCDR_CFG3_LSB)
#define GTHE3_CH_RXCDR_CFG4_ADDR 0x0012
#define GTHE3_CH_RXCDR_CFG4_MSB 15
#define GTHE3_CH_RXCDR_CFG4_LSB 0
#define GTHE3_CH_RXCDR_CFG4_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG4_MSB, GTHE3_CH_RXCDR_CFG4_LSB)
#define GTHE3_CH_RXCDR_LOCK_CFG0_ADDR 0x0013
#define GTHE3_CH_RXCDR_LOCK_CFG0_MSB 15
#define GTHE3_CH_RXCDR_LOCK_CFG0_LSB 0
#define GTHE3_CH_RXCDR_LOCK_CFG0_MASK BIT_MASK(GTHE3_CH_RXCDR_LOCK_CFG0_MSB, GTHE3_CH_RXCDR_LOCK_CFG0_LSB)
#define GTHE3_CH_CHAN_BOND_MAX_SKEW_ADDR 0x0014
#define GTHE3_CH_CHAN_BOND_MAX_SKEW_MSB 15
#define GTHE3_CH_CHAN_BOND_MAX_SKEW_LSB 12
#define GTHE3_CH_CHAN_BOND_MAX_SKEW_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_MAX_SKEW_MSB, GTHE3_CH_CHAN_BOND_MAX_SKEW_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_ADDR 0x0014
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_MSB 11
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_LSB 10
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_LEN_MSB, GTHE3_CH_CHAN_BOND_SEQ_LEN_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_1 0
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_2 1
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_3 2
#define GTHE3_CH_CHAN_BOND_SEQ_LEN_4 3
#define GTHE3_CH_CHAN_BOND_SEQ_1_1_ADDR 0x0014
#define GTHE3_CH_CHAN_BOND_SEQ_1_1_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_1_1_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_1_1_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_1_1_MSB, GTHE3_CH_CHAN_BOND_SEQ_1_1_LSB)
#define GTHE3_CH_PCI3_RX_ELECIDLE_HI_COUNT_ADDR 0x0015
#define GTHE3_CH_PCI3_RX_ELECIDLE_HI_COUNT_MSB 15
#define GTHE3_CH_PCI3_RX_ELECIDLE_HI_COUNT_LSB 10
#define GTHE3_CH_PCI3_RX_ELECIDLE_HI_COUNT_MASK BIT_MASK(GTHE3_CH_PCI3_RX_ELECIDLE_HI_COUNT_MSB, GTHE3_CH_PCI3_RX_ELECIDLE_HI_COUNT_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_1_3_ADDR 0x0015
#define GTHE3_CH_CHAN_BOND_SEQ_1_3_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_1_3_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_1_3_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_1_3_MSB, GTHE3_CH_CHAN_BOND_SEQ_1_3_LSB)
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_COUNT_ADDR 0x0016
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_COUNT_MSB 15
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_COUNT_LSB 10
#define GTHE3_CH_PCI3_RX_ELECIDLE_H2L_COUNT_MASK BIT_MASK(GTHE3_CH_PCI3_RX_ELECIDLE_H2L_COUNT_MSB, GTHE3_CH_PCI3_RX_ELECIDLE_H2L_COUNT_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_1_4_ADDR 0x0016
#define GTHE3_CH_CHAN_BOND_SEQ_1_4_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_1_4_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_1_4_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_1_4_MSB, GTHE3_CH_CHAN_BOND_SEQ_1_4_LSB)
#define GTHE3_CH_RX_BUFFER_CFG_ADDR 0x0017
#define GTHE3_CH_RX_BUFFER_CFG_MSB 15
#define GTHE3_CH_RX_BUFFER_CFG_LSB 10
#define GTHE3_CH_RX_BUFFER_CFG_MASK BIT_MASK(GTHE3_CH_RX_BUFFER_CFG_MSB, GTHE3_CH_RX_BUFFER_CFG_LSB)
#define GTHE3_CH_RX_DEFER_RESET_BUF_EN_ADDR 0x0017
#define GTHE3_CH_RX_DEFER_RESET_BUF_EN_MSB 9
#define GTHE3_CH_RX_DEFER_RESET_BUF_EN_LSB 9
#define GTHE3_CH_RX_DEFER_RESET_BUF_EN_MASK BIT_MASK(GTHE3_CH_RX_DEFER_RESET_BUF_EN_MSB, GTHE3_CH_RX_DEFER_RESET_BUF_EN_LSB)
#define GTHE3_CH_OOBDIVCTL0_ADDR 0x0017
#define GTHE3_CH_OOBDIVCTL0_MSB 8
#define GTHE3_CH_OOBDIVCTL0_LSB 7
#define GTHE3_CH_OOBDIVCTL0_MASK BIT_MASK(GTHE3_CH_OOBDIVCTL0_MSB, GTHE3_CH_OOBDIVCTL0_LSB)
#define GTHE3_CH_PCI3_AUTO_REALIGN_ADDR 0x0017
#define GTHE3_CH_PCI3_AUTO_REALIGN_MSB 6
#define GTHE3_CH_PCI3_AUTO_REALIGN_LSB 5
#define GTHE3_CH_PCI3_AUTO_REALIGN_MASK BIT_MASK(GTHE3_CH_PCI3_AUTO_REALIGN_MSB, GTHE3_CH_PCI3_AUTO_REALIGN_LSB)
#define GTHE3_CH_PCI3_AUTO_REALIGN_FRST_SMPL 0
#define GTHE3_CH_PCI3_AUTO_REALIGN_OVR_8_BLK 1
#define GTHE3_CH_PCI3_AUTO_REALIGN_OVR_64_BLK 2
#define GTHE3_CH_PCI3_AUTO_REALIGN_OVR_1K_BLK 3
#define GTHE3_CH_PCI3_PIPE_RX_ELECIDLE_ADDR 0x0017
#define GTHE3_CH_PCI3_PIPE_RX_ELECIDLE_MSB 4
#define GTHE3_CH_PCI3_PIPE_RX_ELECIDLE_LSB 4
#define GTHE3_CH_PCI3_PIPE_RX_ELECIDLE_MASK BIT_MASK(GTHE3_CH_PCI3_PIPE_RX_ELECIDLE_MSB, GTHE3_CH_PCI3_PIPE_RX_ELECIDLE_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_1_ENABLE_ADDR 0x0018
#define GTHE3_CH_CHAN_BOND_SEQ_1_ENABLE_MSB 15
#define GTHE3_CH_CHAN_BOND_SEQ_1_ENABLE_LSB 12
#define GTHE3_CH_CHAN_BOND_SEQ_1_ENABLE_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_1_ENABLE_MSB, GTHE3_CH_CHAN_BOND_SEQ_1_ENABLE_LSB)
#define GTHE3_CH_PCI3_RX_ASYNC_EBUF_BYPASS_ADDR 0x0018
#define GTHE3_CH_PCI3_RX_ASYNC_EBUF_BYPASS_MSB 11
#define GTHE3_CH_PCI3_RX_ASYNC_EBUF_BYPASS_LSB 10
#define GTHE3_CH_PCI3_RX_ASYNC_EBUF_BYPASS_MASK BIT_MASK(GTHE3_CH_PCI3_RX_ASYNC_EBUF_BYPASS_MSB, GTHE3_CH_PCI3_RX_ASYNC_EBUF_BYPASS_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_2_1_ADDR 0x0018
#define GTHE3_CH_CHAN_BOND_SEQ_2_1_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_2_1_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_2_1_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_2_1_MSB, GTHE3_CH_CHAN_BOND_SEQ_2_1_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_2_2_ADDR 0x0019
#define GTHE3_CH_CHAN_BOND_SEQ_2_2_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_2_2_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_2_2_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_2_2_MSB, GTHE3_CH_CHAN_BOND_SEQ_2_2_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_2_3_ADDR 0x001A
#define GTHE3_CH_CHAN_BOND_SEQ_2_3_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_2_3_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_2_3_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_2_3_MSB, GTHE3_CH_CHAN_BOND_SEQ_2_3_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_2_4_ADDR 0x001B
#define GTHE3_CH_CHAN_BOND_SEQ_2_4_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_2_4_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_2_4_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_2_4_MSB, GTHE3_CH_CHAN_BOND_SEQ_2_4_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_2_ENABLE_ADDR 0x001C
#define GTHE3_CH_CHAN_BOND_SEQ_2_ENABLE_MSB 15
#define GTHE3_CH_CHAN_BOND_SEQ_2_ENABLE_LSB 12
#define GTHE3_CH_CHAN_BOND_SEQ_2_ENABLE_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_2_ENABLE_MSB, GTHE3_CH_CHAN_BOND_SEQ_2_ENABLE_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_2_USE_ADDR 0x001C
#define GTHE3_CH_CHAN_BOND_SEQ_2_USE_MSB 11
#define GTHE3_CH_CHAN_BOND_SEQ_2_USE_LSB 11
#define GTHE3_CH_CHAN_BOND_SEQ_2_USE_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_2_USE_MSB, GTHE3_CH_CHAN_BOND_SEQ_2_USE_LSB)
#define GTHE3_CH_CLK_COR_KEEP_IDLE_ADDR 0x001C
#define GTHE3_CH_CLK_COR_KEEP_IDLE_MSB 6
#define GTHE3_CH_CLK_COR_KEEP_IDLE_LSB 6
#define GTHE3_CH_CLK_COR_KEEP_IDLE_MASK BIT_MASK(GTHE3_CH_CLK_COR_KEEP_IDLE_MSB, GTHE3_CH_CLK_COR_KEEP_IDLE_LSB)
#define GTHE3_CH_CLK_COR_MIN_LAT_ADDR 0x001C
#define GTHE3_CH_CLK_COR_MIN_LAT_MSB 5
#define GTHE3_CH_CLK_COR_MIN_LAT_LSB 0
#define GTHE3_CH_CLK_COR_MIN_LAT_MASK BIT_MASK(GTHE3_CH_CLK_COR_MIN_LAT_MSB, GTHE3_CH_CLK_COR_MIN_LAT_LSB)
#define GTHE3_CH_CLK_COR_MAX_LAT_ADDR 0x001D
#define GTHE3_CH_CLK_COR_MAX_LAT_MSB 15
#define GTHE3_CH_CLK_COR_MAX_LAT_LSB 10
#define GTHE3_CH_CLK_COR_MAX_LAT_MASK BIT_MASK(GTHE3_CH_CLK_COR_MAX_LAT_MSB, GTHE3_CH_CLK_COR_MAX_LAT_LSB)
#define GTHE3_CH_CLK_COR_PRECEDENCE_ADDR 0x001D
#define GTHE3_CH_CLK_COR_PRECEDENCE_MSB 9
#define GTHE3_CH_CLK_COR_PRECEDENCE_LSB 9
#define GTHE3_CH_CLK_COR_PRECEDENCE_MASK BIT_MASK(GTHE3_CH_CLK_COR_PRECEDENCE_MSB, GTHE3_CH_CLK_COR_PRECEDENCE_LSB)
#define GTHE3_CH_CLK_COR_REPEAT_WAIT_ADDR 0x001D
#define GTHE3_CH_CLK_COR_REPEAT_WAIT_MSB 8
#define GTHE3_CH_CLK_COR_REPEAT_WAIT_LSB 4
#define GTHE3_CH_CLK_COR_REPEAT_WAIT_MASK BIT_MASK(GTHE3_CH_CLK_COR_REPEAT_WAIT_MSB, GTHE3_CH_CLK_COR_REPEAT_WAIT_LSB)
#define GTHE3_CH_CLK_COR_SEQ_LEN_ADDR 0x001D
#define GTHE3_CH_CLK_COR_SEQ_LEN_MSB 3
#define GTHE3_CH_CLK_COR_SEQ_LEN_LSB 2
#define GTHE3_CH_CLK_COR_SEQ_LEN_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_LEN_MSB, GTHE3_CH_CLK_COR_SEQ_LEN_LSB)
#define GTHE3_CH_CLK_COR_SEQ_LEN_1 0
#define GTHE3_CH_CLK_COR_SEQ_LEN_2 1
#define GTHE3_CH_CLK_COR_SEQ_LEN_3 2
#define GTHE3_CH_CLK_COR_SEQ_LEN_4 3
#define GTHE3_CH_CHAN_BOND_KEEP_ALIGN_ADDR 0x001D
#define GTHE3_CH_CHAN_BOND_KEEP_ALIGN_MSB 0
#define GTHE3_CH_CHAN_BOND_KEEP_ALIGN_LSB 0
#define GTHE3_CH_CHAN_BOND_KEEP_ALIGN_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_KEEP_ALIGN_MSB, GTHE3_CH_CHAN_BOND_KEEP_ALIGN_LSB)
#define GTHE3_CH_CLK_COR_SEQ_1_1_ADDR 0x001E
#define GTHE3_CH_CLK_COR_SEQ_1_1_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_1_1_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_1_1_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_1_1_MSB, GTHE3_CH_CLK_COR_SEQ_1_1_LSB)
#define GTHE3_CH_CLK_COR_SEQ_1_2_ADDR 0x001F
#define GTHE3_CH_CLK_COR_SEQ_1_2_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_1_2_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_1_2_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_1_2_MSB, GTHE3_CH_CLK_COR_SEQ_1_2_LSB)
#define GTHE3_CH_CLK_COR_SEQ_1_3_ADDR 0x0020
#define GTHE3_CH_CLK_COR_SEQ_1_3_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_1_3_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_1_3_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_1_3_MSB, GTHE3_CH_CLK_COR_SEQ_1_3_LSB)
#define GTHE3_CH_CLK_COR_SEQ_1_4_ADDR 0x0021
#define GTHE3_CH_CLK_COR_SEQ_1_4_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_1_4_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_1_4_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_1_4_MSB, GTHE3_CH_CLK_COR_SEQ_1_4_LSB)
#define GTHE3_CH_CLK_COR_SEQ_1_ENABLE_ADDR 0x0022
#define GTHE3_CH_CLK_COR_SEQ_1_ENABLE_MSB 15
#define GTHE3_CH_CLK_COR_SEQ_1_ENABLE_LSB 12
#define GTHE3_CH_CLK_COR_SEQ_1_ENABLE_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_1_ENABLE_MSB, GTHE3_CH_CLK_COR_SEQ_1_ENABLE_LSB)
#define GTHE3_CH_CLK_COR_SEQ_2_1_ADDR 0x0022
#define GTHE3_CH_CLK_COR_SEQ_2_1_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_2_1_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_2_1_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_2_1_MSB, GTHE3_CH_CLK_COR_SEQ_2_1_LSB)
#define GTHE3_CH_CLK_COR_SEQ_2_2_ADDR 0x0023
#define GTHE3_CH_CLK_COR_SEQ_2_2_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_2_2_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_2_2_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_2_2_MSB, GTHE3_CH_CLK_COR_SEQ_2_2_LSB)
#define GTHE3_CH_CLK_COR_SEQ_2_ENABLE_ADDR 0x0024
#define GTHE3_CH_CLK_COR_SEQ_2_ENABLE_MSB 15
#define GTHE3_CH_CLK_COR_SEQ_2_ENABLE_LSB 12
#define GTHE3_CH_CLK_COR_SEQ_2_ENABLE_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_2_ENABLE_MSB, GTHE3_CH_CLK_COR_SEQ_2_ENABLE_LSB)
#define GTHE3_CH_CLK_COR_SEQ_2_USE_ADDR 0x0024
#define GTHE3_CH_CLK_COR_SEQ_2_USE_MSB 11
#define GTHE3_CH_CLK_COR_SEQ_2_USE_LSB 11
#define GTHE3_CH_CLK_COR_SEQ_2_USE_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_2_USE_MSB, GTHE3_CH_CLK_COR_SEQ_2_USE_LSB)
#define GTHE3_CH_CLK_CORRECT_USE_ADDR 0x0024
#define GTHE3_CH_CLK_CORRECT_USE_MSB 10
#define GTHE3_CH_CLK_CORRECT_USE_LSB 10
#define GTHE3_CH_CLK_CORRECT_USE_MASK BIT_MASK(GTHE3_CH_CLK_CORRECT_USE_MSB, GTHE3_CH_CLK_CORRECT_USE_LSB)
#define GTHE3_CH_CLK_COR_SEQ_2_3_ADDR 0x0024
#define GTHE3_CH_CLK_COR_SEQ_2_3_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_2_3_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_2_3_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_2_3_MSB, GTHE3_CH_CLK_COR_SEQ_2_3_LSB)
#define GTHE3_CH_CLK_COR_SEQ_2_4_ADDR 0x0025
#define GTHE3_CH_CLK_COR_SEQ_2_4_MSB 9
#define GTHE3_CH_CLK_COR_SEQ_2_4_LSB 0
#define GTHE3_CH_CLK_COR_SEQ_2_4_MASK BIT_MASK(GTHE3_CH_CLK_COR_SEQ_2_4_MSB, GTHE3_CH_CLK_COR_SEQ_2_4_LSB)
#define GTHE3_CH_RXDFE_HE_CFG0_ADDR 0x0026
#define GTHE3_CH_RXDFE_HE_CFG0_MSB 15
#define GTHE3_CH_RXDFE_HE_CFG0_LSB 0
#define GTHE3_CH_RXDFE_HE_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_HE_CFG0_MSB, GTHE3_CH_RXDFE_HE_CFG0_LSB)
#define GTHE3_CH_ALIGN_COMMA_WORD_ADDR 0x0027
#define GTHE3_CH_ALIGN_COMMA_WORD_MSB 15
#define GTHE3_CH_ALIGN_COMMA_WORD_LSB 13
#define GTHE3_CH_ALIGN_COMMA_WORD_MASK BIT_MASK(GTHE3_CH_ALIGN_COMMA_WORD_MSB, GTHE3_CH_ALIGN_COMMA_WORD_LSB)
#define GTHE3_CH_ALIGN_COMMA_DOUBLE_ADDR 0x0027
#define GTHE3_CH_ALIGN_COMMA_DOUBLE_MSB 12
#define GTHE3_CH_ALIGN_COMMA_DOUBLE_LSB 12
#define GTHE3_CH_ALIGN_COMMA_DOUBLE_MASK BIT_MASK(GTHE3_CH_ALIGN_COMMA_DOUBLE_MSB, GTHE3_CH_ALIGN_COMMA_DOUBLE_LSB)
#define GTHE3_CH_SHOW_REALIGN_COMMA_ADDR 0x0027
#define GTHE3_CH_SHOW_REALIGN_COMMA_MSB 11
#define GTHE3_CH_SHOW_REALIGN_COMMA_LSB 11
#define GTHE3_CH_SHOW_REALIGN_COMMA_MASK BIT_MASK(GTHE3_CH_SHOW_REALIGN_COMMA_MSB, GTHE3_CH_SHOW_REALIGN_COMMA_LSB)
#define GTHE3_CH_ALIGN_COMMA_ENABLE_ADDR 0x0027
#define GTHE3_CH_ALIGN_COMMA_ENABLE_MSB 9
#define GTHE3_CH_ALIGN_COMMA_ENABLE_LSB 0
#define GTHE3_CH_ALIGN_COMMA_ENABLE_MASK BIT_MASK(GTHE3_CH_ALIGN_COMMA_ENABLE_MSB, GTHE3_CH_ALIGN_COMMA_ENABLE_LSB)
#define GTHE3_CH_CPLL_FBDIV_ADDR 0x0028
#define GTHE3_CH_CPLL_FBDIV_MSB 15
#define GTHE3_CH_CPLL_FBDIV_LSB 8
#define GTHE3_CH_CPLL_FBDIV_MASK BIT_MASK(GTHE3_CH_CPLL_FBDIV_MSB, GTHE3_CH_CPLL_FBDIV_LSB)
#define GTHE3_CH_CPLL_FBDIV_1 16
#define GTHE3_CH_CPLL_FBDIV_2 0
#define GTHE3_CH_CPLL_FBDIV_3 1
#define GTHE3_CH_CPLL_FBDIV_4 2
#define GTHE3_CH_CPLL_FBDIV_5 3
#define GTHE3_CH_CPLL_FBDIV_6 5
#define GTHE3_CH_CPLL_FBDIV_8 6
#define GTHE3_CH_CPLL_FBDIV_10 7
#define GTHE3_CH_CPLL_FBDIV_12 13
#define GTHE3_CH_CPLL_FBDIV_16 14
#define GTHE3_CH_CPLL_FBDIV_20 15
#define GTHE3_CH_CPLL_FBDIV_45_ADDR 0x0028
#define GTHE3_CH_CPLL_FBDIV_45_MSB 7
#define GTHE3_CH_CPLL_FBDIV_45_LSB 7
#define GTHE3_CH_CPLL_FBDIV_45_MASK BIT_MASK(GTHE3_CH_CPLL_FBDIV_45_MSB, GTHE3_CH_CPLL_FBDIV_45_LSB)
#define GTHE3_CH_CPLL_FBDIV_45_4 0
#define GTHE3_CH_CPLL_FBDIV_45_5 1
#define GTHE3_CH_TXDRVBIAS_N_ADDR 0x0028
#define GTHE3_CH_TXDRVBIAS_N_MSB 3
#define GTHE3_CH_TXDRVBIAS_N_LSB 0
#define GTHE3_CH_TXDRVBIAS_N_MASK BIT_MASK(GTHE3_CH_TXDRVBIAS_N_MSB, GTHE3_CH_TXDRVBIAS_N_LSB)
#define GTHE3_CH_CPLL_LOCK_CFG_ADDR 0x0029
#define GTHE3_CH_CPLL_LOCK_CFG_MSB 15
#define GTHE3_CH_CPLL_LOCK_CFG_LSB 0
#define GTHE3_CH_CPLL_LOCK_CFG_MASK BIT_MASK(GTHE3_CH_CPLL_LOCK_CFG_MSB, GTHE3_CH_CPLL_LOCK_CFG_LSB)
#define GTHE3_CH_CPLL_REFCLK_DIV_ADDR 0x002A
#define GTHE3_CH_CPLL_REFCLK_DIV_MSB 15
#define GTHE3_CH_CPLL_REFCLK_DIV_LSB 11
#define GTHE3_CH_CPLL_REFCLK_DIV_MASK BIT_MASK(GTHE3_CH_CPLL_REFCLK_DIV_MSB, GTHE3_CH_CPLL_REFCLK_DIV_LSB)
#define GTHE3_CH_CPLL_REFCLK_DIV_1 16
#define GTHE3_CH_CPLL_REFCLK_DIV_2 0
#define GTHE3_CH_CPLL_REFCLK_DIV_3 1
#define GTHE3_CH_CPLL_REFCLK_DIV_4 2
#define GTHE3_CH_CPLL_REFCLK_DIV_5 3
#define GTHE3_CH_CPLL_REFCLK_DIV_6 5
#define GTHE3_CH_CPLL_REFCLK_DIV_8 6
#define GTHE3_CH_CPLL_REFCLK_DIV_10 7
#define GTHE3_CH_CPLL_REFCLK_DIV_12 13
#define GTHE3_CH_CPLL_REFCLK_DIV_16 14
#define GTHE3_CH_CPLL_REFCLK_DIV_20 15
#define GTHE3_CH_SATA_CPLL_CFG_ADDR 0x002A
#define GTHE3_CH_SATA_CPLL_CFG_MSB 6
#define GTHE3_CH_SATA_CPLL_CFG_LSB 5
#define GTHE3_CH_SATA_CPLL_CFG_MASK BIT_MASK(GTHE3_CH_SATA_CPLL_CFG_MSB, GTHE3_CH_SATA_CPLL_CFG_LSB)
#define GTHE3_CH_SATA_CPLL_CFG_VCO_3000MHZ 0
#define GTHE3_CH_SATA_CPLL_CFG_VCO_1500MHZ 1
#define GTHE3_CH_SATA_CPLL_CFG_VCO_750MHZ 2
#define GTHE3_CH_TXDRVBIAS_P_ADDR 0x002A
#define GTHE3_CH_TXDRVBIAS_P_MSB 3
#define GTHE3_CH_TXDRVBIAS_P_LSB 0
#define GTHE3_CH_TXDRVBIAS_P_MASK BIT_MASK(GTHE3_CH_TXDRVBIAS_P_MSB, GTHE3_CH_TXDRVBIAS_P_LSB)
#define GTHE3_CH_CPLL_INIT_CFG0_ADDR 0x002B
#define GTHE3_CH_CPLL_INIT_CFG0_MSB 15
#define GTHE3_CH_CPLL_INIT_CFG0_LSB 0
#define GTHE3_CH_CPLL_INIT_CFG0_MASK BIT_MASK(GTHE3_CH_CPLL_INIT_CFG0_MSB, GTHE3_CH_CPLL_INIT_CFG0_LSB)
#define GTHE3_CH_DEC_PCOMMA_DETECT_ADDR 0x002C
#define GTHE3_CH_DEC_PCOMMA_DETECT_MSB 15
#define GTHE3_CH_DEC_PCOMMA_DETECT_LSB 15
#define GTHE3_CH_DEC_PCOMMA_DETECT_MASK BIT_MASK(GTHE3_CH_DEC_PCOMMA_DETECT_MSB, GTHE3_CH_DEC_PCOMMA_DETECT_LSB)
#define GTHE3_CH_TX_DIVRESET_TIME_ADDR 0x002C
#define GTHE3_CH_TX_DIVRESET_TIME_MSB 11
#define GTHE3_CH_TX_DIVRESET_TIME_LSB 7
#define GTHE3_CH_TX_DIVRESET_TIME_MASK BIT_MASK(GTHE3_CH_TX_DIVRESET_TIME_MSB, GTHE3_CH_TX_DIVRESET_TIME_LSB)
#define GTHE3_CH_RX_DIVRESET_TIME_ADDR 0x002C
#define GTHE3_CH_RX_DIVRESET_TIME_MSB 6
#define GTHE3_CH_RX_DIVRESET_TIME_LSB 2
#define GTHE3_CH_RX_DIVRESET_TIME_MASK BIT_MASK(GTHE3_CH_RX_DIVRESET_TIME_MSB, GTHE3_CH_RX_DIVRESET_TIME_LSB)
#define GTHE3_CH_A_TXPROGDIVRESET_ADDR 0x002C
#define GTHE3_CH_A_TXPROGDIVRESET_MSB 1
#define GTHE3_CH_A_TXPROGDIVRESET_LSB 1
#define GTHE3_CH_A_TXPROGDIVRESET_MASK BIT_MASK(GTHE3_CH_A_TXPROGDIVRESET_MSB, GTHE3_CH_A_TXPROGDIVRESET_LSB)
#define GTHE3_CH_A_RXPROGDIVRESET_ADDR 0x002C
#define GTHE3_CH_A_RXPROGDIVRESET_MSB 0
#define GTHE3_CH_A_RXPROGDIVRESET_LSB 0
#define GTHE3_CH_A_RXPROGDIVRESET_MASK BIT_MASK(GTHE3_CH_A_RXPROGDIVRESET_MSB, GTHE3_CH_A_RXPROGDIVRESET_LSB)
#define GTHE3_CH_RXCDR_LOCK_CFG1_ADDR 0x002D
#define GTHE3_CH_RXCDR_LOCK_CFG1_MSB 15
#define GTHE3_CH_RXCDR_LOCK_CFG1_LSB 0
#define GTHE3_CH_RXCDR_LOCK_CFG1_MASK BIT_MASK(GTHE3_CH_RXCDR_LOCK_CFG1_MSB, GTHE3_CH_RXCDR_LOCK_CFG1_LSB)
#define GTHE3_CH_RXCFOK_CFG1_ADDR 0x002E
#define GTHE3_CH_RXCFOK_CFG1_MSB 15
#define GTHE3_CH_RXCFOK_CFG1_LSB 0
#define GTHE3_CH_RXCFOK_CFG1_MASK BIT_MASK(GTHE3_CH_RXCFOK_CFG1_MSB, GTHE3_CH_RXCFOK_CFG1_LSB)
#define GTHE3_CH_RXDFE_H2_CFG0_ADDR 0x002F
#define GTHE3_CH_RXDFE_H2_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H2_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H2_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H2_CFG0_MSB, GTHE3_CH_RXDFE_H2_CFG0_LSB)
#define GTHE3_CH_RXDFE_H2_CFG1_ADDR 0x0030
#define GTHE3_CH_RXDFE_H2_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H2_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H2_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H2_CFG1_MSB, GTHE3_CH_RXDFE_H2_CFG1_LSB)
#define GTHE3_CH_RXCFOK_CFG2_ADDR 0x0031
#define GTHE3_CH_RXCFOK_CFG2_MSB 15
#define GTHE3_CH_RXCFOK_CFG2_LSB 0
#define GTHE3_CH_RXCFOK_CFG2_MASK BIT_MASK(GTHE3_CH_RXCFOK_CFG2_MSB, GTHE3_CH_RXCFOK_CFG2_LSB)
#define GTHE3_CH_RXLPM_CFG_ADDR 0x0032
#define GTHE3_CH_RXLPM_CFG_MSB 15
#define GTHE3_CH_RXLPM_CFG_LSB 0
#define GTHE3_CH_RXLPM_CFG_MASK BIT_MASK(GTHE3_CH_RXLPM_CFG_MSB, GTHE3_CH_RXLPM_CFG_LSB)
#define GTHE3_CH_RXLPM_KH_CFG0_ADDR 0x0033
#define GTHE3_CH_RXLPM_KH_CFG0_MSB 15
#define GTHE3_CH_RXLPM_KH_CFG0_LSB 0
#define GTHE3_CH_RXLPM_KH_CFG0_MASK BIT_MASK(GTHE3_CH_RXLPM_KH_CFG0_MSB, GTHE3_CH_RXLPM_KH_CFG0_LSB)
#define GTHE3_CH_RXLPM_KH_CFG1_ADDR 0x0034
#define GTHE3_CH_RXLPM_KH_CFG1_MSB 15
#define GTHE3_CH_RXLPM_KH_CFG1_LSB 0
#define GTHE3_CH_RXLPM_KH_CFG1_MASK BIT_MASK(GTHE3_CH_RXLPM_KH_CFG1_MSB, GTHE3_CH_RXLPM_KH_CFG1_LSB)
#define GTHE3_CH_RXDFELPM_KL_CFG0_ADDR 0x0035
#define GTHE3_CH_RXDFELPM_KL_CFG0_MSB 15
#define GTHE3_CH_RXDFELPM_KL_CFG0_LSB 0
#define GTHE3_CH_RXDFELPM_KL_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFELPM_KL_CFG0_MSB, GTHE3_CH_RXDFELPM_KL_CFG0_LSB)
#define GTHE3_CH_RXDFELPM_KL_CFG1_ADDR 0x0036
#define GTHE3_CH_RXDFELPM_KL_CFG1_MSB 15
#define GTHE3_CH_RXDFELPM_KL_CFG1_LSB 0
#define GTHE3_CH_RXDFELPM_KL_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFELPM_KL_CFG1_MSB, GTHE3_CH_RXDFELPM_KL_CFG1_LSB)
#define GTHE3_CH_RXLPM_OS_CFG0_ADDR 0x0037
#define GTHE3_CH_RXLPM_OS_CFG0_MSB 15
#define GTHE3_CH_RXLPM_OS_CFG0_LSB 0
#define GTHE3_CH_RXLPM_OS_CFG0_MASK BIT_MASK(GTHE3_CH_RXLPM_OS_CFG0_MSB, GTHE3_CH_RXLPM_OS_CFG0_LSB)
#define GTHE3_CH_RXLPM_OS_CFG1_ADDR 0x0038
#define GTHE3_CH_RXLPM_OS_CFG1_MSB 15
#define GTHE3_CH_RXLPM_OS_CFG1_LSB 0
#define GTHE3_CH_RXLPM_OS_CFG1_MASK BIT_MASK(GTHE3_CH_RXLPM_OS_CFG1_MSB, GTHE3_CH_RXLPM_OS_CFG1_LSB)
#define GTHE3_CH_RXLPM_GC_CFG_ADDR 0x0039
#define GTHE3_CH_RXLPM_GC_CFG_MSB 15
#define GTHE3_CH_RXLPM_GC_CFG_LSB 0
#define GTHE3_CH_RXLPM_GC_CFG_MASK BIT_MASK(GTHE3_CH_RXLPM_GC_CFG_MSB, GTHE3_CH_RXLPM_GC_CFG_LSB)
#define GTHE3_CH_DMONITOR_CFG1_ADDR 0x003A
#define GTHE3_CH_DMONITOR_CFG1_MSB 15
#define GTHE3_CH_DMONITOR_CFG1_LSB 8
#define GTHE3_CH_DMONITOR_CFG1_MASK BIT_MASK(GTHE3_CH_DMONITOR_CFG1_MSB, GTHE3_CH_DMONITOR_CFG1_LSB)
#define GTHE3_CH_ES_CONTROL_ADDR 0x003C
#define GTHE3_CH_ES_CONTROL_MSB 15
#define GTHE3_CH_ES_CONTROL_LSB 10
#define GTHE3_CH_ES_CONTROL_MASK BIT_MASK(GTHE3_CH_ES_CONTROL_MSB, GTHE3_CH_ES_CONTROL_LSB)
#define GTHE3_CH_ES_ERRDET_EN_ADDR 0x003C
#define GTHE3_CH_ES_ERRDET_EN_MSB 9
#define GTHE3_CH_ES_ERRDET_EN_LSB 9
#define GTHE3_CH_ES_ERRDET_EN_MASK BIT_MASK(GTHE3_CH_ES_ERRDET_EN_MSB, GTHE3_CH_ES_ERRDET_EN_LSB)
#define GTHE3_CH_ES_EYE_SCAN_EN_ADDR 0x003C
#define GTHE3_CH_ES_EYE_SCAN_EN_MSB 8
#define GTHE3_CH_ES_EYE_SCAN_EN_LSB 8
#define GTHE3_CH_ES_EYE_SCAN_EN_MASK BIT_MASK(GTHE3_CH_ES_EYE_SCAN_EN_MSB, GTHE3_CH_ES_EYE_SCAN_EN_LSB)
#define GTHE3_CH_ES_PRESCALE_ADDR 0x003C
#define GTHE3_CH_ES_PRESCALE_MSB 4
#define GTHE3_CH_ES_PRESCALE_LSB 0
#define GTHE3_CH_ES_PRESCALE_MASK BIT_MASK(GTHE3_CH_ES_PRESCALE_MSB, GTHE3_CH_ES_PRESCALE_LSB)
#define GTHE3_CH_RXDFE_HC_CFG0_ADDR 0x003D
#define GTHE3_CH_RXDFE_HC_CFG0_MSB 15
#define GTHE3_CH_RXDFE_HC_CFG0_LSB 0
#define GTHE3_CH_RXDFE_HC_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_HC_CFG0_MSB, GTHE3_CH_RXDFE_HC_CFG0_LSB)
#define GTHE3_CH_TX_PROGDIV_CFG_ADDR 0x003E
#define GTHE3_CH_TX_PROGDIV_CFG_MSB 15
#define GTHE3_CH_TX_PROGDIV_CFG_LSB 0
#define GTHE3_CH_TX_PROGDIV_CFG_MASK BIT_MASK(GTHE3_CH_TX_PROGDIV_CFG_MSB, GTHE3_CH_TX_PROGDIV_CFG_LSB)
#define GTHE3_CH_TX_PROGDIV_CFG_0 32768
#define GTHE3_CH_TX_PROGDIV_CFG_4 57744
#define GTHE3_CH_TX_PROGDIV_CFG_5 49648
#define GTHE3_CH_TX_PROGDIV_CFG_8 57728
#define GTHE3_CH_TX_PROGDIV_CFG_10 57760
#define GTHE3_CH_TX_PROGDIV_CFG_16 57730
#define GTHE3_CH_TX_PROGDIV_CFG_16P5 49672
#define GTHE3_CH_TX_PROGDIV_CFG_20 57762
#define GTHE3_CH_TX_PROGDIV_CFG_32 57734
#define GTHE3_CH_TX_PROGDIV_CFG_33 49800
#define GTHE3_CH_TX_PROGDIV_CFG_40 57766
#define GTHE3_CH_TX_PROGDIV_CFG_64 57742
#define GTHE3_CH_TX_PROGDIV_CFG_66 50056
#define GTHE3_CH_TX_PROGDIV_CFG_80 57743
#define GTHE3_CH_TX_PROGDIV_CFG_100 57775
#define GTHE3_CH_ES_QUALIFIER0_ADDR 0x003F
#define GTHE3_CH_ES_QUALIFIER0_MSB 15
#define GTHE3_CH_ES_QUALIFIER0_LSB 0
#define GTHE3_CH_ES_QUALIFIER0_MASK BIT_MASK(GTHE3_CH_ES_QUALIFIER0_MSB, GTHE3_CH_ES_QUALIFIER0_LSB)
#define GTHE3_CH_ES_QUALIFIER1_ADDR 0x0040
#define GTHE3_CH_ES_QUALIFIER1_MSB 15
#define GTHE3_CH_ES_QUALIFIER1_LSB 0
#define GTHE3_CH_ES_QUALIFIER1_MASK BIT_MASK(GTHE3_CH_ES_QUALIFIER1_MSB, GTHE3_CH_ES_QUALIFIER1_LSB)
#define GTHE3_CH_ES_QUALIFIER2_ADDR 0x0041
#define GTHE3_CH_ES_QUALIFIER2_MSB 15
#define GTHE3_CH_ES_QUALIFIER2_LSB 0
#define GTHE3_CH_ES_QUALIFIER2_MASK BIT_MASK(GTHE3_CH_ES_QUALIFIER2_MSB, GTHE3_CH_ES_QUALIFIER2_LSB)
#define GTHE3_CH_ES_QUALIFIER3_ADDR 0x0042
#define GTHE3_CH_ES_QUALIFIER3_MSB 15
#define GTHE3_CH_ES_QUALIFIER3_LSB 0
#define GTHE3_CH_ES_QUALIFIER3_MASK BIT_MASK(GTHE3_CH_ES_QUALIFIER3_MSB, GTHE3_CH_ES_QUALIFIER3_LSB)
#define GTHE3_CH_ES_QUALIFIER4_ADDR 0x0043
#define GTHE3_CH_ES_QUALIFIER4_MSB 15
#define GTHE3_CH_ES_QUALIFIER4_LSB 0
#define GTHE3_CH_ES_QUALIFIER4_MASK BIT_MASK(GTHE3_CH_ES_QUALIFIER4_MSB, GTHE3_CH_ES_QUALIFIER4_LSB)
#define GTHE3_CH_ES_QUAL_MASK0_ADDR 0x0044
#define GTHE3_CH_ES_QUAL_MASK0_MSB 15
#define GTHE3_CH_ES_QUAL_MASK0_LSB 0
#define GTHE3_CH_ES_QUAL_MASK0_MASK BIT_MASK(GTHE3_CH_ES_QUAL_MASK0_MSB, GTHE3_CH_ES_QUAL_MASK0_LSB)
#define GTHE3_CH_ES_QUAL_MASK1_ADDR 0x0045
#define GTHE3_CH_ES_QUAL_MASK1_MSB 15
#define GTHE3_CH_ES_QUAL_MASK1_LSB 0
#define GTHE3_CH_ES_QUAL_MASK1_MASK BIT_MASK(GTHE3_CH_ES_QUAL_MASK1_MSB, GTHE3_CH_ES_QUAL_MASK1_LSB)
#define GTHE3_CH_ES_QUAL_MASK2_ADDR 0x0046
#define GTHE3_CH_ES_QUAL_MASK2_MSB 15
#define GTHE3_CH_ES_QUAL_MASK2_LSB 0
#define GTHE3_CH_ES_QUAL_MASK2_MASK BIT_MASK(GTHE3_CH_ES_QUAL_MASK2_MSB, GTHE3_CH_ES_QUAL_MASK2_LSB)
#define GTHE3_CH_ES_QUAL_MASK3_ADDR 0x0047
#define GTHE3_CH_ES_QUAL_MASK3_MSB 15
#define GTHE3_CH_ES_QUAL_MASK3_LSB 0
#define GTHE3_CH_ES_QUAL_MASK3_MASK BIT_MASK(GTHE3_CH_ES_QUAL_MASK3_MSB, GTHE3_CH_ES_QUAL_MASK3_LSB)
#define GTHE3_CH_ES_QUAL_MASK4_ADDR 0x0048
#define GTHE3_CH_ES_QUAL_MASK4_MSB 15
#define GTHE3_CH_ES_QUAL_MASK4_LSB 0
#define GTHE3_CH_ES_QUAL_MASK4_MASK BIT_MASK(GTHE3_CH_ES_QUAL_MASK4_MSB, GTHE3_CH_ES_QUAL_MASK4_LSB)
#define GTHE3_CH_ES_SDATA_MASK0_ADDR 0x0049
#define GTHE3_CH_ES_SDATA_MASK0_MSB 15
#define GTHE3_CH_ES_SDATA_MASK0_LSB 0
#define GTHE3_CH_ES_SDATA_MASK0_MASK BIT_MASK(GTHE3_CH_ES_SDATA_MASK0_MSB, GTHE3_CH_ES_SDATA_MASK0_LSB)
#define GTHE3_CH_ES_SDATA_MASK1_ADDR 0x004A
#define GTHE3_CH_ES_SDATA_MASK1_MSB 15
#define GTHE3_CH_ES_SDATA_MASK1_LSB 0
#define GTHE3_CH_ES_SDATA_MASK1_MASK BIT_MASK(GTHE3_CH_ES_SDATA_MASK1_MSB, GTHE3_CH_ES_SDATA_MASK1_LSB)
#define GTHE3_CH_ES_SDATA_MASK2_ADDR 0x004B
#define GTHE3_CH_ES_SDATA_MASK2_MSB 15
#define GTHE3_CH_ES_SDATA_MASK2_LSB 0
#define GTHE3_CH_ES_SDATA_MASK2_MASK BIT_MASK(GTHE3_CH_ES_SDATA_MASK2_MSB, GTHE3_CH_ES_SDATA_MASK2_LSB)
#define GTHE3_CH_ES_SDATA_MASK3_ADDR 0x004C
#define GTHE3_CH_ES_SDATA_MASK3_MSB 15
#define GTHE3_CH_ES_SDATA_MASK3_LSB 0
#define GTHE3_CH_ES_SDATA_MASK3_MASK BIT_MASK(GTHE3_CH_ES_SDATA_MASK3_MSB, GTHE3_CH_ES_SDATA_MASK3_LSB)
#define GTHE3_CH_ES_SDATA_MASK4_ADDR 0x004D
#define GTHE3_CH_ES_SDATA_MASK4_MSB 15
#define GTHE3_CH_ES_SDATA_MASK4_LSB 0
#define GTHE3_CH_ES_SDATA_MASK4_MASK BIT_MASK(GTHE3_CH_ES_SDATA_MASK4_MSB, GTHE3_CH_ES_SDATA_MASK4_LSB)
#define GTHE3_CH_FTS_LANE_DESKEW_EN_ADDR 0x004E
#define GTHE3_CH_FTS_LANE_DESKEW_EN_MSB 4
#define GTHE3_CH_FTS_LANE_DESKEW_EN_LSB 4
#define GTHE3_CH_FTS_LANE_DESKEW_EN_MASK BIT_MASK(GTHE3_CH_FTS_LANE_DESKEW_EN_MSB, GTHE3_CH_FTS_LANE_DESKEW_EN_LSB)
#define GTHE3_CH_FTS_DESKEW_SEQ_ENABLE_ADDR 0x004E
#define GTHE3_CH_FTS_DESKEW_SEQ_ENABLE_MSB 3
#define GTHE3_CH_FTS_DESKEW_SEQ_ENABLE_LSB 0
#define GTHE3_CH_FTS_DESKEW_SEQ_ENABLE_MASK BIT_MASK(GTHE3_CH_FTS_DESKEW_SEQ_ENABLE_MSB, GTHE3_CH_FTS_DESKEW_SEQ_ENABLE_LSB)
#define GTHE3_CH_ES_HORZ_OFFSET_ADDR 0x004F
#define GTHE3_CH_ES_HORZ_OFFSET_MSB 15
#define GTHE3_CH_ES_HORZ_OFFSET_LSB 4
#define GTHE3_CH_ES_HORZ_OFFSET_MASK BIT_MASK(GTHE3_CH_ES_HORZ_OFFSET_MSB, GTHE3_CH_ES_HORZ_OFFSET_LSB)
#define GTHE3_CH_FTS_LANE_DESKEW_CFG_ADDR 0x004F
#define GTHE3_CH_FTS_LANE_DESKEW_CFG_MSB 3
#define GTHE3_CH_FTS_LANE_DESKEW_CFG_LSB 0
#define GTHE3_CH_FTS_LANE_DESKEW_CFG_MASK BIT_MASK(GTHE3_CH_FTS_LANE_DESKEW_CFG_MSB, GTHE3_CH_FTS_LANE_DESKEW_CFG_LSB)
#define GTHE3_CH_RXDFE_HC_CFG1_ADDR 0x0050
#define GTHE3_CH_RXDFE_HC_CFG1_MSB 15
#define GTHE3_CH_RXDFE_HC_CFG1_LSB 0
#define GTHE3_CH_RXDFE_HC_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_HC_CFG1_MSB, GTHE3_CH_RXDFE_HC_CFG1_LSB)
#define GTHE3_CH_ES_PMA_CFG_ADDR 0x0051
#define GTHE3_CH_ES_PMA_CFG_MSB 9
#define GTHE3_CH_ES_PMA_CFG_LSB 0
#define GTHE3_CH_ES_PMA_CFG_MASK BIT_MASK(GTHE3_CH_ES_PMA_CFG_MSB, GTHE3_CH_ES_PMA_CFG_LSB)
#define GTHE3_CH_RX_EN_HI_LR_ADDR 0x0052
#define GTHE3_CH_RX_EN_HI_LR_MSB 10
#define GTHE3_CH_RX_EN_HI_LR_LSB 10
#define GTHE3_CH_RX_EN_HI_LR_MASK BIT_MASK(GTHE3_CH_RX_EN_HI_LR_MSB, GTHE3_CH_RX_EN_HI_LR_LSB)
#define GTHE3_CH_RX_DFE_AGC_CFG1_ADDR 0x0052
#define GTHE3_CH_RX_DFE_AGC_CFG1_MSB 4
#define GTHE3_CH_RX_DFE_AGC_CFG1_LSB 2
#define GTHE3_CH_RX_DFE_AGC_CFG1_MASK BIT_MASK(GTHE3_CH_RX_DFE_AGC_CFG1_MSB, GTHE3_CH_RX_DFE_AGC_CFG1_LSB)
#define GTHE3_CH_RX_DFE_AGC_CFG0_ADDR 0x0052
#define GTHE3_CH_RX_DFE_AGC_CFG0_MSB 1
#define GTHE3_CH_RX_DFE_AGC_CFG0_LSB 0
#define GTHE3_CH_RX_DFE_AGC_CFG0_MASK BIT_MASK(GTHE3_CH_RX_DFE_AGC_CFG0_MSB, GTHE3_CH_RX_DFE_AGC_CFG0_LSB)
#define GTHE3_CH_RXDFE_CFG0_ADDR 0x0053
#define GTHE3_CH_RXDFE_CFG0_MSB 15
#define GTHE3_CH_RXDFE_CFG0_LSB 0
#define GTHE3_CH_RXDFE_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_CFG0_MSB, GTHE3_CH_RXDFE_CFG0_LSB)
#define GTHE3_CH_RXDFE_CFG1_ADDR 0x0054
#define GTHE3_CH_RXDFE_CFG1_MSB 15
#define GTHE3_CH_RXDFE_CFG1_LSB 0
#define GTHE3_CH_RXDFE_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_CFG1_MSB, GTHE3_CH_RXDFE_CFG1_LSB)
#define GTHE3_CH_LOCAL_MASTER_ADDR 0x0055
#define GTHE3_CH_LOCAL_MASTER_MSB 13
#define GTHE3_CH_LOCAL_MASTER_LSB 13
#define GTHE3_CH_LOCAL_MASTER_MASK BIT_MASK(GTHE3_CH_LOCAL_MASTER_MSB, GTHE3_CH_LOCAL_MASTER_LSB)
#define GTHE3_CH_PCS_PCIE_EN_ADDR 0x0055
#define GTHE3_CH_PCS_PCIE_EN_MSB 12
#define GTHE3_CH_PCS_PCIE_EN_LSB 12
#define GTHE3_CH_PCS_PCIE_EN_MASK BIT_MASK(GTHE3_CH_PCS_PCIE_EN_MSB, GTHE3_CH_PCS_PCIE_EN_LSB)
#define GTHE3_CH_ALIGN_MCOMMA_DET_ADDR 0x0055
#define GTHE3_CH_ALIGN_MCOMMA_DET_MSB 10
#define GTHE3_CH_ALIGN_MCOMMA_DET_LSB 10
#define GTHE3_CH_ALIGN_MCOMMA_DET_MASK BIT_MASK(GTHE3_CH_ALIGN_MCOMMA_DET_MSB, GTHE3_CH_ALIGN_MCOMMA_DET_LSB)
#define GTHE3_CH_ALIGN_MCOMMA_VALUE_ADDR 0x0055
#define GTHE3_CH_ALIGN_MCOMMA_VALUE_MSB 9
#define GTHE3_CH_ALIGN_MCOMMA_VALUE_LSB 0
#define GTHE3_CH_ALIGN_MCOMMA_VALUE_MASK BIT_MASK(GTHE3_CH_ALIGN_MCOMMA_VALUE_MSB, GTHE3_CH_ALIGN_MCOMMA_VALUE_LSB)
#define GTHE3_CH_ALIGN_PCOMMA_DET_ADDR 0x0056
#define GTHE3_CH_ALIGN_PCOMMA_DET_MSB 10
#define GTHE3_CH_ALIGN_PCOMMA_DET_LSB 10
#define GTHE3_CH_ALIGN_PCOMMA_DET_MASK BIT_MASK(GTHE3_CH_ALIGN_PCOMMA_DET_MSB, GTHE3_CH_ALIGN_PCOMMA_DET_LSB)
#define GTHE3_CH_ALIGN_PCOMMA_VALUE_ADDR 0x0056
#define GTHE3_CH_ALIGN_PCOMMA_VALUE_MSB 9
#define GTHE3_CH_ALIGN_PCOMMA_VALUE_LSB 0
#define GTHE3_CH_ALIGN_PCOMMA_VALUE_MASK BIT_MASK(GTHE3_CH_ALIGN_PCOMMA_VALUE_MSB, GTHE3_CH_ALIGN_PCOMMA_VALUE_LSB)
#define GTHE3_CH_TXDLY_LCFG_ADDR 0x0057
#define GTHE3_CH_TXDLY_LCFG_MSB 15
#define GTHE3_CH_TXDLY_LCFG_LSB 0
#define GTHE3_CH_TXDLY_LCFG_MASK BIT_MASK(GTHE3_CH_TXDLY_LCFG_MSB, GTHE3_CH_TXDLY_LCFG_LSB)
#define GTHE3_CH_RXDFE_OS_CFG0_ADDR 0x0058
#define GTHE3_CH_RXDFE_OS_CFG0_MSB 15
#define GTHE3_CH_RXDFE_OS_CFG0_LSB 0
#define GTHE3_CH_RXDFE_OS_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_OS_CFG0_MSB, GTHE3_CH_RXDFE_OS_CFG0_LSB)
#define GTHE3_CH_RXPHDLY_CFG_ADDR 0x0059
#define GTHE3_CH_RXPHDLY_CFG_MSB 15
#define GTHE3_CH_RXPHDLY_CFG_LSB 0
#define GTHE3_CH_RXPHDLY_CFG_MASK BIT_MASK(GTHE3_CH_RXPHDLY_CFG_MSB, GTHE3_CH_RXPHDLY_CFG_LSB)
#define GTHE3_CH_RXDFE_OS_CFG1_ADDR 0x005A
#define GTHE3_CH_RXDFE_OS_CFG1_MSB 15
#define GTHE3_CH_RXDFE_OS_CFG1_LSB 0
#define GTHE3_CH_RXDFE_OS_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_OS_CFG1_MSB, GTHE3_CH_RXDFE_OS_CFG1_LSB)
#define GTHE3_CH_RXDLY_CFG_ADDR 0x005B
#define GTHE3_CH_RXDLY_CFG_MSB 15
#define GTHE3_CH_RXDLY_CFG_LSB 0
#define GTHE3_CH_RXDLY_CFG_MASK BIT_MASK(GTHE3_CH_RXDLY_CFG_MSB, GTHE3_CH_RXDLY_CFG_LSB)
#define GTHE3_CH_RXDLY_LCFG_ADDR 0x005C
#define GTHE3_CH_RXDLY_LCFG_MSB 15
#define GTHE3_CH_RXDLY_LCFG_LSB 0
#define GTHE3_CH_RXDLY_LCFG_MASK BIT_MASK(GTHE3_CH_RXDLY_LCFG_MSB, GTHE3_CH_RXDLY_LCFG_LSB)
#define GTHE3_CH_RXDFE_HF_CFG0_ADDR 0x005D
#define GTHE3_CH_RXDFE_HF_CFG0_MSB 15
#define GTHE3_CH_RXDFE_HF_CFG0_LSB 0
#define GTHE3_CH_RXDFE_HF_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_HF_CFG0_MSB, GTHE3_CH_RXDFE_HF_CFG0_LSB)
#define GTHE3_CH_RXDFE_HD_CFG0_ADDR 0x005E
#define GTHE3_CH_RXDFE_HD_CFG0_MSB 15
#define GTHE3_CH_RXDFE_HD_CFG0_LSB 0
#define GTHE3_CH_RXDFE_HD_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_HD_CFG0_MSB, GTHE3_CH_RXDFE_HD_CFG0_LSB)
#define GTHE3_CH_RX_BIAS_CFG0_ADDR 0x005F
#define GTHE3_CH_RX_BIAS_CFG0_MSB 15
#define GTHE3_CH_RX_BIAS_CFG0_LSB 0
#define GTHE3_CH_RX_BIAS_CFG0_MASK BIT_MASK(GTHE3_CH_RX_BIAS_CFG0_MSB, GTHE3_CH_RX_BIAS_CFG0_LSB)
#define GTHE3_CH_PCS_RSVD0_ADDR 0x0060
#define GTHE3_CH_PCS_RSVD0_MSB 15
#define GTHE3_CH_PCS_RSVD0_LSB 0
#define GTHE3_CH_PCS_RSVD0_MASK BIT_MASK(GTHE3_CH_PCS_RSVD0_MSB, GTHE3_CH_PCS_RSVD0_LSB)
#define GTHE3_CH_RXPH_MONITOR_SEL_ADDR 0x0061
#define GTHE3_CH_RXPH_MONITOR_SEL_MSB 15
#define GTHE3_CH_RXPH_MONITOR_SEL_LSB 11
#define GTHE3_CH_RXPH_MONITOR_SEL_MASK BIT_MASK(GTHE3_CH_RXPH_MONITOR_SEL_MSB, GTHE3_CH_RXPH_MONITOR_SEL_LSB)
#define GTHE3_CH_RX_CM_BUF_PD_ADDR 0x0061
#define GTHE3_CH_RX_CM_BUF_PD_MSB 10
#define GTHE3_CH_RX_CM_BUF_PD_LSB 10
#define GTHE3_CH_RX_CM_BUF_PD_MASK BIT_MASK(GTHE3_CH_RX_CM_BUF_PD_MSB, GTHE3_CH_RX_CM_BUF_PD_LSB)
#define GTHE3_CH_RX_CM_BUF_CFG_ADDR 0x0061
#define GTHE3_CH_RX_CM_BUF_CFG_MSB 9
#define GTHE3_CH_RX_CM_BUF_CFG_LSB 6
#define GTHE3_CH_RX_CM_BUF_CFG_MASK BIT_MASK(GTHE3_CH_RX_CM_BUF_CFG_MSB, GTHE3_CH_RX_CM_BUF_CFG_LSB)
#define GTHE3_CH_RX_CM_TRIM_ADDR 0x0061
#define GTHE3_CH_RX_CM_TRIM_MSB 5
#define GTHE3_CH_RX_CM_TRIM_LSB 2
#define GTHE3_CH_RX_CM_TRIM_MASK BIT_MASK(GTHE3_CH_RX_CM_TRIM_MSB, GTHE3_CH_RX_CM_TRIM_LSB)
#define GTHE3_CH_RX_CM_SEL_ADDR 0x0061
#define GTHE3_CH_RX_CM_SEL_MSB 1
#define GTHE3_CH_RX_CM_SEL_LSB 0
#define GTHE3_CH_RX_CM_SEL_MASK BIT_MASK(GTHE3_CH_RX_CM_SEL_MSB, GTHE3_CH_RX_CM_SEL_LSB)
#define GTHE3_CH_RX_SUM_DFETAPREP_EN_ADDR 0x0062
#define GTHE3_CH_RX_SUM_DFETAPREP_EN_MSB 14
#define GTHE3_CH_RX_SUM_DFETAPREP_EN_LSB 14
#define GTHE3_CH_RX_SUM_DFETAPREP_EN_MASK BIT_MASK(GTHE3_CH_RX_SUM_DFETAPREP_EN_MSB, GTHE3_CH_RX_SUM_DFETAPREP_EN_LSB)
#define GTHE3_CH_RX_SUM_VCM_OVWR_ADDR 0x0062
#define GTHE3_CH_RX_SUM_VCM_OVWR_MSB 13
#define GTHE3_CH_RX_SUM_VCM_OVWR_LSB 13
#define GTHE3_CH_RX_SUM_VCM_OVWR_MASK BIT_MASK(GTHE3_CH_RX_SUM_VCM_OVWR_MSB, GTHE3_CH_RX_SUM_VCM_OVWR_LSB)
#define GTHE3_CH_RX_SUM_IREF_TUNE_ADDR 0x0062
#define GTHE3_CH_RX_SUM_IREF_TUNE_MSB 12
#define GTHE3_CH_RX_SUM_IREF_TUNE_LSB 9
#define GTHE3_CH_RX_SUM_IREF_TUNE_MASK BIT_MASK(GTHE3_CH_RX_SUM_IREF_TUNE_MSB, GTHE3_CH_RX_SUM_IREF_TUNE_LSB)
#define GTHE3_CH_RX_SUM_RES_CTRL_ADDR 0x0062
#define GTHE3_CH_RX_SUM_RES_CTRL_MSB 8
#define GTHE3_CH_RX_SUM_RES_CTRL_LSB 7
#define GTHE3_CH_RX_SUM_RES_CTRL_MASK BIT_MASK(GTHE3_CH_RX_SUM_RES_CTRL_MSB, GTHE3_CH_RX_SUM_RES_CTRL_LSB)
#define GTHE3_CH_RX_SUM_VCMTUNE_ADDR 0x0062
#define GTHE3_CH_RX_SUM_VCMTUNE_MSB 6
#define GTHE3_CH_RX_SUM_VCMTUNE_LSB 3
#define GTHE3_CH_RX_SUM_VCMTUNE_MASK BIT_MASK(GTHE3_CH_RX_SUM_VCMTUNE_MSB, GTHE3_CH_RX_SUM_VCMTUNE_LSB)
#define GTHE3_CH_RX_SUM_VREF_TUNE_ADDR 0x0062
#define GTHE3_CH_RX_SUM_VREF_TUNE_MSB 2
#define GTHE3_CH_RX_SUM_VREF_TUNE_LSB 0
#define GTHE3_CH_RX_SUM_VREF_TUNE_MASK BIT_MASK(GTHE3_CH_RX_SUM_VREF_TUNE_MSB, GTHE3_CH_RX_SUM_VREF_TUNE_LSB)
#define GTHE3_CH_CBCC_DATA_SOURCE_SEL_ADDR 0x0063
#define GTHE3_CH_CBCC_DATA_SOURCE_SEL_MSB 15
#define GTHE3_CH_CBCC_DATA_SOURCE_SEL_LSB 15
#define GTHE3_CH_CBCC_DATA_SOURCE_SEL_MASK BIT_MASK(GTHE3_CH_CBCC_DATA_SOURCE_SEL_MSB, GTHE3_CH_CBCC_DATA_SOURCE_SEL_LSB)
#define GTHE3_CH_CBCC_DATA_SOURCE_SEL_ENCODED 0
#define GTHE3_CH_CBCC_DATA_SOURCE_SEL_DECODED 1
#define GTHE3_CH_OOB_PWRUP_ADDR 0x0063
#define GTHE3_CH_OOB_PWRUP_MSB 14
#define GTHE3_CH_OOB_PWRUP_LSB 14
#define GTHE3_CH_OOB_PWRUP_MASK BIT_MASK(GTHE3_CH_OOB_PWRUP_MSB, GTHE3_CH_OOB_PWRUP_LSB)
#define GTHE3_CH_RXOOB_CFG_ADDR 0x0063
#define GTHE3_CH_RXOOB_CFG_MSB 13
#define GTHE3_CH_RXOOB_CFG_LSB 5
#define GTHE3_CH_RXOOB_CFG_MASK BIT_MASK(GTHE3_CH_RXOOB_CFG_MSB, GTHE3_CH_RXOOB_CFG_LSB)
#define GTHE3_CH_RXOUT_DIV_ADDR 0x0063
#define GTHE3_CH_RXOUT_DIV_MSB 2
#define GTHE3_CH_RXOUT_DIV_LSB 0
#define GTHE3_CH_RXOUT_DIV_MASK BIT_MASK(GTHE3_CH_RXOUT_DIV_MSB, GTHE3_CH_RXOUT_DIV_LSB)
#define GTHE3_CH_RXOUT_DIV_1 0
#define GTHE3_CH_RXOUT_DIV_2 1
#define GTHE3_CH_RXOUT_DIV_4 2
#define GTHE3_CH_RXOUT_DIV_8 3
#define GTHE3_CH_RXOUT_DIV_16 4
#define GTHE3_CH_RX_SIG_VALID_DLY_ADDR 0x0064
#define GTHE3_CH_RX_SIG_VALID_DLY_MSB 15
#define GTHE3_CH_RX_SIG_VALID_DLY_LSB 11
#define GTHE3_CH_RX_SIG_VALID_DLY_MASK BIT_MASK(GTHE3_CH_RX_SIG_VALID_DLY_MSB, GTHE3_CH_RX_SIG_VALID_DLY_LSB)
#define GTHE3_CH_RXSLIDE_MODE_ADDR 0x0064
#define GTHE3_CH_RXSLIDE_MODE_MSB 10
#define GTHE3_CH_RXSLIDE_MODE_LSB 9
#define GTHE3_CH_RXSLIDE_MODE_MASK BIT_MASK(GTHE3_CH_RXSLIDE_MODE_MSB, GTHE3_CH_RXSLIDE_MODE_LSB)
#define GTHE3_CH_RXSLIDE_MODE_OFF 0
#define GTHE3_CH_RXSLIDE_MODE_AUTO 1
#define GTHE3_CH_RXSLIDE_MODE_PCS 2
#define GTHE3_CH_RXSLIDE_MODE_PMA 3
#define GTHE3_CH_RXPRBS_ERR_LOOPBACK_ADDR 0x0064
#define GTHE3_CH_RXPRBS_ERR_LOOPBACK_MSB 8
#define GTHE3_CH_RXPRBS_ERR_LOOPBACK_LSB 8
#define GTHE3_CH_RXPRBS_ERR_LOOPBACK_MASK BIT_MASK(GTHE3_CH_RXPRBS_ERR_LOOPBACK_MSB, GTHE3_CH_RXPRBS_ERR_LOOPBACK_LSB)
#define GTHE3_CH_RXSLIDE_AUTO_WAIT_ADDR 0x0064
#define GTHE3_CH_RXSLIDE_AUTO_WAIT_MSB 7
#define GTHE3_CH_RXSLIDE_AUTO_WAIT_LSB 4
#define GTHE3_CH_RXSLIDE_AUTO_WAIT_MASK BIT_MASK(GTHE3_CH_RXSLIDE_AUTO_WAIT_MSB, GTHE3_CH_RXSLIDE_AUTO_WAIT_LSB)
#define GTHE3_CH_RXBUF_EN_ADDR 0x0064
#define GTHE3_CH_RXBUF_EN_MSB 3
#define GTHE3_CH_RXBUF_EN_LSB 3
#define GTHE3_CH_RXBUF_EN_MASK BIT_MASK(GTHE3_CH_RXBUF_EN_MSB, GTHE3_CH_RXBUF_EN_LSB)
#define GTHE3_CH_RX_XCLK_SEL_ADDR 0x0064
#define GTHE3_CH_RX_XCLK_SEL_MSB 2
#define GTHE3_CH_RX_XCLK_SEL_LSB 1
#define GTHE3_CH_RX_XCLK_SEL_MASK BIT_MASK(GTHE3_CH_RX_XCLK_SEL_MSB, GTHE3_CH_RX_XCLK_SEL_LSB)
#define GTHE3_CH_RX_XCLK_SEL_RXDES 0
#define GTHE3_CH_RX_XCLK_SEL_RXUSR 1
#define GTHE3_CH_RX_XCLK_SEL_RXPMA 2
#define GTHE3_CH_RXGEARBOX_EN_ADDR 0x0064
#define GTHE3_CH_RXGEARBOX_EN_MSB 0
#define GTHE3_CH_RXGEARBOX_EN_LSB 0
#define GTHE3_CH_RXGEARBOX_EN_MASK BIT_MASK(GTHE3_CH_RXGEARBOX_EN_MSB, GTHE3_CH_RXGEARBOX_EN_LSB)
#define GTHE3_CH_RXBUF_THRESH_OVFLW_ADDR 0x0065
#define GTHE3_CH_RXBUF_THRESH_OVFLW_MSB 15
#define GTHE3_CH_RXBUF_THRESH_OVFLW_LSB 10
#define GTHE3_CH_RXBUF_THRESH_OVFLW_MASK BIT_MASK(GTHE3_CH_RXBUF_THRESH_OVFLW_MSB, GTHE3_CH_RXBUF_THRESH_OVFLW_LSB)
#define GTHE3_CH_DMONITOR_CFG0_ADDR 0x0065
#define GTHE3_CH_DMONITOR_CFG0_MSB 9
#define GTHE3_CH_DMONITOR_CFG0_LSB 0
#define GTHE3_CH_DMONITOR_CFG0_MASK BIT_MASK(GTHE3_CH_DMONITOR_CFG0_MSB, GTHE3_CH_DMONITOR_CFG0_LSB)
#define GTHE3_CH_RXBUF_THRESH_OVRD_ADDR 0x0066
#define GTHE3_CH_RXBUF_THRESH_OVRD_MSB 15
#define GTHE3_CH_RXBUF_THRESH_OVRD_LSB 15
#define GTHE3_CH_RXBUF_THRESH_OVRD_MASK BIT_MASK(GTHE3_CH_RXBUF_THRESH_OVRD_MSB, GTHE3_CH_RXBUF_THRESH_OVRD_LSB)
#define GTHE3_CH_RXBUF_RESET_ON_COMMAALIGN_ADDR 0x0066
#define GTHE3_CH_RXBUF_RESET_ON_COMMAALIGN_MSB 14
#define GTHE3_CH_RXBUF_RESET_ON_COMMAALIGN_LSB 14
#define GTHE3_CH_RXBUF_RESET_ON_COMMAALIGN_MASK BIT_MASK(GTHE3_CH_RXBUF_RESET_ON_COMMAALIGN_MSB, GTHE3_CH_RXBUF_RESET_ON_COMMAALIGN_LSB)
#define GTHE3_CH_RXBUF_RESET_ON_RATE_CHANGE_ADDR 0x0066
#define GTHE3_CH_RXBUF_RESET_ON_RATE_CHANGE_MSB 13
#define GTHE3_CH_RXBUF_RESET_ON_RATE_CHANGE_LSB 13
#define GTHE3_CH_RXBUF_RESET_ON_RATE_CHANGE_MASK BIT_MASK(GTHE3_CH_RXBUF_RESET_ON_RATE_CHANGE_MSB, GTHE3_CH_RXBUF_RESET_ON_RATE_CHANGE_LSB)
#define GTHE3_CH_RXBUF_RESET_ON_CB_CHANGE_ADDR 0x0066
#define GTHE3_CH_RXBUF_RESET_ON_CB_CHANGE_MSB 12
#define GTHE3_CH_RXBUF_RESET_ON_CB_CHANGE_LSB 12
#define GTHE3_CH_RXBUF_RESET_ON_CB_CHANGE_MASK BIT_MASK(GTHE3_CH_RXBUF_RESET_ON_CB_CHANGE_MSB, GTHE3_CH_RXBUF_RESET_ON_CB_CHANGE_LSB)
#define GTHE3_CH_RXBUF_THRESH_UNDFLW_ADDR 0x0066
#define GTHE3_CH_RXBUF_THRESH_UNDFLW_MSB 11
#define GTHE3_CH_RXBUF_THRESH_UNDFLW_LSB 6
#define GTHE3_CH_RXBUF_THRESH_UNDFLW_MASK BIT_MASK(GTHE3_CH_RXBUF_THRESH_UNDFLW_MSB, GTHE3_CH_RXBUF_THRESH_UNDFLW_LSB)
#define GTHE3_CH_RX_CLKMUX_EN_ADDR 0x0066
#define GTHE3_CH_RX_CLKMUX_EN_MSB 5
#define GTHE3_CH_RX_CLKMUX_EN_LSB 5
#define GTHE3_CH_RX_CLKMUX_EN_MASK BIT_MASK(GTHE3_CH_RX_CLKMUX_EN_MSB, GTHE3_CH_RX_CLKMUX_EN_LSB)
#define GTHE3_CH_RX_DISPERR_SEQ_MATCH_ADDR 0x0066
#define GTHE3_CH_RX_DISPERR_SEQ_MATCH_MSB 4
#define GTHE3_CH_RX_DISPERR_SEQ_MATCH_LSB 4
#define GTHE3_CH_RX_DISPERR_SEQ_MATCH_MASK BIT_MASK(GTHE3_CH_RX_DISPERR_SEQ_MATCH_MSB, GTHE3_CH_RX_DISPERR_SEQ_MATCH_LSB)
#define GTHE3_CH_RXBUF_ADDR_MODE_ADDR 0x0066
#define GTHE3_CH_RXBUF_ADDR_MODE_MSB 3
#define GTHE3_CH_RXBUF_ADDR_MODE_LSB 3
#define GTHE3_CH_RXBUF_ADDR_MODE_MASK BIT_MASK(GTHE3_CH_RXBUF_ADDR_MODE_MSB, GTHE3_CH_RXBUF_ADDR_MODE_LSB)
#define GTHE3_CH_RX_WIDEMODE_CDR_ADDR 0x0066
#define GTHE3_CH_RX_WIDEMODE_CDR_MSB 2
#define GTHE3_CH_RX_WIDEMODE_CDR_LSB 2
#define GTHE3_CH_RX_WIDEMODE_CDR_MASK BIT_MASK(GTHE3_CH_RX_WIDEMODE_CDR_MSB, GTHE3_CH_RX_WIDEMODE_CDR_LSB)
#define GTHE3_CH_RX_INT_DATAWIDTH_ADDR 0x0066
#define GTHE3_CH_RX_INT_DATAWIDTH_MSB 1
#define GTHE3_CH_RX_INT_DATAWIDTH_LSB 0
#define GTHE3_CH_RX_INT_DATAWIDTH_MASK BIT_MASK(GTHE3_CH_RX_INT_DATAWIDTH_MSB, GTHE3_CH_RX_INT_DATAWIDTH_LSB)
#define GTHE3_CH_RXBUF_EIDLE_HI_CNT_ADDR 0x0067
#define GTHE3_CH_RXBUF_EIDLE_HI_CNT_MSB 15
#define GTHE3_CH_RXBUF_EIDLE_HI_CNT_LSB 12
#define GTHE3_CH_RXBUF_EIDLE_HI_CNT_MASK BIT_MASK(GTHE3_CH_RXBUF_EIDLE_HI_CNT_MSB, GTHE3_CH_RXBUF_EIDLE_HI_CNT_LSB)
#define GTHE3_CH_RXCDR_HOLD_DURING_EIDLE_ADDR 0x0067
#define GTHE3_CH_RXCDR_HOLD_DURING_EIDLE_MSB 11
#define GTHE3_CH_RXCDR_HOLD_DURING_EIDLE_LSB 11
#define GTHE3_CH_RXCDR_HOLD_DURING_EIDLE_MASK BIT_MASK(GTHE3_CH_RXCDR_HOLD_DURING_EIDLE_MSB, GTHE3_CH_RXCDR_HOLD_DURING_EIDLE_LSB)
#define GTHE3_CH_RX_DFE_LPM_HOLD_DURING_EIDLE_ADDR 0x0067
#define GTHE3_CH_RX_DFE_LPM_HOLD_DURING_EIDLE_MSB 10
#define GTHE3_CH_RX_DFE_LPM_HOLD_DURING_EIDLE_LSB 10
#define GTHE3_CH_RX_DFE_LPM_HOLD_DURING_EIDLE_MASK BIT_MASK(GTHE3_CH_RX_DFE_LPM_HOLD_DURING_EIDLE_MSB, GTHE3_CH_RX_DFE_LPM_HOLD_DURING_EIDLE_LSB)
#define GTHE3_CH_RXBUF_EIDLE_LO_CNT_ADDR 0x0067
#define GTHE3_CH_RXBUF_EIDLE_LO_CNT_MSB 7
#define GTHE3_CH_RXBUF_EIDLE_LO_CNT_LSB 4
#define GTHE3_CH_RXBUF_EIDLE_LO_CNT_MASK BIT_MASK(GTHE3_CH_RXBUF_EIDLE_LO_CNT_MSB, GTHE3_CH_RXBUF_EIDLE_LO_CNT_LSB)
#define GTHE3_CH_RXBUF_RESET_ON_EIDLE_ADDR 0x0067
#define GTHE3_CH_RXBUF_RESET_ON_EIDLE_MSB 3
#define GTHE3_CH_RXBUF_RESET_ON_EIDLE_LSB 3
#define GTHE3_CH_RXBUF_RESET_ON_EIDLE_MASK BIT_MASK(GTHE3_CH_RXBUF_RESET_ON_EIDLE_MSB, GTHE3_CH_RXBUF_RESET_ON_EIDLE_LSB)
#define GTHE3_CH_RXCDR_FR_RESET_ON_EIDLE_ADDR 0x0067
#define GTHE3_CH_RXCDR_FR_RESET_ON_EIDLE_MSB 2
#define GTHE3_CH_RXCDR_FR_RESET_ON_EIDLE_LSB 2
#define GTHE3_CH_RXCDR_FR_RESET_ON_EIDLE_MASK BIT_MASK(GTHE3_CH_RXCDR_FR_RESET_ON_EIDLE_MSB, GTHE3_CH_RXCDR_FR_RESET_ON_EIDLE_LSB)
#define GTHE3_CH_RXCDR_PH_RESET_ON_EIDLE_ADDR 0x0067
#define GTHE3_CH_RXCDR_PH_RESET_ON_EIDLE_MSB 1
#define GTHE3_CH_RXCDR_PH_RESET_ON_EIDLE_LSB 1
#define GTHE3_CH_RXCDR_PH_RESET_ON_EIDLE_MASK BIT_MASK(GTHE3_CH_RXCDR_PH_RESET_ON_EIDLE_MSB, GTHE3_CH_RXCDR_PH_RESET_ON_EIDLE_LSB)
#define GTHE3_CH_SATA_BURST_VAL_ADDR 0x0068
#define GTHE3_CH_SATA_BURST_VAL_MSB 15
#define GTHE3_CH_SATA_BURST_VAL_LSB 13
#define GTHE3_CH_SATA_BURST_VAL_MASK BIT_MASK(GTHE3_CH_SATA_BURST_VAL_MSB, GTHE3_CH_SATA_BURST_VAL_LSB)
#define GTHE3_CH_SATA_BURST_SEQ_LEN_ADDR 0x0068
#define GTHE3_CH_SATA_BURST_SEQ_LEN_MSB 7
#define GTHE3_CH_SATA_BURST_SEQ_LEN_LSB 4
#define GTHE3_CH_SATA_BURST_SEQ_LEN_MASK BIT_MASK(GTHE3_CH_SATA_BURST_SEQ_LEN_MSB, GTHE3_CH_SATA_BURST_SEQ_LEN_LSB)
#define GTHE3_CH_SATA_EIDLE_VAL_ADDR 0x0068
#define GTHE3_CH_SATA_EIDLE_VAL_MSB 2
#define GTHE3_CH_SATA_EIDLE_VAL_LSB 0
#define GTHE3_CH_SATA_EIDLE_VAL_MASK BIT_MASK(GTHE3_CH_SATA_EIDLE_VAL_MSB, GTHE3_CH_SATA_EIDLE_VAL_LSB)
#define GTHE3_CH_SATA_MIN_BURST_ADDR 0x0069
#define GTHE3_CH_SATA_MIN_BURST_MSB 15
#define GTHE3_CH_SATA_MIN_BURST_LSB 10
#define GTHE3_CH_SATA_MIN_BURST_MASK BIT_MASK(GTHE3_CH_SATA_MIN_BURST_MSB, GTHE3_CH_SATA_MIN_BURST_LSB)
#define GTHE3_CH_SAS_MIN_COM_ADDR 0x0069
#define GTHE3_CH_SAS_MIN_COM_MSB 6
#define GTHE3_CH_SAS_MIN_COM_LSB 1
#define GTHE3_CH_SAS_MIN_COM_MASK BIT_MASK(GTHE3_CH_SAS_MIN_COM_MSB, GTHE3_CH_SAS_MIN_COM_LSB)
#define GTHE3_CH_SATA_MIN_INIT_ADDR 0x006A
#define GTHE3_CH_SATA_MIN_INIT_MSB 15
#define GTHE3_CH_SATA_MIN_INIT_LSB 10
#define GTHE3_CH_SATA_MIN_INIT_MASK BIT_MASK(GTHE3_CH_SATA_MIN_INIT_MSB, GTHE3_CH_SATA_MIN_INIT_LSB)
#define GTHE3_CH_SATA_MIN_WAKE_ADDR 0x006A
#define GTHE3_CH_SATA_MIN_WAKE_MSB 6
#define GTHE3_CH_SATA_MIN_WAKE_LSB 1
#define GTHE3_CH_SATA_MIN_WAKE_MASK BIT_MASK(GTHE3_CH_SATA_MIN_WAKE_MSB, GTHE3_CH_SATA_MIN_WAKE_LSB)
#define GTHE3_CH_SATA_MAX_BURST_ADDR 0x006B
#define GTHE3_CH_SATA_MAX_BURST_MSB 15
#define GTHE3_CH_SATA_MAX_BURST_LSB 10
#define GTHE3_CH_SATA_MAX_BURST_MASK BIT_MASK(GTHE3_CH_SATA_MAX_BURST_MSB, GTHE3_CH_SATA_MAX_BURST_LSB)
#define GTHE3_CH_SAS_MAX_COM_ADDR 0x006B
#define GTHE3_CH_SAS_MAX_COM_MSB 6
#define GTHE3_CH_SAS_MAX_COM_LSB 0
#define GTHE3_CH_SAS_MAX_COM_MASK BIT_MASK(GTHE3_CH_SAS_MAX_COM_MSB, GTHE3_CH_SAS_MAX_COM_LSB)
#define GTHE3_CH_SATA_MAX_INIT_ADDR 0x006C
#define GTHE3_CH_SATA_MAX_INIT_MSB 15
#define GTHE3_CH_SATA_MAX_INIT_LSB 10
#define GTHE3_CH_SATA_MAX_INIT_MASK BIT_MASK(GTHE3_CH_SATA_MAX_INIT_MSB, GTHE3_CH_SATA_MAX_INIT_LSB)
#define GTHE3_CH_SATA_MAX_WAKE_ADDR 0x006C
#define GTHE3_CH_SATA_MAX_WAKE_MSB 6
#define GTHE3_CH_SATA_MAX_WAKE_LSB 1
#define GTHE3_CH_SATA_MAX_WAKE_MASK BIT_MASK(GTHE3_CH_SATA_MAX_WAKE_MSB, GTHE3_CH_SATA_MAX_WAKE_LSB)
#define GTHE3_CH_RX_CLK25_DIV_ADDR 0x006D
#define GTHE3_CH_RX_CLK25_DIV_MSB 7
#define GTHE3_CH_RX_CLK25_DIV_LSB 3
#define GTHE3_CH_RX_CLK25_DIV_MASK BIT_MASK(GTHE3_CH_RX_CLK25_DIV_MSB, GTHE3_CH_RX_CLK25_DIV_LSB)
#define GTHE3_CH_TXPHDLY_CFG0_ADDR 0x006E
#define GTHE3_CH_TXPHDLY_CFG0_MSB 15
#define GTHE3_CH_TXPHDLY_CFG0_LSB 0
#define GTHE3_CH_TXPHDLY_CFG0_MASK BIT_MASK(GTHE3_CH_TXPHDLY_CFG0_MSB, GTHE3_CH_TXPHDLY_CFG0_LSB)
#define GTHE3_CH_TXPHDLY_CFG1_ADDR 0x006F
#define GTHE3_CH_TXPHDLY_CFG1_MSB 15
#define GTHE3_CH_TXPHDLY_CFG1_LSB 0
#define GTHE3_CH_TXPHDLY_CFG1_MASK BIT_MASK(GTHE3_CH_TXPHDLY_CFG1_MSB, GTHE3_CH_TXPHDLY_CFG1_LSB)
#define GTHE3_CH_TXDLY_CFG_ADDR 0x0070
#define GTHE3_CH_TXDLY_CFG_MSB 15
#define GTHE3_CH_TXDLY_CFG_LSB 0
#define GTHE3_CH_TXDLY_CFG_MASK BIT_MASK(GTHE3_CH_TXDLY_CFG_MSB, GTHE3_CH_TXDLY_CFG_LSB)
#define GTHE3_CH_TXPH_MONITOR_SEL_ADDR 0x0071
#define GTHE3_CH_TXPH_MONITOR_SEL_MSB 6
#define GTHE3_CH_TXPH_MONITOR_SEL_LSB 2
#define GTHE3_CH_TXPH_MONITOR_SEL_MASK BIT_MASK(GTHE3_CH_TXPH_MONITOR_SEL_MSB, GTHE3_CH_TXPH_MONITOR_SEL_LSB)
#define GTHE3_CH_TAPDLY_SET_TX_ADDR 0x0071
#define GTHE3_CH_TAPDLY_SET_TX_MSB 1
#define GTHE3_CH_TAPDLY_SET_TX_LSB 0
#define GTHE3_CH_TAPDLY_SET_TX_MASK BIT_MASK(GTHE3_CH_TAPDLY_SET_TX_MSB, GTHE3_CH_TAPDLY_SET_TX_LSB)
#define GTHE3_CH_RXCDR_LOCK_CFG2_ADDR 0x0072
#define GTHE3_CH_RXCDR_LOCK_CFG2_MSB 15
#define GTHE3_CH_RXCDR_LOCK_CFG2_LSB 0
#define GTHE3_CH_RXCDR_LOCK_CFG2_MASK BIT_MASK(GTHE3_CH_RXCDR_LOCK_CFG2_MSB, GTHE3_CH_RXCDR_LOCK_CFG2_LSB)
#define GTHE3_CH_TXPH_CFG_ADDR 0x0073
#define GTHE3_CH_TXPH_CFG_MSB 15
#define GTHE3_CH_TXPH_CFG_LSB 0
#define GTHE3_CH_TXPH_CFG_MASK BIT_MASK(GTHE3_CH_TXPH_CFG_MSB, GTHE3_CH_TXPH_CFG_LSB)
#define GTHE3_CH_TERM_RCAL_CFG_ADDR 0x0074
#define GTHE3_CH_TERM_RCAL_CFG_MSB 14
#define GTHE3_CH_TERM_RCAL_CFG_LSB 0
#define GTHE3_CH_TERM_RCAL_CFG_MASK BIT_MASK(GTHE3_CH_TERM_RCAL_CFG_MSB, GTHE3_CH_TERM_RCAL_CFG_LSB)
#define GTHE3_CH_RXDFE_HF_CFG1_ADDR 0x0075
#define GTHE3_CH_RXDFE_HF_CFG1_MSB 15
#define GTHE3_CH_RXDFE_HF_CFG1_LSB 0
#define GTHE3_CH_RXDFE_HF_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_HF_CFG1_MSB, GTHE3_CH_RXDFE_HF_CFG1_LSB)
#define GTHE3_CH_PD_TRANS_TIME_FROM_P2_ADDR 0x0076
#define GTHE3_CH_PD_TRANS_TIME_FROM_P2_MSB 15
#define GTHE3_CH_PD_TRANS_TIME_FROM_P2_LSB 4
#define GTHE3_CH_PD_TRANS_TIME_FROM_P2_MASK BIT_MASK(GTHE3_CH_PD_TRANS_TIME_FROM_P2_MSB, GTHE3_CH_PD_TRANS_TIME_FROM_P2_LSB)
#define GTHE3_CH_TERM_RCAL_OVRD_ADDR 0x0076
#define GTHE3_CH_TERM_RCAL_OVRD_MSB 3
#define GTHE3_CH_TERM_RCAL_OVRD_LSB 1
#define GTHE3_CH_TERM_RCAL_OVRD_MASK BIT_MASK(GTHE3_CH_TERM_RCAL_OVRD_MSB, GTHE3_CH_TERM_RCAL_OVRD_LSB)
#define GTHE3_CH_PD_TRANS_TIME_NONE_P2_ADDR 0x0077
#define GTHE3_CH_PD_TRANS_TIME_NONE_P2_MSB 15
#define GTHE3_CH_PD_TRANS_TIME_NONE_P2_LSB 8
#define GTHE3_CH_PD_TRANS_TIME_NONE_P2_MASK BIT_MASK(GTHE3_CH_PD_TRANS_TIME_NONE_P2_MSB, GTHE3_CH_PD_TRANS_TIME_NONE_P2_LSB)
#define GTHE3_CH_PD_TRANS_TIME_TO_P2_ADDR 0x0077
#define GTHE3_CH_PD_TRANS_TIME_TO_P2_MSB 7
#define GTHE3_CH_PD_TRANS_TIME_TO_P2_LSB 0
#define GTHE3_CH_PD_TRANS_TIME_TO_P2_MASK BIT_MASK(GTHE3_CH_PD_TRANS_TIME_TO_P2_MSB, GTHE3_CH_PD_TRANS_TIME_TO_P2_LSB)
#define GTHE3_CH_TRANS_TIME_RATE_ADDR 0x0078
#define GTHE3_CH_TRANS_TIME_RATE_MSB 15
#define GTHE3_CH_TRANS_TIME_RATE_LSB 8
#define GTHE3_CH_TRANS_TIME_RATE_MASK BIT_MASK(GTHE3_CH_TRANS_TIME_RATE_MSB, GTHE3_CH_TRANS_TIME_RATE_LSB)
#define GTHE3_CH_TST_RSV0_ADDR 0x0079
#define GTHE3_CH_TST_RSV0_MSB 15
#define GTHE3_CH_TST_RSV0_LSB 8
#define GTHE3_CH_TST_RSV0_MASK BIT_MASK(GTHE3_CH_TST_RSV0_MSB, GTHE3_CH_TST_RSV0_LSB)
#define GTHE3_CH_TST_RSV1_ADDR 0x0079
#define GTHE3_CH_TST_RSV1_MSB 7
#define GTHE3_CH_TST_RSV1_LSB 0
#define GTHE3_CH_TST_RSV1_MASK BIT_MASK(GTHE3_CH_TST_RSV1_MSB, GTHE3_CH_TST_RSV1_LSB)
#define GTHE3_CH_TX_CLK25_DIV_ADDR 0x007A
#define GTHE3_CH_TX_CLK25_DIV_MSB 15
#define GTHE3_CH_TX_CLK25_DIV_LSB 11
#define GTHE3_CH_TX_CLK25_DIV_MASK BIT_MASK(GTHE3_CH_TX_CLK25_DIV_MSB, GTHE3_CH_TX_CLK25_DIV_LSB)
#define GTHE3_CH_TX_XCLK_SEL_ADDR 0x007A
#define GTHE3_CH_TX_XCLK_SEL_MSB 10
#define GTHE3_CH_TX_XCLK_SEL_LSB 10
#define GTHE3_CH_TX_XCLK_SEL_MASK BIT_MASK(GTHE3_CH_TX_XCLK_SEL_MSB, GTHE3_CH_TX_XCLK_SEL_LSB)
#define GTHE3_CH_TX_XCLK_SEL_TXOUT 0
#define GTHE3_CH_TX_XCLK_SEL_TXUSR 1
#define GTHE3_CH_TX_DATA_WIDTH_ADDR 0x007A
#define GTHE3_CH_TX_DATA_WIDTH_MSB 3
#define GTHE3_CH_TX_DATA_WIDTH_LSB 0
#define GTHE3_CH_TX_DATA_WIDTH_MASK BIT_MASK(GTHE3_CH_TX_DATA_WIDTH_MSB, GTHE3_CH_TX_DATA_WIDTH_LSB)
#define GTHE3_CH_TX_DATA_WIDTH_16 2
#define GTHE3_CH_TX_DATA_WIDTH_20 3
#define GTHE3_CH_TX_DATA_WIDTH_32 4
#define GTHE3_CH_TX_DATA_WIDTH_40 5
#define GTHE3_CH_TX_DATA_WIDTH_64 6
#define GTHE3_CH_TX_DATA_WIDTH_80 7
#define GTHE3_CH_TX_DATA_WIDTH_128 8
#define GTHE3_CH_TX_DATA_WIDTH_160 9
#define GTHE3_CH_TX_DEEMPH0_ADDR 0x007B
#define GTHE3_CH_TX_DEEMPH0_MSB 15
#define GTHE3_CH_TX_DEEMPH0_LSB 10
#define GTHE3_CH_TX_DEEMPH0_MASK BIT_MASK(GTHE3_CH_TX_DEEMPH0_MSB, GTHE3_CH_TX_DEEMPH0_LSB)
#define GTHE3_CH_TX_DEEMPH1_ADDR 0x007B
#define GTHE3_CH_TX_DEEMPH1_MSB 7
#define GTHE3_CH_TX_DEEMPH1_LSB 2
#define GTHE3_CH_TX_DEEMPH1_MASK BIT_MASK(GTHE3_CH_TX_DEEMPH1_MSB, GTHE3_CH_TX_DEEMPH1_LSB)
#define GTHE3_CH_TX_MAINCURSOR_SEL_ADDR 0x007C
#define GTHE3_CH_TX_MAINCURSOR_SEL_MSB 14
#define GTHE3_CH_TX_MAINCURSOR_SEL_LSB 14
#define GTHE3_CH_TX_MAINCURSOR_SEL_MASK BIT_MASK(GTHE3_CH_TX_MAINCURSOR_SEL_MSB, GTHE3_CH_TX_MAINCURSOR_SEL_LSB)
#define GTHE3_CH_TXGEARBOX_EN_ADDR 0x007C
#define GTHE3_CH_TXGEARBOX_EN_MSB 13
#define GTHE3_CH_TXGEARBOX_EN_LSB 13
#define GTHE3_CH_TXGEARBOX_EN_MASK BIT_MASK(GTHE3_CH_TXGEARBOX_EN_MSB, GTHE3_CH_TXGEARBOX_EN_LSB)
#define GTHE3_CH_TXOUT_DIV_ADDR 0x007C
#define GTHE3_CH_TXOUT_DIV_MSB 10
#define GTHE3_CH_TXOUT_DIV_LSB 8
#define GTHE3_CH_TXOUT_DIV_MASK BIT_MASK(GTHE3_CH_TXOUT_DIV_MSB, GTHE3_CH_TXOUT_DIV_LSB)
#define GTHE3_CH_TXOUT_DIV_1 0
#define GTHE3_CH_TXOUT_DIV_2 1
#define GTHE3_CH_TXOUT_DIV_4 2
#define GTHE3_CH_TXOUT_DIV_8 3
#define GTHE3_CH_TXOUT_DIV_16 4
#define GTHE3_CH_TXBUF_EN_ADDR 0x007C
#define GTHE3_CH_TXBUF_EN_MSB 7
#define GTHE3_CH_TXBUF_EN_LSB 7
#define GTHE3_CH_TXBUF_EN_MASK BIT_MASK(GTHE3_CH_TXBUF_EN_MSB, GTHE3_CH_TXBUF_EN_LSB)
#define GTHE3_CH_TXBUF_RESET_ON_RATE_CHANGE_ADDR 0x007C
#define GTHE3_CH_TXBUF_RESET_ON_RATE_CHANGE_MSB 6
#define GTHE3_CH_TXBUF_RESET_ON_RATE_CHANGE_LSB 6
#define GTHE3_CH_TXBUF_RESET_ON_RATE_CHANGE_MASK BIT_MASK(GTHE3_CH_TXBUF_RESET_ON_RATE_CHANGE_MSB, GTHE3_CH_TXBUF_RESET_ON_RATE_CHANGE_LSB)
#define GTHE3_CH_TX_RXDETECT_REF_ADDR 0x007C
#define GTHE3_CH_TX_RXDETECT_REF_MSB 5
#define GTHE3_CH_TX_RXDETECT_REF_LSB 3
#define GTHE3_CH_TX_RXDETECT_REF_MASK BIT_MASK(GTHE3_CH_TX_RXDETECT_REF_MSB, GTHE3_CH_TX_RXDETECT_REF_LSB)
#define GTHE3_CH_TXFIFO_ADDR_CFG_ADDR 0x007C
#define GTHE3_CH_TXFIFO_ADDR_CFG_MSB 2
#define GTHE3_CH_TXFIFO_ADDR_CFG_LSB 2
#define GTHE3_CH_TXFIFO_ADDR_CFG_MASK BIT_MASK(GTHE3_CH_TXFIFO_ADDR_CFG_MSB, GTHE3_CH_TXFIFO_ADDR_CFG_LSB)
#define GTHE3_CH_TXFIFO_ADDR_CFG_LOW 0
#define GTHE3_CH_TXFIFO_ADDR_CFG_HIGH 1
#define GTHE3_CH_TX_RXDETECT_CFG_ADDR 0x007D
#define GTHE3_CH_TX_RXDETECT_CFG_MSB 15
#define GTHE3_CH_TX_RXDETECT_CFG_LSB 2
#define GTHE3_CH_TX_RXDETECT_CFG_MASK BIT_MASK(GTHE3_CH_TX_RXDETECT_CFG_MSB, GTHE3_CH_TX_RXDETECT_CFG_LSB)
#define GTHE3_CH_TX_CLKMUX_EN_ADDR 0x007E
#define GTHE3_CH_TX_CLKMUX_EN_MSB 15
#define GTHE3_CH_TX_CLKMUX_EN_LSB 15
#define GTHE3_CH_TX_CLKMUX_EN_MASK BIT_MASK(GTHE3_CH_TX_CLKMUX_EN_MSB, GTHE3_CH_TX_CLKMUX_EN_LSB)
#define GTHE3_CH_TX_LOOPBACK_DRIVE_HIZ_ADDR 0x007E
#define GTHE3_CH_TX_LOOPBACK_DRIVE_HIZ_MSB 14
#define GTHE3_CH_TX_LOOPBACK_DRIVE_HIZ_LSB 14
#define GTHE3_CH_TX_LOOPBACK_DRIVE_HIZ_MASK BIT_MASK(GTHE3_CH_TX_LOOPBACK_DRIVE_HIZ_MSB, GTHE3_CH_TX_LOOPBACK_DRIVE_HIZ_LSB)
#define GTHE3_CH_TX_DRIVE_MODE_ADDR 0x007E
#define GTHE3_CH_TX_DRIVE_MODE_MSB 12
#define GTHE3_CH_TX_DRIVE_MODE_LSB 8
#define GTHE3_CH_TX_DRIVE_MODE_MASK BIT_MASK(GTHE3_CH_TX_DRIVE_MODE_MSB, GTHE3_CH_TX_DRIVE_MODE_LSB)
#define GTHE3_CH_TX_DRIVE_MODE_DIRECT 0
#define GTHE3_CH_TX_DRIVE_MODE_PIPE 1
#define GTHE3_CH_TX_DRIVE_MODE_PIPEGEN3 2
#define GTHE3_CH_TX_EIDLE_ASSERT_DELAY_ADDR 0x007E
#define GTHE3_CH_TX_EIDLE_ASSERT_DELAY_MSB 7
#define GTHE3_CH_TX_EIDLE_ASSERT_DELAY_LSB 5
#define GTHE3_CH_TX_EIDLE_ASSERT_DELAY_MASK BIT_MASK(GTHE3_CH_TX_EIDLE_ASSERT_DELAY_MSB, GTHE3_CH_TX_EIDLE_ASSERT_DELAY_LSB)
#define GTHE3_CH_TX_EIDLE_DEASSERT_DELAY_ADDR 0x007E
#define GTHE3_CH_TX_EIDLE_DEASSERT_DELAY_MSB 4
#define GTHE3_CH_TX_EIDLE_DEASSERT_DELAY_LSB 2
#define GTHE3_CH_TX_EIDLE_DEASSERT_DELAY_MASK BIT_MASK(GTHE3_CH_TX_EIDLE_DEASSERT_DELAY_MSB, GTHE3_CH_TX_EIDLE_DEASSERT_DELAY_LSB)
#define GTHE3_CH_TX_MARGIN_FULL_0_ADDR 0x007F
#define GTHE3_CH_TX_MARGIN_FULL_0_MSB 15
#define GTHE3_CH_TX_MARGIN_FULL_0_LSB 9
#define GTHE3_CH_TX_MARGIN_FULL_0_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_FULL_0_MSB, GTHE3_CH_TX_MARGIN_FULL_0_LSB)
#define GTHE3_CH_TX_MARGIN_FULL_1_ADDR 0x007F
#define GTHE3_CH_TX_MARGIN_FULL_1_MSB 7
#define GTHE3_CH_TX_MARGIN_FULL_1_LSB 1
#define GTHE3_CH_TX_MARGIN_FULL_1_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_FULL_1_MSB, GTHE3_CH_TX_MARGIN_FULL_1_LSB)
#define GTHE3_CH_TX_MARGIN_FULL_2_ADDR 0x0080
#define GTHE3_CH_TX_MARGIN_FULL_2_MSB 15
#define GTHE3_CH_TX_MARGIN_FULL_2_LSB 9
#define GTHE3_CH_TX_MARGIN_FULL_2_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_FULL_2_MSB, GTHE3_CH_TX_MARGIN_FULL_2_LSB)
#define GTHE3_CH_TX_MARGIN_FULL_3_ADDR 0x0080
#define GTHE3_CH_TX_MARGIN_FULL_3_MSB 7
#define GTHE3_CH_TX_MARGIN_FULL_3_LSB 1
#define GTHE3_CH_TX_MARGIN_FULL_3_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_FULL_3_MSB, GTHE3_CH_TX_MARGIN_FULL_3_LSB)
#define GTHE3_CH_TX_MARGIN_FULL_4_ADDR 0x0081
#define GTHE3_CH_TX_MARGIN_FULL_4_MSB 15
#define GTHE3_CH_TX_MARGIN_FULL_4_LSB 9
#define GTHE3_CH_TX_MARGIN_FULL_4_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_FULL_4_MSB, GTHE3_CH_TX_MARGIN_FULL_4_LSB)
#define GTHE3_CH_TX_MARGIN_LOW_0_ADDR 0x0081
#define GTHE3_CH_TX_MARGIN_LOW_0_MSB 7
#define GTHE3_CH_TX_MARGIN_LOW_0_LSB 1
#define GTHE3_CH_TX_MARGIN_LOW_0_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_LOW_0_MSB, GTHE3_CH_TX_MARGIN_LOW_0_LSB)
#define GTHE3_CH_TX_MARGIN_LOW_1_ADDR 0x0082
#define GTHE3_CH_TX_MARGIN_LOW_1_MSB 15
#define GTHE3_CH_TX_MARGIN_LOW_1_LSB 9
#define GTHE3_CH_TX_MARGIN_LOW_1_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_LOW_1_MSB, GTHE3_CH_TX_MARGIN_LOW_1_LSB)
#define GTHE3_CH_TX_MARGIN_LOW_2_ADDR 0x0082
#define GTHE3_CH_TX_MARGIN_LOW_2_MSB 7
#define GTHE3_CH_TX_MARGIN_LOW_2_LSB 1
#define GTHE3_CH_TX_MARGIN_LOW_2_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_LOW_2_MSB, GTHE3_CH_TX_MARGIN_LOW_2_LSB)
#define GTHE3_CH_TX_MARGIN_LOW_3_ADDR 0x0083
#define GTHE3_CH_TX_MARGIN_LOW_3_MSB 15
#define GTHE3_CH_TX_MARGIN_LOW_3_LSB 9
#define GTHE3_CH_TX_MARGIN_LOW_3_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_LOW_3_MSB, GTHE3_CH_TX_MARGIN_LOW_3_LSB)
#define GTHE3_CH_TX_MARGIN_LOW_4_ADDR 0x0083
#define GTHE3_CH_TX_MARGIN_LOW_4_MSB 7
#define GTHE3_CH_TX_MARGIN_LOW_4_LSB 1
#define GTHE3_CH_TX_MARGIN_LOW_4_MASK BIT_MASK(GTHE3_CH_TX_MARGIN_LOW_4_MSB, GTHE3_CH_TX_MARGIN_LOW_4_LSB)
#define GTHE3_CH_RXDFE_HD_CFG1_ADDR 0x0084
#define GTHE3_CH_RXDFE_HD_CFG1_MSB 15
#define GTHE3_CH_RXDFE_HD_CFG1_LSB 0
#define GTHE3_CH_RXDFE_HD_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_HD_CFG1_MSB, GTHE3_CH_RXDFE_HD_CFG1_LSB)
#define GTHE3_CH_TX_QPI_STATUS_EN_ADDR 0x0085
#define GTHE3_CH_TX_QPI_STATUS_EN_MSB 13
#define GTHE3_CH_TX_QPI_STATUS_EN_LSB 13
#define GTHE3_CH_TX_QPI_STATUS_EN_MASK BIT_MASK(GTHE3_CH_TX_QPI_STATUS_EN_MSB, GTHE3_CH_TX_QPI_STATUS_EN_LSB)
#define GTHE3_CH_TX_INT_DATAWIDTH_ADDR 0x0085
#define GTHE3_CH_TX_INT_DATAWIDTH_MSB 11
#define GTHE3_CH_TX_INT_DATAWIDTH_LSB 10
#define GTHE3_CH_TX_INT_DATAWIDTH_MASK BIT_MASK(GTHE3_CH_TX_INT_DATAWIDTH_MSB, GTHE3_CH_TX_INT_DATAWIDTH_LSB)
#define GTHE3_CH_RXPRBS_LINKACQ_CNT_ADDR 0x0089
#define GTHE3_CH_RXPRBS_LINKACQ_CNT_MSB 7
#define GTHE3_CH_RXPRBS_LINKACQ_CNT_LSB 0
#define GTHE3_CH_RXPRBS_LINKACQ_CNT_MASK BIT_MASK(GTHE3_CH_RXPRBS_LINKACQ_CNT_MSB, GTHE3_CH_RXPRBS_LINKACQ_CNT_LSB)
#define GTHE3_CH_TX_PMADATA_OPT_ADDR 0x008A
#define GTHE3_CH_TX_PMADATA_OPT_MSB 15
#define GTHE3_CH_TX_PMADATA_OPT_LSB 15
#define GTHE3_CH_TX_PMADATA_OPT_MASK BIT_MASK(GTHE3_CH_TX_PMADATA_OPT_MSB, GTHE3_CH_TX_PMADATA_OPT_LSB)
#define GTHE3_CH_RXSYNC_OVRD_ADDR 0x008A
#define GTHE3_CH_RXSYNC_OVRD_MSB 14
#define GTHE3_CH_RXSYNC_OVRD_LSB 14
#define GTHE3_CH_RXSYNC_OVRD_MASK BIT_MASK(GTHE3_CH_RXSYNC_OVRD_MSB, GTHE3_CH_RXSYNC_OVRD_LSB)
#define GTHE3_CH_TXSYNC_OVRD_ADDR 0x008A
#define GTHE3_CH_TXSYNC_OVRD_MSB 13
#define GTHE3_CH_TXSYNC_OVRD_LSB 13
#define GTHE3_CH_TXSYNC_OVRD_MASK BIT_MASK(GTHE3_CH_TXSYNC_OVRD_MSB, GTHE3_CH_TXSYNC_OVRD_LSB)
#define GTHE3_CH_TX_IDLE_DATA_ZERO_ADDR 0x008A
#define GTHE3_CH_TX_IDLE_DATA_ZERO_MSB 12
#define GTHE3_CH_TX_IDLE_DATA_ZERO_LSB 12
#define GTHE3_CH_TX_IDLE_DATA_ZERO_MASK BIT_MASK(GTHE3_CH_TX_IDLE_DATA_ZERO_MSB, GTHE3_CH_TX_IDLE_DATA_ZERO_LSB)
#define GTHE3_CH_A_RXOSCALRESET_ADDR 0x008A
#define GTHE3_CH_A_RXOSCALRESET_MSB 11
#define GTHE3_CH_A_RXOSCALRESET_LSB 11
#define GTHE3_CH_A_RXOSCALRESET_MASK BIT_MASK(GTHE3_CH_A_RXOSCALRESET_MSB, GTHE3_CH_A_RXOSCALRESET_LSB)
#define GTHE3_CH_RXOOB_CLK_CFG_ADDR 0x008A
#define GTHE3_CH_RXOOB_CLK_CFG_MSB 10
#define GTHE3_CH_RXOOB_CLK_CFG_LSB 10
#define GTHE3_CH_RXOOB_CLK_CFG_MASK BIT_MASK(GTHE3_CH_RXOOB_CLK_CFG_MSB, GTHE3_CH_RXOOB_CLK_CFG_LSB)
#define GTHE3_CH_TXSYNC_SKIP_DA_ADDR 0x008A
#define GTHE3_CH_TXSYNC_SKIP_DA_MSB 9
#define GTHE3_CH_TXSYNC_SKIP_DA_LSB 9
#define GTHE3_CH_TXSYNC_SKIP_DA_MASK BIT_MASK(GTHE3_CH_TXSYNC_SKIP_DA_MSB, GTHE3_CH_TXSYNC_SKIP_DA_LSB)
#define GTHE3_CH_RXSYNC_SKIP_DA_ADDR 0x008A
#define GTHE3_CH_RXSYNC_SKIP_DA_MSB 8
#define GTHE3_CH_RXSYNC_SKIP_DA_LSB 8
#define GTHE3_CH_RXSYNC_SKIP_DA_MASK BIT_MASK(GTHE3_CH_RXSYNC_SKIP_DA_MSB, GTHE3_CH_RXSYNC_SKIP_DA_LSB)
#define GTHE3_CH_RXOSCALRESET_TIME_ADDR 0x008A
#define GTHE3_CH_RXOSCALRESET_TIME_MSB 4
#define GTHE3_CH_RXOSCALRESET_TIME_LSB 0
#define GTHE3_CH_RXOSCALRESET_TIME_MASK BIT_MASK(GTHE3_CH_RXOSCALRESET_TIME_MSB, GTHE3_CH_RXOSCALRESET_TIME_LSB)
#define GTHE3_CH_TXSYNC_MULTILANE_ADDR 0x008B
#define GTHE3_CH_TXSYNC_MULTILANE_MSB 10
#define GTHE3_CH_TXSYNC_MULTILANE_LSB 10
#define GTHE3_CH_TXSYNC_MULTILANE_MASK BIT_MASK(GTHE3_CH_TXSYNC_MULTILANE_MSB, GTHE3_CH_TXSYNC_MULTILANE_LSB)
#define GTHE3_CH_RXSYNC_MULTILANE_ADDR 0x008B
#define GTHE3_CH_RXSYNC_MULTILANE_MSB 9
#define GTHE3_CH_RXSYNC_MULTILANE_LSB 9
#define GTHE3_CH_RXSYNC_MULTILANE_MASK BIT_MASK(GTHE3_CH_RXSYNC_MULTILANE_MSB, GTHE3_CH_RXSYNC_MULTILANE_LSB)
#define GTHE3_CH_RX_CTLE3_LPF_ADDR 0x008B
#define GTHE3_CH_RX_CTLE3_LPF_MSB 7
#define GTHE3_CH_RX_CTLE3_LPF_LSB 0
#define GTHE3_CH_RX_CTLE3_LPF_MASK BIT_MASK(GTHE3_CH_RX_CTLE3_LPF_MSB, GTHE3_CH_RX_CTLE3_LPF_LSB)
#define GTHE3_CH_ACJTAG_MODE_ADDR 0x008C
#define GTHE3_CH_ACJTAG_MODE_MSB 15
#define GTHE3_CH_ACJTAG_MODE_LSB 15
#define GTHE3_CH_ACJTAG_MODE_MASK BIT_MASK(GTHE3_CH_ACJTAG_MODE_MSB, GTHE3_CH_ACJTAG_MODE_LSB)
#define GTHE3_CH_ACJTAG_DEBUG_MODE_ADDR 0x008C
#define GTHE3_CH_ACJTAG_DEBUG_MODE_MSB 14
#define GTHE3_CH_ACJTAG_DEBUG_MODE_LSB 14
#define GTHE3_CH_ACJTAG_DEBUG_MODE_MASK BIT_MASK(GTHE3_CH_ACJTAG_DEBUG_MODE_MSB, GTHE3_CH_ACJTAG_DEBUG_MODE_LSB)
#define GTHE3_CH_ACJTAG_RESET_ADDR 0x008C
#define GTHE3_CH_ACJTAG_RESET_MSB 13
#define GTHE3_CH_ACJTAG_RESET_LSB 13
#define GTHE3_CH_ACJTAG_RESET_MASK BIT_MASK(GTHE3_CH_ACJTAG_RESET_MSB, GTHE3_CH_ACJTAG_RESET_LSB)
#define GTHE3_CH_RESET_POWERSAVE_DISABLE_ADDR 0x008C
#define GTHE3_CH_RESET_POWERSAVE_DISABLE_MSB 12
#define GTHE3_CH_RESET_POWERSAVE_DISABLE_LSB 12
#define GTHE3_CH_RESET_POWERSAVE_DISABLE_MASK BIT_MASK(GTHE3_CH_RESET_POWERSAVE_DISABLE_MSB, GTHE3_CH_RESET_POWERSAVE_DISABLE_LSB)
#define GTHE3_CH_RX_TUNE_AFE_OS_ADDR 0x008C
#define GTHE3_CH_RX_TUNE_AFE_OS_MSB 11
#define GTHE3_CH_RX_TUNE_AFE_OS_LSB 10
#define GTHE3_CH_RX_TUNE_AFE_OS_MASK BIT_MASK(GTHE3_CH_RX_TUNE_AFE_OS_MSB, GTHE3_CH_RX_TUNE_AFE_OS_LSB)
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG0_ADDR 0x008C
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG0_MSB 9
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG0_LSB 8
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG0_MASK BIT_MASK(GTHE3_CH_RX_DFE_KL_LPM_KL_CFG0_MSB, GTHE3_CH_RX_DFE_KL_LPM_KL_CFG0_LSB)
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG1_ADDR 0x008C
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG1_MSB 7
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG1_LSB 5
#define GTHE3_CH_RX_DFE_KL_LPM_KL_CFG1_MASK BIT_MASK(GTHE3_CH_RX_DFE_KL_LPM_KL_CFG1_MSB, GTHE3_CH_RX_DFE_KL_LPM_KL_CFG1_LSB)
#define GTHE3_CH_RXDFELPM_KL_CFG2_ADDR 0x008D
#define GTHE3_CH_RXDFELPM_KL_CFG2_MSB 15
#define GTHE3_CH_RXDFELPM_KL_CFG2_LSB 0
#define GTHE3_CH_RXDFELPM_KL_CFG2_MASK BIT_MASK(GTHE3_CH_RXDFELPM_KL_CFG2_MSB, GTHE3_CH_RXDFELPM_KL_CFG2_LSB)
#define GTHE3_CH_RXDFE_VP_CFG0_ADDR 0x008E
#define GTHE3_CH_RXDFE_VP_CFG0_MSB 15
#define GTHE3_CH_RXDFE_VP_CFG0_LSB 0
#define GTHE3_CH_RXDFE_VP_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_VP_CFG0_MSB, GTHE3_CH_RXDFE_VP_CFG0_LSB)
#define GTHE3_CH_RXDFE_VP_CFG1_ADDR 0x008F
#define GTHE3_CH_RXDFE_VP_CFG1_MSB 15
#define GTHE3_CH_RXDFE_VP_CFG1_LSB 0
#define GTHE3_CH_RXDFE_VP_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_VP_CFG1_MSB, GTHE3_CH_RXDFE_VP_CFG1_LSB)
#define GTHE3_CH_RXDFE_UT_CFG1_ADDR 0x0090
#define GTHE3_CH_RXDFE_UT_CFG1_MSB 15
#define GTHE3_CH_RXDFE_UT_CFG1_LSB 0
#define GTHE3_CH_RXDFE_UT_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_UT_CFG1_MSB, GTHE3_CH_RXDFE_UT_CFG1_LSB)
#define GTHE3_CH_ADAPT_CFG0_ADDR 0x0091
#define GTHE3_CH_ADAPT_CFG0_MSB 15
#define GTHE3_CH_ADAPT_CFG0_LSB 0
#define GTHE3_CH_ADAPT_CFG0_MASK BIT_MASK(GTHE3_CH_ADAPT_CFG0_MSB, GTHE3_CH_ADAPT_CFG0_LSB)
#define GTHE3_CH_ADAPT_CFG1_ADDR 0x0092
#define GTHE3_CH_ADAPT_CFG1_MSB 15
#define GTHE3_CH_ADAPT_CFG1_LSB 0
#define GTHE3_CH_ADAPT_CFG1_MASK BIT_MASK(GTHE3_CH_ADAPT_CFG1_MSB, GTHE3_CH_ADAPT_CFG1_LSB)
#define GTHE3_CH_RXCFOK_CFG0_ADDR 0x0093
#define GTHE3_CH_RXCFOK_CFG0_MSB 15
#define GTHE3_CH_RXCFOK_CFG0_LSB 0
#define GTHE3_CH_RXCFOK_CFG0_MASK BIT_MASK(GTHE3_CH_RXCFOK_CFG0_MSB, GTHE3_CH_RXCFOK_CFG0_LSB)
#define GTHE3_CH_ES_CLK_PHASE_SEL_ADDR 0x0094
#define GTHE3_CH_ES_CLK_PHASE_SEL_MSB 11
#define GTHE3_CH_ES_CLK_PHASE_SEL_LSB 11
#define GTHE3_CH_ES_CLK_PHASE_SEL_MASK BIT_MASK(GTHE3_CH_ES_CLK_PHASE_SEL_MSB, GTHE3_CH_ES_CLK_PHASE_SEL_LSB)
#define GTHE3_CH_USE_PCS_CLK_PHASE_SEL_ADDR 0x0094
#define GTHE3_CH_USE_PCS_CLK_PHASE_SEL_MSB 10
#define GTHE3_CH_USE_PCS_CLK_PHASE_SEL_LSB 10
#define GTHE3_CH_USE_PCS_CLK_PHASE_SEL_MASK BIT_MASK(GTHE3_CH_USE_PCS_CLK_PHASE_SEL_MSB, GTHE3_CH_USE_PCS_CLK_PHASE_SEL_LSB)
#define GTHE3_CH_PMA_RSV1_ADDR 0x0095
#define GTHE3_CH_PMA_RSV1_MSB 15
#define GTHE3_CH_PMA_RSV1_LSB 0
#define GTHE3_CH_PMA_RSV1_MASK BIT_MASK(GTHE3_CH_PMA_RSV1_MSB, GTHE3_CH_PMA_RSV1_LSB)
#define GTHE3_CH_RX_AFE_CM_EN_ADDR 0x0097
#define GTHE3_CH_RX_AFE_CM_EN_MSB 12
#define GTHE3_CH_RX_AFE_CM_EN_LSB 12
#define GTHE3_CH_RX_AFE_CM_EN_MASK BIT_MASK(GTHE3_CH_RX_AFE_CM_EN_MSB, GTHE3_CH_RX_AFE_CM_EN_LSB)
#define GTHE3_CH_RX_CAPFF_SARC_ENB_ADDR 0x0097
#define GTHE3_CH_RX_CAPFF_SARC_ENB_MSB 11
#define GTHE3_CH_RX_CAPFF_SARC_ENB_LSB 11
#define GTHE3_CH_RX_CAPFF_SARC_ENB_MASK BIT_MASK(GTHE3_CH_RX_CAPFF_SARC_ENB_MSB, GTHE3_CH_RX_CAPFF_SARC_ENB_LSB)
#define GTHE3_CH_RX_EYESCAN_VS_NEG_DIR_ADDR 0x0097
#define GTHE3_CH_RX_EYESCAN_VS_NEG_DIR_MSB 10
#define GTHE3_CH_RX_EYESCAN_VS_NEG_DIR_LSB 10
#define GTHE3_CH_RX_EYESCAN_VS_NEG_DIR_MASK BIT_MASK(GTHE3_CH_RX_EYESCAN_VS_NEG_DIR_MSB, GTHE3_CH_RX_EYESCAN_VS_NEG_DIR_LSB)
#define GTHE3_CH_RX_EYESCAN_VS_UT_SIGN_ADDR 0x0097
#define GTHE3_CH_RX_EYESCAN_VS_UT_SIGN_MSB 9
#define GTHE3_CH_RX_EYESCAN_VS_UT_SIGN_LSB 9
#define GTHE3_CH_RX_EYESCAN_VS_UT_SIGN_MASK BIT_MASK(GTHE3_CH_RX_EYESCAN_VS_UT_SIGN_MSB, GTHE3_CH_RX_EYESCAN_VS_UT_SIGN_LSB)
#define GTHE3_CH_RX_EYESCAN_VS_CODE_ADDR 0x0097
#define GTHE3_CH_RX_EYESCAN_VS_CODE_MSB 8
#define GTHE3_CH_RX_EYESCAN_VS_CODE_LSB 2
#define GTHE3_CH_RX_EYESCAN_VS_CODE_MASK BIT_MASK(GTHE3_CH_RX_EYESCAN_VS_CODE_MSB, GTHE3_CH_RX_EYESCAN_VS_CODE_LSB)
#define GTHE3_CH_RX_EYESCAN_VS_RANGE_ADDR 0x0097
#define GTHE3_CH_RX_EYESCAN_VS_RANGE_MSB 1
#define GTHE3_CH_RX_EYESCAN_VS_RANGE_LSB 0
#define GTHE3_CH_RX_EYESCAN_VS_RANGE_MASK BIT_MASK(GTHE3_CH_RX_EYESCAN_VS_RANGE_MSB, GTHE3_CH_RX_EYESCAN_VS_RANGE_LSB)
#define GTHE3_CH_RXDFE_HE_CFG1_ADDR 0x0098
#define GTHE3_CH_RXDFE_HE_CFG1_MSB 15
#define GTHE3_CH_RXDFE_HE_CFG1_LSB 0
#define GTHE3_CH_RXDFE_HE_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_HE_CFG1_MSB, GTHE3_CH_RXDFE_HE_CFG1_LSB)
#define GTHE3_CH_GEARBOX_MODE_ADDR 0x0099
#define GTHE3_CH_GEARBOX_MODE_MSB 15
#define GTHE3_CH_GEARBOX_MODE_LSB 11
#define GTHE3_CH_GEARBOX_MODE_MASK BIT_MASK(GTHE3_CH_GEARBOX_MODE_MSB, GTHE3_CH_GEARBOX_MODE_LSB)
#define GTHE3_CH_TXPI_SYNFREQ_PPM_ADDR 0x0099
#define GTHE3_CH_TXPI_SYNFREQ_PPM_MSB 10
#define GTHE3_CH_TXPI_SYNFREQ_PPM_LSB 8
#define GTHE3_CH_TXPI_SYNFREQ_PPM_MASK BIT_MASK(GTHE3_CH_TXPI_SYNFREQ_PPM_MSB, GTHE3_CH_TXPI_SYNFREQ_PPM_LSB)
#define GTHE3_CH_TXPI_PPMCLK_SEL_ADDR 0x0099
#define GTHE3_CH_TXPI_PPMCLK_SEL_MSB 7
#define GTHE3_CH_TXPI_PPMCLK_SEL_LSB 7
#define GTHE3_CH_TXPI_PPMCLK_SEL_MASK BIT_MASK(GTHE3_CH_TXPI_PPMCLK_SEL_MSB, GTHE3_CH_TXPI_PPMCLK_SEL_LSB)
#define GTHE3_CH_TXPI_PPMCLK_SEL_TXUSRCLK 0
#define GTHE3_CH_TXPI_PPMCLK_SEL_TXUSRCLK2 1
#define GTHE3_CH_TXPI_INVSTROBE_SEL_ADDR 0x0099
#define GTHE3_CH_TXPI_INVSTROBE_SEL_MSB 6
#define GTHE3_CH_TXPI_INVSTROBE_SEL_LSB 6
#define GTHE3_CH_TXPI_INVSTROBE_SEL_MASK BIT_MASK(GTHE3_CH_TXPI_INVSTROBE_SEL_MSB, GTHE3_CH_TXPI_INVSTROBE_SEL_LSB)
#define GTHE3_CH_TXPI_GRAY_SEL_ADDR 0x0099
#define GTHE3_CH_TXPI_GRAY_SEL_MSB 5
#define GTHE3_CH_TXPI_GRAY_SEL_LSB 5
#define GTHE3_CH_TXPI_GRAY_SEL_MASK BIT_MASK(GTHE3_CH_TXPI_GRAY_SEL_MSB, GTHE3_CH_TXPI_GRAY_SEL_LSB)
#define GTHE3_CH_TXPI_LPM_ADDR 0x0099
#define GTHE3_CH_TXPI_LPM_MSB 3
#define GTHE3_CH_TXPI_LPM_LSB 3
#define GTHE3_CH_TXPI_LPM_MASK BIT_MASK(GTHE3_CH_TXPI_LPM_MSB, GTHE3_CH_TXPI_LPM_LSB)
#define GTHE3_CH_TXPI_VREFSEL_ADDR 0x0099
#define GTHE3_CH_TXPI_VREFSEL_MSB 2
#define GTHE3_CH_TXPI_VREFSEL_LSB 2
#define GTHE3_CH_TXPI_VREFSEL_MASK BIT_MASK(GTHE3_CH_TXPI_VREFSEL_MSB, GTHE3_CH_TXPI_VREFSEL_LSB)
#define GTHE3_CH_TXPI_PPM_CFG_ADDR 0x009A
#define GTHE3_CH_TXPI_PPM_CFG_MSB 7
#define GTHE3_CH_TXPI_PPM_CFG_LSB 0
#define GTHE3_CH_TXPI_PPM_CFG_MASK BIT_MASK(GTHE3_CH_TXPI_PPM_CFG_MSB, GTHE3_CH_TXPI_PPM_CFG_LSB)
#define GTHE3_CH_RX_DFELPM_KLKH_AGC_STUP_EN_ADDR 0x009B
#define GTHE3_CH_RX_DFELPM_KLKH_AGC_STUP_EN_MSB 15
#define GTHE3_CH_RX_DFELPM_KLKH_AGC_STUP_EN_LSB 15
#define GTHE3_CH_RX_DFELPM_KLKH_AGC_STUP_EN_MASK BIT_MASK(GTHE3_CH_RX_DFELPM_KLKH_AGC_STUP_EN_MSB, GTHE3_CH_RX_DFELPM_KLKH_AGC_STUP_EN_LSB)
#define GTHE3_CH_RX_DFELPM_CFG0_ADDR 0x009B
#define GTHE3_CH_RX_DFELPM_CFG0_MSB 14
#define GTHE3_CH_RX_DFELPM_CFG0_LSB 11
#define GTHE3_CH_RX_DFELPM_CFG0_MASK BIT_MASK(GTHE3_CH_RX_DFELPM_CFG0_MSB, GTHE3_CH_RX_DFELPM_CFG0_LSB)
#define GTHE3_CH_RX_DFELPM_CFG1_ADDR 0x009B
#define GTHE3_CH_RX_DFELPM_CFG1_MSB 10
#define GTHE3_CH_RX_DFELPM_CFG1_LSB 10
#define GTHE3_CH_RX_DFELPM_CFG1_MASK BIT_MASK(GTHE3_CH_RX_DFELPM_CFG1_MSB, GTHE3_CH_RX_DFELPM_CFG1_LSB)
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG0_ADDR 0x009B
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG0_MSB 9
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG0_LSB 8
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG0_MASK BIT_MASK(GTHE3_CH_RX_DFE_KL_LPM_KH_CFG0_MSB, GTHE3_CH_RX_DFE_KL_LPM_KH_CFG0_LSB)
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG1_ADDR 0x009B
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG1_MSB 7
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG1_LSB 5
#define GTHE3_CH_RX_DFE_KL_LPM_KH_CFG1_MASK BIT_MASK(GTHE3_CH_RX_DFE_KL_LPM_KH_CFG1_MSB, GTHE3_CH_RX_DFE_KL_LPM_KH_CFG1_LSB)
#define GTHE3_CH_TXPI_CFG0_ADDR 0x009C
#define GTHE3_CH_TXPI_CFG0_MSB 12
#define GTHE3_CH_TXPI_CFG0_LSB 11
#define GTHE3_CH_TXPI_CFG0_MASK BIT_MASK(GTHE3_CH_TXPI_CFG0_MSB, GTHE3_CH_TXPI_CFG0_LSB)
#define GTHE3_CH_TXPI_CFG1_ADDR 0x009C
#define GTHE3_CH_TXPI_CFG1_MSB 10
#define GTHE3_CH_TXPI_CFG1_LSB 9
#define GTHE3_CH_TXPI_CFG1_MASK BIT_MASK(GTHE3_CH_TXPI_CFG1_MSB, GTHE3_CH_TXPI_CFG1_LSB)
#define GTHE3_CH_TXPI_CFG2_ADDR 0x009C
#define GTHE3_CH_TXPI_CFG2_MSB 8
#define GTHE3_CH_TXPI_CFG2_LSB 7
#define GTHE3_CH_TXPI_CFG2_MASK BIT_MASK(GTHE3_CH_TXPI_CFG2_MSB, GTHE3_CH_TXPI_CFG2_LSB)
#define GTHE3_CH_TXPI_CFG3_ADDR 0x009C
#define GTHE3_CH_TXPI_CFG3_MSB 6
#define GTHE3_CH_TXPI_CFG3_LSB 6
#define GTHE3_CH_TXPI_CFG3_MASK BIT_MASK(GTHE3_CH_TXPI_CFG3_MSB, GTHE3_CH_TXPI_CFG3_LSB)
#define GTHE3_CH_TXPI_CFG4_ADDR 0x009C
#define GTHE3_CH_TXPI_CFG4_MSB 5
#define GTHE3_CH_TXPI_CFG4_LSB 5
#define GTHE3_CH_TXPI_CFG4_MASK BIT_MASK(GTHE3_CH_TXPI_CFG4_MSB, GTHE3_CH_TXPI_CFG4_LSB)
#define GTHE3_CH_TXPI_CFG5_ADDR 0x009C
#define GTHE3_CH_TXPI_CFG5_MSB 4
#define GTHE3_CH_TXPI_CFG5_LSB 2
#define GTHE3_CH_TXPI_CFG5_MASK BIT_MASK(GTHE3_CH_TXPI_CFG5_MSB, GTHE3_CH_TXPI_CFG5_LSB)
#define GTHE3_CH_RXPI_CFG1_ADDR 0x009D
#define GTHE3_CH_RXPI_CFG1_MSB 15
#define GTHE3_CH_RXPI_CFG1_LSB 14
#define GTHE3_CH_RXPI_CFG1_MASK BIT_MASK(GTHE3_CH_RXPI_CFG1_MSB, GTHE3_CH_RXPI_CFG1_LSB)
#define GTHE3_CH_RXPI_CFG2_ADDR 0x009D
#define GTHE3_CH_RXPI_CFG2_MSB 13
#define GTHE3_CH_RXPI_CFG2_LSB 12
#define GTHE3_CH_RXPI_CFG2_MASK BIT_MASK(GTHE3_CH_RXPI_CFG2_MSB, GTHE3_CH_RXPI_CFG2_LSB)
#define GTHE3_CH_RXPI_CFG3_ADDR 0x009D
#define GTHE3_CH_RXPI_CFG3_MSB 11
#define GTHE3_CH_RXPI_CFG3_LSB 10
#define GTHE3_CH_RXPI_CFG3_MASK BIT_MASK(GTHE3_CH_RXPI_CFG3_MSB, GTHE3_CH_RXPI_CFG3_LSB)
#define GTHE3_CH_RXPI_CFG4_ADDR 0x009D
#define GTHE3_CH_RXPI_CFG4_MSB 9
#define GTHE3_CH_RXPI_CFG4_LSB 9
#define GTHE3_CH_RXPI_CFG4_MASK BIT_MASK(GTHE3_CH_RXPI_CFG4_MSB, GTHE3_CH_RXPI_CFG4_LSB)
#define GTHE3_CH_RXPI_CFG5_ADDR 0x009D
#define GTHE3_CH_RXPI_CFG5_MSB 8
#define GTHE3_CH_RXPI_CFG5_LSB 8
#define GTHE3_CH_RXPI_CFG5_MASK BIT_MASK(GTHE3_CH_RXPI_CFG5_MSB, GTHE3_CH_RXPI_CFG5_LSB)
#define GTHE3_CH_RXPI_CFG6_ADDR 0x009D
#define GTHE3_CH_RXPI_CFG6_MSB 7
#define GTHE3_CH_RXPI_CFG6_LSB 5
#define GTHE3_CH_RXPI_CFG6_MASK BIT_MASK(GTHE3_CH_RXPI_CFG6_MSB, GTHE3_CH_RXPI_CFG6_LSB)
#define GTHE3_CH_RXPI_CFG0_ADDR 0x009D
#define GTHE3_CH_RXPI_CFG0_MSB 4
#define GTHE3_CH_RXPI_CFG0_LSB 3
#define GTHE3_CH_RXPI_CFG0_MASK BIT_MASK(GTHE3_CH_RXPI_CFG0_MSB, GTHE3_CH_RXPI_CFG0_LSB)
#define GTHE3_CH_RXDFE_UT_CFG0_ADDR 0x009E
#define GTHE3_CH_RXDFE_UT_CFG0_MSB 15
#define GTHE3_CH_RXDFE_UT_CFG0_LSB 0
#define GTHE3_CH_RXDFE_UT_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_UT_CFG0_MSB, GTHE3_CH_RXDFE_UT_CFG0_LSB)
#define GTHE3_CH_RXDFE_GC_CFG0_ADDR 0x009F
#define GTHE3_CH_RXDFE_GC_CFG0_MSB 15
#define GTHE3_CH_RXDFE_GC_CFG0_LSB 0
#define GTHE3_CH_RXDFE_GC_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_GC_CFG0_MSB, GTHE3_CH_RXDFE_GC_CFG0_LSB)
#define GTHE3_CH_RXDFE_GC_CFG1_ADDR 0x00A0
#define GTHE3_CH_RXDFE_GC_CFG1_MSB 15
#define GTHE3_CH_RXDFE_GC_CFG1_LSB 0
#define GTHE3_CH_RXDFE_GC_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_GC_CFG1_MSB, GTHE3_CH_RXDFE_GC_CFG1_LSB)
#define GTHE3_CH_RXDFE_GC_CFG2_ADDR 0x00A1
#define GTHE3_CH_RXDFE_GC_CFG2_MSB 15
#define GTHE3_CH_RXDFE_GC_CFG2_LSB 0
#define GTHE3_CH_RXDFE_GC_CFG2_MASK BIT_MASK(GTHE3_CH_RXDFE_GC_CFG2_MSB, GTHE3_CH_RXDFE_GC_CFG2_LSB)
#define GTHE3_CH_RXCDR_CFG0_GEN3_ADDR 0x00A2
#define GTHE3_CH_RXCDR_CFG0_GEN3_MSB 15
#define GTHE3_CH_RXCDR_CFG0_GEN3_LSB 0
#define GTHE3_CH_RXCDR_CFG0_GEN3_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG0_GEN3_MSB, GTHE3_CH_RXCDR_CFG0_GEN3_LSB)
#define GTHE3_CH_RXCDR_CFG1_GEN3_ADDR 0x00A3
#define GTHE3_CH_RXCDR_CFG1_GEN3_MSB 15
#define GTHE3_CH_RXCDR_CFG1_GEN3_LSB 0
#define GTHE3_CH_RXCDR_CFG1_GEN3_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG1_GEN3_MSB, GTHE3_CH_RXCDR_CFG1_GEN3_LSB)
#define GTHE3_CH_RXCDR_CFG2_GEN3_ADDR 0x00A4
#define GTHE3_CH_RXCDR_CFG2_GEN3_MSB 15
#define GTHE3_CH_RXCDR_CFG2_GEN3_LSB 0
#define GTHE3_CH_RXCDR_CFG2_GEN3_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG2_GEN3_MSB, GTHE3_CH_RXCDR_CFG2_GEN3_LSB)
#define GTHE3_CH_RXCDR_CFG3_GEN3_ADDR 0x00A5
#define GTHE3_CH_RXCDR_CFG3_GEN3_MSB 15
#define GTHE3_CH_RXCDR_CFG3_GEN3_LSB 0
#define GTHE3_CH_RXCDR_CFG3_GEN3_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG3_GEN3_MSB, GTHE3_CH_RXCDR_CFG3_GEN3_LSB)
#define GTHE3_CH_RXCDR_CFG4_GEN3_ADDR 0x00A6
#define GTHE3_CH_RXCDR_CFG4_GEN3_MSB 15
#define GTHE3_CH_RXCDR_CFG4_GEN3_LSB 0
#define GTHE3_CH_RXCDR_CFG4_GEN3_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG4_GEN3_MSB, GTHE3_CH_RXCDR_CFG4_GEN3_LSB)
#define GTHE3_CH_RXCDR_CFG5_GEN3_ADDR 0x00A7
#define GTHE3_CH_RXCDR_CFG5_GEN3_MSB 15
#define GTHE3_CH_RXCDR_CFG5_GEN3_LSB 0
#define GTHE3_CH_RXCDR_CFG5_GEN3_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG5_GEN3_MSB, GTHE3_CH_RXCDR_CFG5_GEN3_LSB)
#define GTHE3_CH_RXCDR_CFG5_ADDR 0x00A8
#define GTHE3_CH_RXCDR_CFG5_MSB 15
#define GTHE3_CH_RXCDR_CFG5_LSB 0
#define GTHE3_CH_RXCDR_CFG5_MASK BIT_MASK(GTHE3_CH_RXCDR_CFG5_MSB, GTHE3_CH_RXCDR_CFG5_LSB)
#define GTHE3_CH_PCIE_RXPMA_CFG_ADDR 0x00A9
#define GTHE3_CH_PCIE_RXPMA_CFG_MSB 15
#define GTHE3_CH_PCIE_RXPMA_CFG_LSB 0
#define GTHE3_CH_PCIE_RXPMA_CFG_MASK BIT_MASK(GTHE3_CH_PCIE_RXPMA_CFG_MSB, GTHE3_CH_PCIE_RXPMA_CFG_LSB)
#define GTHE3_CH_PCIE_TXPCS_CFG_GEN3_ADDR 0x00AA
#define GTHE3_CH_PCIE_TXPCS_CFG_GEN3_MSB 15
#define GTHE3_CH_PCIE_TXPCS_CFG_GEN3_LSB 0
#define GTHE3_CH_PCIE_TXPCS_CFG_GEN3_MASK BIT_MASK(GTHE3_CH_PCIE_TXPCS_CFG_GEN3_MSB, GTHE3_CH_PCIE_TXPCS_CFG_GEN3_LSB)
#define GTHE3_CH_PCIE_TXPMA_CFG_ADDR 0x00AB
#define GTHE3_CH_PCIE_TXPMA_CFG_MSB 15
#define GTHE3_CH_PCIE_TXPMA_CFG_LSB 0
#define GTHE3_CH_PCIE_TXPMA_CFG_MASK BIT_MASK(GTHE3_CH_PCIE_TXPMA_CFG_MSB, GTHE3_CH_PCIE_TXPMA_CFG_LSB)
#define GTHE3_CH_RX_CLK_SLIP_OVRD_ADDR 0x00AC
#define GTHE3_CH_RX_CLK_SLIP_OVRD_MSB 7
#define GTHE3_CH_RX_CLK_SLIP_OVRD_LSB 3
#define GTHE3_CH_RX_CLK_SLIP_OVRD_MASK BIT_MASK(GTHE3_CH_RX_CLK_SLIP_OVRD_MSB, GTHE3_CH_RX_CLK_SLIP_OVRD_LSB)
#define GTHE3_CH_PCS_RSVD1_ADDR 0x00AC
#define GTHE3_CH_PCS_RSVD1_MSB 2
#define GTHE3_CH_PCS_RSVD1_LSB 0
#define GTHE3_CH_PCS_RSVD1_MASK BIT_MASK(GTHE3_CH_PCS_RSVD1_MSB, GTHE3_CH_PCS_RSVD1_LSB)
#define GTHE3_CH_PLL_SEL_MODE_GEN3_ADDR 0x00AD
#define GTHE3_CH_PLL_SEL_MODE_GEN3_MSB 12
#define GTHE3_CH_PLL_SEL_MODE_GEN3_LSB 11
#define GTHE3_CH_PLL_SEL_MODE_GEN3_MASK BIT_MASK(GTHE3_CH_PLL_SEL_MODE_GEN3_MSB, GTHE3_CH_PLL_SEL_MODE_GEN3_LSB)
#define GTHE3_CH_PLL_SEL_MODE_GEN12_ADDR 0x00AD
#define GTHE3_CH_PLL_SEL_MODE_GEN12_MSB 10
#define GTHE3_CH_PLL_SEL_MODE_GEN12_LSB 9
#define GTHE3_CH_PLL_SEL_MODE_GEN12_MASK BIT_MASK(GTHE3_CH_PLL_SEL_MODE_GEN12_MSB, GTHE3_CH_PLL_SEL_MODE_GEN12_LSB)
#define GTHE3_CH_RATE_SW_USE_DRP_ADDR 0x00AD
#define GTHE3_CH_RATE_SW_USE_DRP_MSB 8
#define GTHE3_CH_RATE_SW_USE_DRP_LSB 8
#define GTHE3_CH_RATE_SW_USE_DRP_MASK BIT_MASK(GTHE3_CH_RATE_SW_USE_DRP_MSB, GTHE3_CH_RATE_SW_USE_DRP_LSB)
#define GTHE3_CH_RXPI_LPM_ADDR 0x00AD
#define GTHE3_CH_RXPI_LPM_MSB 3
#define GTHE3_CH_RXPI_LPM_LSB 3
#define GTHE3_CH_RXPI_LPM_MASK BIT_MASK(GTHE3_CH_RXPI_LPM_MSB, GTHE3_CH_RXPI_LPM_LSB)
#define GTHE3_CH_RXPI_VREFSEL_ADDR 0x00AD
#define GTHE3_CH_RXPI_VREFSEL_MSB 2
#define GTHE3_CH_RXPI_VREFSEL_LSB 2
#define GTHE3_CH_RXPI_VREFSEL_MASK BIT_MASK(GTHE3_CH_RXPI_VREFSEL_MSB, GTHE3_CH_RXPI_VREFSEL_LSB)
#define GTHE3_CH_RXDFE_H3_CFG0_ADDR 0x00AE
#define GTHE3_CH_RXDFE_H3_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H3_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H3_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H3_CFG0_MSB, GTHE3_CH_RXDFE_H3_CFG0_LSB)
#define GTHE3_CH_DFE_D_X_REL_POS_ADDR 0x00AF
#define GTHE3_CH_DFE_D_X_REL_POS_MSB 15
#define GTHE3_CH_DFE_D_X_REL_POS_LSB 15
#define GTHE3_CH_DFE_D_X_REL_POS_MASK BIT_MASK(GTHE3_CH_DFE_D_X_REL_POS_MSB, GTHE3_CH_DFE_D_X_REL_POS_LSB)
#define GTHE3_CH_DFE_VCM_COMP_EN_ADDR 0x00AF
#define GTHE3_CH_DFE_VCM_COMP_EN_MSB 14
#define GTHE3_CH_DFE_VCM_COMP_EN_LSB 14
#define GTHE3_CH_DFE_VCM_COMP_EN_MASK BIT_MASK(GTHE3_CH_DFE_VCM_COMP_EN_MSB, GTHE3_CH_DFE_VCM_COMP_EN_LSB)
#define GTHE3_CH_GM_BIAS_SELECT_ADDR 0x00AF
#define GTHE3_CH_GM_BIAS_SELECT_MSB 13
#define GTHE3_CH_GM_BIAS_SELECT_LSB 13
#define GTHE3_CH_GM_BIAS_SELECT_MASK BIT_MASK(GTHE3_CH_GM_BIAS_SELECT_MSB, GTHE3_CH_GM_BIAS_SELECT_LSB)
#define GTHE3_CH_EVODD_PHI_CFG_ADDR 0x00AF
#define GTHE3_CH_EVODD_PHI_CFG_MSB 10
#define GTHE3_CH_EVODD_PHI_CFG_LSB 0
#define GTHE3_CH_EVODD_PHI_CFG_MASK BIT_MASK(GTHE3_CH_EVODD_PHI_CFG_MSB, GTHE3_CH_EVODD_PHI_CFG_LSB)
#define GTHE3_CH_RXDFE_H3_CFG1_ADDR 0x00B0
#define GTHE3_CH_RXDFE_H3_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H3_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H3_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H3_CFG1_MSB, GTHE3_CH_RXDFE_H3_CFG1_LSB)
#define GTHE3_CH_RXDFE_H4_CFG0_ADDR 0x00B1
#define GTHE3_CH_RXDFE_H4_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H4_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H4_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H4_CFG0_MSB, GTHE3_CH_RXDFE_H4_CFG0_LSB)
#define GTHE3_CH_RXDFE_H4_CFG1_ADDR 0x00B2
#define GTHE3_CH_RXDFE_H4_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H4_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H4_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H4_CFG1_MSB, GTHE3_CH_RXDFE_H4_CFG1_LSB)
#define GTHE3_CH_RXDFE_H5_CFG0_ADDR 0x00B3
#define GTHE3_CH_RXDFE_H5_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H5_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H5_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H5_CFG0_MSB, GTHE3_CH_RXDFE_H5_CFG0_LSB)
#define GTHE3_CH_PROCESS_PAR_ADDR 0x00B4
#define GTHE3_CH_PROCESS_PAR_MSB 15
#define GTHE3_CH_PROCESS_PAR_LSB 13
#define GTHE3_CH_PROCESS_PAR_MASK BIT_MASK(GTHE3_CH_PROCESS_PAR_MSB, GTHE3_CH_PROCESS_PAR_LSB)
#define GTHE3_CH_TEMPERATUR_PAR_ADDR 0x00B4
#define GTHE3_CH_TEMPERATUR_PAR_MSB 11
#define GTHE3_CH_TEMPERATUR_PAR_LSB 8
#define GTHE3_CH_TEMPERATUR_PAR_MASK BIT_MASK(GTHE3_CH_TEMPERATUR_PAR_MSB, GTHE3_CH_TEMPERATUR_PAR_LSB)
#define GTHE3_CH_TX_MODE_SEL_ADDR 0x00B4
#define GTHE3_CH_TX_MODE_SEL_MSB 7
#define GTHE3_CH_TX_MODE_SEL_LSB 5
#define GTHE3_CH_TX_MODE_SEL_MASK BIT_MASK(GTHE3_CH_TX_MODE_SEL_MSB, GTHE3_CH_TX_MODE_SEL_LSB)
#define GTHE3_CH_TX_SARC_LPBK_ENB_ADDR 0x00B4
#define GTHE3_CH_TX_SARC_LPBK_ENB_MSB 4
#define GTHE3_CH_TX_SARC_LPBK_ENB_LSB 4
#define GTHE3_CH_TX_SARC_LPBK_ENB_MASK BIT_MASK(GTHE3_CH_TX_SARC_LPBK_ENB_MSB, GTHE3_CH_TX_SARC_LPBK_ENB_LSB)
#define GTHE3_CH_RXDFE_H5_CFG1_ADDR 0x00B5
#define GTHE3_CH_RXDFE_H5_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H5_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H5_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H5_CFG1_MSB, GTHE3_CH_RXDFE_H5_CFG1_LSB)
#define GTHE3_CH_TX_DCD_CFG_ADDR 0x00B6
#define GTHE3_CH_TX_DCD_CFG_MSB 15
#define GTHE3_CH_TX_DCD_CFG_LSB 10
#define GTHE3_CH_TX_DCD_CFG_MASK BIT_MASK(GTHE3_CH_TX_DCD_CFG_MSB, GTHE3_CH_TX_DCD_CFG_LSB)
#define GTHE3_CH_TX_DCD_EN_ADDR 0x00B6
#define GTHE3_CH_TX_DCD_EN_MSB 9
#define GTHE3_CH_TX_DCD_EN_LSB 9
#define GTHE3_CH_TX_DCD_EN_MASK BIT_MASK(GTHE3_CH_TX_DCD_EN_MSB, GTHE3_CH_TX_DCD_EN_LSB)
#define GTHE3_CH_TX_EML_PHI_TUNE_ADDR 0x00B6
#define GTHE3_CH_TX_EML_PHI_TUNE_MSB 8
#define GTHE3_CH_TX_EML_PHI_TUNE_LSB 8
#define GTHE3_CH_TX_EML_PHI_TUNE_MASK BIT_MASK(GTHE3_CH_TX_EML_PHI_TUNE_MSB, GTHE3_CH_TX_EML_PHI_TUNE_LSB)
#define GTHE3_CH_CPLL_CFG3_ADDR 0x00B6
#define GTHE3_CH_CPLL_CFG3_MSB 5
#define GTHE3_CH_CPLL_CFG3_LSB 0
#define GTHE3_CH_CPLL_CFG3_MASK BIT_MASK(GTHE3_CH_CPLL_CFG3_MSB, GTHE3_CH_CPLL_CFG3_LSB)
#define GTHE3_CH_RXDFE_H6_CFG0_ADDR 0x00B7
#define GTHE3_CH_RXDFE_H6_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H6_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H6_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H6_CFG0_MSB, GTHE3_CH_RXDFE_H6_CFG0_LSB)
#define GTHE3_CH_RXDFE_H6_CFG1_ADDR 0x00B8
#define GTHE3_CH_RXDFE_H6_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H6_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H6_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H6_CFG1_MSB, GTHE3_CH_RXDFE_H6_CFG1_LSB)
#define GTHE3_CH_RXDFE_H7_CFG0_ADDR 0x00B9
#define GTHE3_CH_RXDFE_H7_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H7_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H7_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H7_CFG0_MSB, GTHE3_CH_RXDFE_H7_CFG0_LSB)
#define GTHE3_CH_DDI_REALIGN_WAIT_ADDR 0x00BA
#define GTHE3_CH_DDI_REALIGN_WAIT_MSB 6
#define GTHE3_CH_DDI_REALIGN_WAIT_LSB 2
#define GTHE3_CH_DDI_REALIGN_WAIT_MASK BIT_MASK(GTHE3_CH_DDI_REALIGN_WAIT_MSB, GTHE3_CH_DDI_REALIGN_WAIT_LSB)
#define GTHE3_CH_DDI_CTRL_ADDR 0x00BA
#define GTHE3_CH_DDI_CTRL_MSB 1
#define GTHE3_CH_DDI_CTRL_LSB 0
#define GTHE3_CH_DDI_CTRL_MASK BIT_MASK(GTHE3_CH_DDI_CTRL_MSB, GTHE3_CH_DDI_CTRL_LSB)
#define GTHE3_CH_TXGBOX_FIFO_INIT_RD_ADDR_ADDR 0x00BB
#define GTHE3_CH_TXGBOX_FIFO_INIT_RD_ADDR_MSB 11
#define GTHE3_CH_TXGBOX_FIFO_INIT_RD_ADDR_LSB 9
#define GTHE3_CH_TXGBOX_FIFO_INIT_RD_ADDR_MASK BIT_MASK(GTHE3_CH_TXGBOX_FIFO_INIT_RD_ADDR_MSB, GTHE3_CH_TXGBOX_FIFO_INIT_RD_ADDR_LSB)
#define GTHE3_CH_TX_SAMPLE_PERIOD_ADDR 0x00BB
#define GTHE3_CH_TX_SAMPLE_PERIOD_MSB 8
#define GTHE3_CH_TX_SAMPLE_PERIOD_LSB 6
#define GTHE3_CH_TX_SAMPLE_PERIOD_MASK BIT_MASK(GTHE3_CH_TX_SAMPLE_PERIOD_MSB, GTHE3_CH_TX_SAMPLE_PERIOD_LSB)
#define GTHE3_CH_RXGBOX_FIFO_INIT_RD_ADDR_ADDR 0x00BB
#define GTHE3_CH_RXGBOX_FIFO_INIT_RD_ADDR_MSB 5
#define GTHE3_CH_RXGBOX_FIFO_INIT_RD_ADDR_LSB 3
#define GTHE3_CH_RXGBOX_FIFO_INIT_RD_ADDR_MASK BIT_MASK(GTHE3_CH_RXGBOX_FIFO_INIT_RD_ADDR_MSB, GTHE3_CH_RXGBOX_FIFO_INIT_RD_ADDR_LSB)
#define GTHE3_CH_RX_SAMPLE_PERIOD_ADDR 0x00BB
#define GTHE3_CH_RX_SAMPLE_PERIOD_MSB 2
#define GTHE3_CH_RX_SAMPLE_PERIOD_LSB 0
#define GTHE3_CH_RX_SAMPLE_PERIOD_MASK BIT_MASK(GTHE3_CH_RX_SAMPLE_PERIOD_MSB, GTHE3_CH_RX_SAMPLE_PERIOD_LSB)
#define GTHE3_CH_CPLL_CFG2_ADDR 0x00BC
#define GTHE3_CH_CPLL_CFG2_MSB 15
#define GTHE3_CH_CPLL_CFG2_LSB 0
#define GTHE3_CH_CPLL_CFG2_MASK BIT_MASK(GTHE3_CH_CPLL_CFG2_MSB, GTHE3_CH_CPLL_CFG2_LSB)
#define GTHE3_CH_RXPHSAMP_CFG_ADDR 0x00BD
#define GTHE3_CH_RXPHSAMP_CFG_MSB 15
#define GTHE3_CH_RXPHSAMP_CFG_LSB 0
#define GTHE3_CH_RXPHSAMP_CFG_MASK BIT_MASK(GTHE3_CH_RXPHSAMP_CFG_MSB, GTHE3_CH_RXPHSAMP_CFG_LSB)
#define GTHE3_CH_RXPHSLIP_CFG_ADDR 0x00BE
#define GTHE3_CH_RXPHSLIP_CFG_MSB 15
#define GTHE3_CH_RXPHSLIP_CFG_LSB 0
#define GTHE3_CH_RXPHSLIP_CFG_MASK BIT_MASK(GTHE3_CH_RXPHSLIP_CFG_MSB, GTHE3_CH_RXPHSLIP_CFG_LSB)
#define GTHE3_CH_RXPHBEACON_CFG_ADDR 0x00BF
#define GTHE3_CH_RXPHBEACON_CFG_MSB 15
#define GTHE3_CH_RXPHBEACON_CFG_LSB 0
#define GTHE3_CH_RXPHBEACON_CFG_MASK BIT_MASK(GTHE3_CH_RXPHBEACON_CFG_MSB, GTHE3_CH_RXPHBEACON_CFG_LSB)
#define GTHE3_CH_RXDFE_H7_CFG1_ADDR 0x00C0
#define GTHE3_CH_RXDFE_H7_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H7_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H7_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H7_CFG1_MSB, GTHE3_CH_RXDFE_H7_CFG1_LSB)
#define GTHE3_CH_RXDFE_H8_CFG0_ADDR 0x00C1
#define GTHE3_CH_RXDFE_H8_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H8_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H8_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H8_CFG0_MSB, GTHE3_CH_RXDFE_H8_CFG0_LSB)
#define GTHE3_CH_RXDFE_H8_CFG1_ADDR 0x00C2
#define GTHE3_CH_RXDFE_H8_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H8_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H8_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H8_CFG1_MSB, GTHE3_CH_RXDFE_H8_CFG1_LSB)
#define GTHE3_CH_PCIE_BUFG_DIV_CTRL_ADDR 0x00C3
#define GTHE3_CH_PCIE_BUFG_DIV_CTRL_MSB 15
#define GTHE3_CH_PCIE_BUFG_DIV_CTRL_LSB 0
#define GTHE3_CH_PCIE_BUFG_DIV_CTRL_MASK BIT_MASK(GTHE3_CH_PCIE_BUFG_DIV_CTRL_MSB, GTHE3_CH_PCIE_BUFG_DIV_CTRL_LSB)
#define GTHE3_CH_PCIE_RXPCS_CFG_GEN3_ADDR 0x00C4
#define GTHE3_CH_PCIE_RXPCS_CFG_GEN3_MSB 15
#define GTHE3_CH_PCIE_RXPCS_CFG_GEN3_LSB 0
#define GTHE3_CH_PCIE_RXPCS_CFG_GEN3_MASK BIT_MASK(GTHE3_CH_PCIE_RXPCS_CFG_GEN3_MSB, GTHE3_CH_PCIE_RXPCS_CFG_GEN3_LSB)
#define GTHE3_CH_RXDFE_H9_CFG0_ADDR 0x00C5
#define GTHE3_CH_RXDFE_H9_CFG0_MSB 15
#define GTHE3_CH_RXDFE_H9_CFG0_LSB 0
#define GTHE3_CH_RXDFE_H9_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_H9_CFG0_MSB, GTHE3_CH_RXDFE_H9_CFG0_LSB)
#define GTHE3_CH_RX_PROGDIV_CFG_ADDR 0x00C6
#define GTHE3_CH_RX_PROGDIV_CFG_MSB 15
#define GTHE3_CH_RX_PROGDIV_CFG_LSB 0
#define GTHE3_CH_RX_PROGDIV_CFG_MASK BIT_MASK(GTHE3_CH_RX_PROGDIV_CFG_MSB, GTHE3_CH_RX_PROGDIV_CFG_LSB)
#define GTHE3_CH_RX_PROGDIV_CFG_0 32768
#define GTHE3_CH_RX_PROGDIV_CFG_4 57744
#define GTHE3_CH_RX_PROGDIV_CFG_5 49648
#define GTHE3_CH_RX_PROGDIV_CFG_8 57728
#define GTHE3_CH_RX_PROGDIV_CFG_10 57760
#define GTHE3_CH_RX_PROGDIV_CFG_16 57730
#define GTHE3_CH_RX_PROGDIV_CFG_16P5 49672
#define GTHE3_CH_RX_PROGDIV_CFG_20 57762
#define GTHE3_CH_RX_PROGDIV_CFG_32 57734
#define GTHE3_CH_RX_PROGDIV_CFG_33 49800
#define GTHE3_CH_RX_PROGDIV_CFG_40 57766
#define GTHE3_CH_RX_PROGDIV_CFG_64 57742
#define GTHE3_CH_RX_PROGDIV_CFG_66 50056
#define GTHE3_CH_RX_PROGDIV_CFG_80 57743
#define GTHE3_CH_RX_PROGDIV_CFG_100 57775
#define GTHE3_CH_RXDFE_H9_CFG1_ADDR 0x00C7
#define GTHE3_CH_RXDFE_H9_CFG1_MSB 15
#define GTHE3_CH_RXDFE_H9_CFG1_LSB 0
#define GTHE3_CH_RXDFE_H9_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_H9_CFG1_MSB, GTHE3_CH_RXDFE_H9_CFG1_LSB)
#define GTHE3_CH_RXDFE_HA_CFG0_ADDR 0x00C8
#define GTHE3_CH_RXDFE_HA_CFG0_MSB 15
#define GTHE3_CH_RXDFE_HA_CFG0_LSB 0
#define GTHE3_CH_RXDFE_HA_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_HA_CFG0_MSB, GTHE3_CH_RXDFE_HA_CFG0_LSB)
#define GTHE3_CH_CHAN_BOND_SEQ_1_2_ADDR 0x00CA
#define GTHE3_CH_CHAN_BOND_SEQ_1_2_MSB 9
#define GTHE3_CH_CHAN_BOND_SEQ_1_2_LSB 0
#define GTHE3_CH_CHAN_BOND_SEQ_1_2_MASK BIT_MASK(GTHE3_CH_CHAN_BOND_SEQ_1_2_MSB, GTHE3_CH_CHAN_BOND_SEQ_1_2_LSB)
#define GTHE3_CH_CPLL_CFG0_ADDR 0x00CB
#define GTHE3_CH_CPLL_CFG0_MSB 15
#define GTHE3_CH_CPLL_CFG0_LSB 0
#define GTHE3_CH_CPLL_CFG0_MASK BIT_MASK(GTHE3_CH_CPLL_CFG0_MSB, GTHE3_CH_CPLL_CFG0_LSB)
#define GTHE3_CH_CPLL_CFG1_ADDR 0x00CC
#define GTHE3_CH_CPLL_CFG1_MSB 15
#define GTHE3_CH_CPLL_CFG1_LSB 0
#define GTHE3_CH_CPLL_CFG1_MASK BIT_MASK(GTHE3_CH_CPLL_CFG1_MSB, GTHE3_CH_CPLL_CFG1_LSB)
#define GTHE3_CH_CPLL_INIT_CFG1_ADDR 0x00CD
#define GTHE3_CH_CPLL_INIT_CFG1_MSB 15
#define GTHE3_CH_CPLL_INIT_CFG1_LSB 8
#define GTHE3_CH_CPLL_INIT_CFG1_MASK BIT_MASK(GTHE3_CH_CPLL_INIT_CFG1_MSB, GTHE3_CH_CPLL_INIT_CFG1_LSB)
#define GTHE3_CH_RX_DDI_SEL_ADDR 0x00CD
#define GTHE3_CH_RX_DDI_SEL_MSB 7
#define GTHE3_CH_RX_DDI_SEL_LSB 2
#define GTHE3_CH_RX_DDI_SEL_MASK BIT_MASK(GTHE3_CH_RX_DDI_SEL_MSB, GTHE3_CH_RX_DDI_SEL_LSB)
#define GTHE3_CH_DEC_VALID_COMMA_ONLY_ADDR 0x00CD
#define GTHE3_CH_DEC_VALID_COMMA_ONLY_MSB 1
#define GTHE3_CH_DEC_VALID_COMMA_ONLY_LSB 1
#define GTHE3_CH_DEC_VALID_COMMA_ONLY_MASK BIT_MASK(GTHE3_CH_DEC_VALID_COMMA_ONLY_MSB, GTHE3_CH_DEC_VALID_COMMA_ONLY_LSB)
#define GTHE3_CH_DEC_MCOMMA_DETECT_ADDR 0x00CD
#define GTHE3_CH_DEC_MCOMMA_DETECT_MSB 0
#define GTHE3_CH_DEC_MCOMMA_DETECT_LSB 0
#define GTHE3_CH_DEC_MCOMMA_DETECT_MASK BIT_MASK(GTHE3_CH_DEC_MCOMMA_DETECT_MSB, GTHE3_CH_DEC_MCOMMA_DETECT_LSB)
#define GTHE3_CH_RXDFE_HA_CFG1_ADDR 0x00CE
#define GTHE3_CH_RXDFE_HA_CFG1_MSB 15
#define GTHE3_CH_RXDFE_HA_CFG1_LSB 0
#define GTHE3_CH_RXDFE_HA_CFG1_MASK BIT_MASK(GTHE3_CH_RXDFE_HA_CFG1_MSB, GTHE3_CH_RXDFE_HA_CFG1_LSB)
#define GTHE3_CH_RXDFE_HB_CFG0_ADDR 0x00CF
#define GTHE3_CH_RXDFE_HB_CFG0_MSB 15
#define GTHE3_CH_RXDFE_HB_CFG0_LSB 0
#define GTHE3_CH_RXDFE_HB_CFG0_MASK BIT_MASK(GTHE3_CH_RXDFE_HB_CFG0_MSB, GTHE3_CH_RXDFE_HB_CFG0_LSB)
#define GTHE3_CH_COMMA_ALIGN_LATENCY_ADDR 0x0150
#define GTHE3_CH_COMMA_ALIGN_LATENCY_MSB 6
#define GTHE3_CH_COMMA_ALIGN_LATENCY_LSB 0
#define GTHE3_CH_COMMA_ALIGN_LATENCY_MASK BIT_MASK(GTHE3_CH_COMMA_ALIGN_LATENCY_MSB, GTHE3_CH_COMMA_ALIGN_LATENCY_LSB)
#define GTHE3_CH_ES_ERROR_COUNT_ADDR 0x0151
#define GTHE3_CH_ES_ERROR_COUNT_MSB 15
#define GTHE3_CH_ES_ERROR_COUNT_LSB 0
#define GTHE3_CH_ES_ERROR_COUNT_MASK BIT_MASK(GTHE3_CH_ES_ERROR_COUNT_MSB, GTHE3_CH_ES_ERROR_COUNT_LSB)
#define GTHE3_CH_ES_SAMPLE_COUNT_ADDR 0x0152
#define GTHE3_CH_ES_SAMPLE_COUNT_MSB 15
#define GTHE3_CH_ES_SAMPLE_COUNT_LSB 0
#define GTHE3_CH_ES_SAMPLE_COUNT_MASK BIT_MASK(GTHE3_CH_ES_SAMPLE_COUNT_MSB, GTHE3_CH_ES_SAMPLE_COUNT_LSB)
#define GTHE3_CH_ES_CONTROL_STATUS_ADDR 0x0153
#define GTHE3_CH_ES_CONTROL_STATUS_MSB 3
#define GTHE3_CH_ES_CONTROL_STATUS_LSB 0
#define GTHE3_CH_ES_CONTROL_STATUS_MASK BIT_MASK(GTHE3_CH_ES_CONTROL_STATUS_MSB, GTHE3_CH_ES_CONTROL_STATUS_LSB)
#define GTHE3_CH_ES_RDATA_BYTE4_ADDR 0x0154
#define GTHE3_CH_ES_RDATA_BYTE4_MSB 15
#define GTHE3_CH_ES_RDATA_BYTE4_LSB 0
#define GTHE3_CH_ES_RDATA_BYTE4_MASK BIT_MASK(GTHE3_CH_ES_RDATA_BYTE4_MSB, GTHE3_CH_ES_RDATA_BYTE4_LSB)
#define GTHE3_CH_ES_RDATA_BYTE3_ADDR 0x0155
#define GTHE3_CH_ES_RDATA_BYTE3_MSB 15
#define GTHE3_CH_ES_RDATA_BYTE3_LSB 0
#define GTHE3_CH_ES_RDATA_BYTE3_MASK BIT_MASK(GTHE3_CH_ES_RDATA_BYTE3_MSB, GTHE3_CH_ES_RDATA_BYTE3_LSB)
#define GTHE3_CH_ES_RDATA_BYTE2_ADDR 0x0156
#define GTHE3_CH_ES_RDATA_BYTE2_MSB 15
#define GTHE3_CH_ES_RDATA_BYTE2_LSB 0
#define GTHE3_CH_ES_RDATA_BYTE2_MASK BIT_MASK(GTHE3_CH_ES_RDATA_BYTE2_MSB, GTHE3_CH_ES_RDATA_BYTE2_LSB)
#define GTHE3_CH_ES_RDATA_BYTE1_ADDR 0x0157
#define GTHE3_CH_ES_RDATA_BYTE1_MSB 15
#define GTHE3_CH_ES_RDATA_BYTE1_LSB 0
#define GTHE3_CH_ES_RDATA_BYTE1_MASK BIT_MASK(GTHE3_CH_ES_RDATA_BYTE1_MSB, GTHE3_CH_ES_RDATA_BYTE1_LSB)
#define GTHE3_CH_ES_RDATA_BYTE0_ADDR 0x0158
#define GTHE3_CH_ES_RDATA_BYTE0_MSB 15
#define GTHE3_CH_ES_RDATA_BYTE0_LSB 0
#define GTHE3_CH_ES_RDATA_BYTE0_MASK BIT_MASK(GTHE3_CH_ES_RDATA_BYTE0_MSB, GTHE3_CH_ES_RDATA_BYTE0_LSB)
#define GTHE3_CH_ES_SDATA_BYTE4_ADDR 0x0159
#define GTHE3_CH_ES_SDATA_BYTE4_MSB 15
#define GTHE3_CH_ES_SDATA_BYTE4_LSB 0
#define GTHE3_CH_ES_SDATA_BYTE4_MASK BIT_MASK(GTHE3_CH_ES_SDATA_BYTE4_MSB, GTHE3_CH_ES_SDATA_BYTE4_LSB)
#define GTHE3_CH_ES_SDATA_BYTE3_ADDR 0x015A
#define GTHE3_CH_ES_SDATA_BYTE3_MSB 15
#define GTHE3_CH_ES_SDATA_BYTE3_LSB 0
#define GTHE3_CH_ES_SDATA_BYTE3_MASK BIT_MASK(GTHE3_CH_ES_SDATA_BYTE3_MSB, GTHE3_CH_ES_SDATA_BYTE3_LSB)
#define GTHE3_CH_ES_SDATA_BYTE2_ADDR 0x015B
#define GTHE3_CH_ES_SDATA_BYTE2_MSB 15
#define GTHE3_CH_ES_SDATA_BYTE2_LSB 0
#define GTHE3_CH_ES_SDATA_BYTE2_MASK BIT_MASK(GTHE3_CH_ES_SDATA_BYTE2_MSB, GTHE3_CH_ES_SDATA_BYTE2_LSB)
#define GTHE3_CH_ES_SDATA_BYTE1_ADDR 0x015C
#define GTHE3_CH_ES_SDATA_BYTE1_MSB 15
#define GTHE3_CH_ES_SDATA_BYTE1_LSB 0
#define GTHE3_CH_ES_SDATA_BYTE1_MASK BIT_MASK(GTHE3_CH_ES_SDATA_BYTE1_MSB, GTHE3_CH_ES_SDATA_BYTE1_LSB)
#define GTHE3_CH_ES_SDATA_BYTE0_ADDR 0x015D
#define GTHE3_CH_ES_SDATA_BYTE0_MSB 15
#define GTHE3_CH_ES_SDATA_BYTE0_LSB 0
#define GTHE3_CH_ES_SDATA_BYTE0_MASK BIT_MASK(GTHE3_CH_ES_SDATA_BYTE0_MSB, GTHE3_CH_ES_SDATA_BYTE0_LSB)
#define GTHE3_CH_RX_PRBS_ERR_CNT_L_ADDR 0x015E
#define GTHE3_CH_RX_PRBS_ERR_CNT_L_MSB 15
#define GTHE3_CH_RX_PRBS_ERR_CNT_L_LSB 0
#define GTHE3_CH_RX_PRBS_ERR_CNT_L_MASK BIT_MASK(GTHE3_CH_RX_PRBS_ERR_CNT_L_MSB, GTHE3_CH_RX_PRBS_ERR_CNT_L_LSB)
#define GTHE3_CH_RX_PRBS_ERR_CNT_H_ADDR 0x015F
#define GTHE3_CH_RX_PRBS_ERR_CNT_H_MSB 15
#define GTHE3_CH_RX_PRBS_ERR_CNT_H_LSB 0
#define GTHE3_CH_RX_PRBS_ERR_CNT_H_MASK BIT_MASK(GTHE3_CH_RX_PRBS_ERR_CNT_H_MSB, GTHE3_CH_RX_PRBS_ERR_CNT_H_LSB)
#define GTHE3_CH_TXGBOX_FIFO_LATENCY_ADDR 0x0163
#define GTHE3_CH_TXGBOX_FIFO_LATENCY_MSB 15
#define GTHE3_CH_TXGBOX_FIFO_LATENCY_LSB 0
#define GTHE3_CH_TXGBOX_FIFO_LATENCY_MASK BIT_MASK(GTHE3_CH_TXGBOX_FIFO_LATENCY_MSB, GTHE3_CH_TXGBOX_FIFO_LATENCY_LSB)
#define GTHE3_CH_RXGBOX_FIFO_LATENCY_ADDR 0x0169
#define GTHE3_CH_RXGBOX_FIFO_LATENCY_MSB 15
#define GTHE3_CH_RXGBOX_FIFO_LATENCY_LSB 0
#define GTHE3_CH_RXGBOX_FIFO_LATENCY_MASK BIT_MASK(GTHE3_CH_RXGBOX_FIFO_LATENCY_MSB, GTHE3_CH_RXGBOX_FIFO_LATENCY_LSB)
#endif /* GTHE3_REGS_H */
|
e14d97e63508284a16c449150d0697e792e6e85f
|
321d11eaee885ceb3a74db0a062f9bbdf282148c
|
/include/internal/thread_once.h
|
d6cb2eeec3bc1065b27882f0ab0432b06a564bfb
|
[
"Apache-2.0",
"OpenSSL",
"LicenseRef-scancode-proprietary-license"
] |
permissive
|
openssl/openssl
|
75691ebaae957793f2ff0673f77545277dfb3988
|
5318c012885a5382eadbf95aa9c1d35664bca819
|
refs/heads/master
| 2023-09-03T15:22:52.727123
| 2023-09-01T07:10:49
| 2023-09-02T14:30:01
| 7,634,677
| 24,148
| 11,569
|
Apache-2.0
| 2023-09-14T19:48:11
| 2013-01-15T22:34:48
|
C
|
UTF-8
|
C
| false
| false
| 5,660
|
h
|
thread_once.h
|
/*
* Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the Apache License 2.0 (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
* in the file LICENSE in the source distribution or at
* https://www.openssl.org/source/license.html
*/
#ifndef OSSL_INTERNAL_THREAD_ONCE_H
# define OSSL_INTERNAL_THREAD_ONCE_H
# pragma once
# include <openssl/crypto.h>
/*
* Initialisation of global data should never happen via "RUN_ONCE" inside the
* FIPS module. Global data should instead always be associated with a specific
* OSSL_LIB_CTX object. In this way data will get cleaned up correctly when the
* module gets unloaded.
*/
# if !defined(FIPS_MODULE) || defined(ALLOW_RUN_ONCE_IN_FIPS)
/*
* DEFINE_RUN_ONCE: Define an initialiser function that should be run exactly
* once. It takes no arguments and returns an int result (1 for success or
* 0 for failure). Typical usage might be:
*
* DEFINE_RUN_ONCE(myinitfunc)
* {
* do_some_initialisation();
* if (init_is_successful())
* return 1;
*
* return 0;
* }
*/
# define DEFINE_RUN_ONCE(init) \
static int init(void); \
int init##_ossl_ret_ = 0; \
void init##_ossl_(void) \
{ \
init##_ossl_ret_ = init(); \
} \
static int init(void)
/*
* DECLARE_RUN_ONCE: Declare an initialiser function that should be run exactly
* once that has been defined in another file via DEFINE_RUN_ONCE().
*/
# define DECLARE_RUN_ONCE(init) \
extern int init##_ossl_ret_; \
void init##_ossl_(void);
/*
* DEFINE_RUN_ONCE_STATIC: Define an initialiser function that should be run
* exactly once. This function will be declared as static within the file. It
* takes no arguments and returns an int result (1 for success or 0 for
* failure). Typical usage might be:
*
* DEFINE_RUN_ONCE_STATIC(myinitfunc)
* {
* do_some_initialisation();
* if (init_is_successful())
* return 1;
*
* return 0;
* }
*/
# define DEFINE_RUN_ONCE_STATIC(init) \
static int init(void); \
static int init##_ossl_ret_ = 0; \
static void init##_ossl_(void) \
{ \
init##_ossl_ret_ = init(); \
} \
static int init(void)
/*
* DEFINE_RUN_ONCE_STATIC_ALT: Define an alternative initialiser function. This
* function will be declared as static within the file. It takes no arguments
* and returns an int result (1 for success or 0 for failure). An alternative
* initialiser function is expected to be associated with a primary initialiser
* function defined via DEFINE_ONCE_STATIC where both functions use the same
* CRYPTO_ONCE object to synchronise. Where an alternative initialiser function
* is used only one of the primary or the alternative initialiser function will
* ever be called - and that function will be called exactly once. Definition
* of an alternative initialiser function MUST occur AFTER the definition of the
* primary initialiser function.
*
* Typical usage might be:
*
* DEFINE_RUN_ONCE_STATIC(myinitfunc)
* {
* do_some_initialisation();
* if (init_is_successful())
* return 1;
*
* return 0;
* }
*
* DEFINE_RUN_ONCE_STATIC_ALT(myaltinitfunc, myinitfunc)
* {
* do_some_alternative_initialisation();
* if (init_is_successful())
* return 1;
*
* return 0;
* }
*/
# define DEFINE_RUN_ONCE_STATIC_ALT(initalt, init) \
static int initalt(void); \
static void initalt##_ossl_(void) \
{ \
init##_ossl_ret_ = initalt(); \
} \
static int initalt(void)
/*
* RUN_ONCE - use CRYPTO_THREAD_run_once, and check if the init succeeded
* @once: pointer to static object of type CRYPTO_ONCE
* @init: function name that was previously given to DEFINE_RUN_ONCE,
* DEFINE_RUN_ONCE_STATIC or DECLARE_RUN_ONCE. This function
* must return 1 for success or 0 for failure.
*
* The return value is 1 on success (*) or 0 in case of error.
*
* (*) by convention, since the init function must return 1 on success.
*/
# define RUN_ONCE(once, init) \
(CRYPTO_THREAD_run_once(once, init##_ossl_) ? init##_ossl_ret_ : 0)
/*
* RUN_ONCE_ALT - use CRYPTO_THREAD_run_once, to run an alternative initialiser
* function and check if that initialisation succeeded
* @once: pointer to static object of type CRYPTO_ONCE
* @initalt: alternative initialiser function name that was previously given to
* DEFINE_RUN_ONCE_STATIC_ALT. This function must return 1 for
* success or 0 for failure.
* @init: primary initialiser function name that was previously given to
* DEFINE_RUN_ONCE_STATIC. This function must return 1 for success or
* 0 for failure.
*
* The return value is 1 on success (*) or 0 in case of error.
*
* (*) by convention, since the init function must return 1 on success.
*/
# define RUN_ONCE_ALT(once, initalt, init) \
(CRYPTO_THREAD_run_once(once, initalt##_ossl_) ? init##_ossl_ret_ : 0)
# endif /* FIPS_MODULE */
#endif /* OSSL_INTERNAL_THREAD_ONCE_H */
|
9ab239413de7ab9985c9a21337a29794e02bfaf0
|
d6819033d5c0d68ec0522c872c057c00da6b2789
|
/modules/src/ll.c
|
6b1fa723fa047615b3469ed92237c10ff6f3de05
|
[
"MIT"
] |
permissive
|
29jm/SnowflakeOS
|
d9b0c2a12f03c0b1e5a5f61477f802d2f653be94
|
fe51e646a78bf4ccee45e5e563cd3a25d76f7690
|
refs/heads/master
| 2023-07-11T02:26:32.590836
| 2023-06-28T00:00:58
| 2023-07-07T13:57:08
| 38,449,214
| 356
| 26
|
MIT
| 2023-06-28T00:08:44
| 2015-07-02T18:18:01
|
C
|
UTF-8
|
C
| false
| false
| 1,526
|
c
|
ll.c
|
#include <dirent.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include <unistd.h>
#define STATR 4
#define STATW 2
#define STATX 1
#include <snow.h>
int main(int argc, char* argv[]) {
char dir[MAX_PATH] = "";
if (argc > 1) {
if (!strcmp(argv[1], "--help")) {
printf("usage: %s [ dir ]\n", argv[0]);
return 0;
}
strcpy(dir, argv[1]);
} else {
getcwd(dir, MAX_PATH);
}
DIR* d = opendir(dir);
struct dirent* dent = NULL;
struct stat statent;
char sec[11] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
if (!d) {
printf("%s: failed to open '%s'\n", argv[0], dir);
return 1;
}
printf("\n");
while ((dent = readdir(d))) {
stat(dent->d_name, &statent);
sec[0] = dent->d_type == 2 ? 'd' : '-';
sec[1] = statent.st_mode & (STATR << 6) ? 'r' : '-';
sec[4] = statent.st_mode & (STATR << 3) ? 'r' : '-';
sec[7] = statent.st_mode & STATR ? 'r' : '-';
sec[2] = statent.st_mode & (STATW << 6) ? 'w' : '-';
sec[5] = statent.st_mode & (STATW << 3) ? 'w' : '-';
sec[8] = statent.st_mode & STATW ? 'w' : '-';
sec[3] = statent.st_mode & (STATX << 6) ? 'x' : '-';
sec[6] = statent.st_mode & (STATX << 3) ? 'x' : '-';
sec[9] = statent.st_mode & STATX ? 'x' : '-';
sec[10] = 0;
printf("%-11s %-16s %10u\n", sec, dent->d_name, statent.st_size);
free(dent);
}
return 0;
}
|
6c89738729673d433b8a25c470c39373b6c07ca8
|
fef5296397f9b950a11455e880a919537390aea0
|
/nbi/engine/native/launcher/windows/src/FileUtils.h
|
0b01ace4585af3b3235a9e8a6743bd947204f547
|
[
"Apache-2.0"
] |
permissive
|
apache/netbeans
|
5a4d6fa9e4f230b33e44519a479d66e47a381289
|
28d308b400bbe439ac0ac84b64d823ce0b69272e
|
refs/heads/master
| 2023-08-29T15:32:41.838270
| 2023-08-29T09:48:59
| 2023-08-29T09:48:59
| 102,083,576
| 1,692
| 718
|
Apache-2.0
| 2023-09-14T19:41:05
| 2017-09-01T07:00:11
|
Java
|
UTF-8
|
C
| false
| false
| 2,660
|
h
|
FileUtils.h
|
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you 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.
*/
#ifndef _FileUtils_H
#define _FileUtils_H
#include <windows.h>
#include "Errors.h"
#include "Types.h"
#ifdef __cplusplus
extern "C" {
#endif
#define OUTPUT_LEVEL_DEBUG 0
#define OUTPUT_LEVEL_NORMAL 1
extern const WCHAR * FILE_SEP;
extern const long CRC32_TABLE[256];
void update_crc32(DWORD * crc32, char * buf, DWORD size);
int64t * getFreeSpace(WCHAR *path);
int64t * getFileSize(WCHAR * path);
void checkFreeSpace(LauncherProperties * props, WCHAR * tmpDir, int64t * size);
WCHAR * getParentDirectory(WCHAR * dir);
void createDirectory(LauncherProperties * props, WCHAR * directory);
void createTempDirectory(LauncherProperties * props, WCHAR * argTempDir, DWORD createRndSubDir);
void deleteDirectory(LauncherProperties * props,WCHAR * dir);
WCHAR * getExePath();
WCHAR * getExeName();
WCHAR * getExeDirectory();
WCHAR * getSystemTemporaryDirectory();
DWORD isDirectory(WCHAR *path);
WCHAR * getCurrentDirectory();
WCHAR * getCurrentUserHome();
void writeMessageW(LauncherProperties * props, DWORD level,DWORD isErr, const WCHAR * message, DWORD needEndOfLine);
void writeMessageA(LauncherProperties * props,DWORD level, DWORD isErr, const char * message, DWORD needEndOfLine);
void writeErrorA(LauncherProperties * props,DWORD level, DWORD isErr, const char * message, const WCHAR * param, DWORD errorCode);
void writeDWORD(LauncherProperties * props,DWORD level, DWORD isErr, const char * message, DWORD value, DWORD needEndOfLine);
void writeint64t(LauncherProperties * props,DWORD level, DWORD isErr, const char * message, int64t * value, DWORD needEndOfLine);
void flushHandle(HANDLE hd);
DWORD fileExists(WCHAR * path);
#ifdef __cplusplus
}
#endif
#endif /* _FileUtils_H */
|
5f447e26c756a710bbc429aac9af64ccc6b88ee7
|
9467e2502183e843a67736800199e31674b1d8f6
|
/HybridCLRData/LocalIl2CppData-OSXEditor/il2cpp/external/mono/mono/utils/mono-dl-fallback.h
|
0383ad1c9068e6fc6f4bfc3fad0d67622030b721
|
[
"Apache-2.0"
] |
permissive
|
yimengfan/BDFramework.Core
|
3a046fcd755a84ba55d648dd3ad52c37a1cc1a04
|
81380fce8e84367f912777717665b53f074ab617
|
refs/heads/master
| 2023-09-04T10:08:47.644992
| 2023-07-05T16:22:11
| 2023-07-05T16:22:11
| 85,928,537
| 2,421
| 497
|
Apache-2.0
| 2023-03-21T06:56:21
| 2017-03-23T09:03:48
|
C#
|
UTF-8
|
C
| false
| false
| 1,036
|
h
|
mono-dl-fallback.h
|
/**
* \file
*/
#ifndef __MONO_UTILS_DL_FALLBACK_H__
#define __MONO_UTILS_DL_FALLBACK_H__
#include <mono/utils/mono-publib.h>
MONO_BEGIN_DECLS
enum {
MONO_DL_EAGER = 0,
MONO_DL_LAZY = 1,
MONO_DL_LOCAL = 2,
MONO_DL_MASK = 3
};
/*
* This is the dynamic loader fallback API
*/
typedef struct MonoDlFallbackHandler MonoDlFallbackHandler;
/*
* The "err" variable contents must be allocated using g_malloc or g_strdup
*/
typedef void* (*MonoDlFallbackLoad) (const char *name, int flags, char **err, void *user_data);
typedef void* (*MonoDlFallbackSymbol) (void *handle, const char *name, char **err, void *user_data);
typedef void* (*MonoDlFallbackClose) (void *handle, void *user_data);
MONO_API MonoDlFallbackHandler *mono_dl_fallback_register (MonoDlFallbackLoad load_func, MonoDlFallbackSymbol symbol_func,
MonoDlFallbackClose close_func, void *user_data);
MONO_API void mono_dl_fallback_unregister (MonoDlFallbackHandler *handler);
MONO_END_DECLS
#endif /* __MONO_UTILS_DL_FALLBACK_H__ */
|
441273b64bfb673d81b9725c6c1dd73f4ce68fbd
|
e9b2c1f687bb9f34732d7eb2bc784a75705a371e
|
/common/bitmap/test-bitmap.c
|
6b7283ad99351ffa32772bdcd2b1e2dde7bda829
|
[
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
libguestfs/nbdkit
|
30bf70eb29843805597a6bbe5b56cc024bfedead
|
45b72f5bd8fc1b475fa130d06c86cd877bf595d5
|
refs/heads/master
| 2023-09-02T12:48:33.201066
| 2023-03-10T09:59:15
| 2023-03-10T10:08:50
| 10,839,800
| 209
| 45
|
NOASSERTION
| 2021-01-24T00:25:00
| 2013-06-21T09:43:21
|
C
|
UTF-8
|
C
| false
| false
| 4,439
|
c
|
test-bitmap.c
|
/* nbdkit
* Copyright Red Hat
*
* 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 Red Hat 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 RED HAT 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 RED HAT 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.
*/
/* Unit tests of the bitmap code. */
#include <config.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <stdarg.h>
#include <string.h>
#include <errno.h>
#undef NDEBUG /* Keep test strong even for nbdkit built without assertions */
#include <assert.h>
#include <nbdkit-plugin.h>
#include "array-size.h"
#include "bitmap.h"
static void
test (int bpb, int blksize)
{
struct bitmap bm;
const int nr_blocks = 1000;
int blks[] =
{
1, 2, 3, 10, 12,
90, 91, 92, 93, 94, 99,
800, 801, 802, 803,
902, 903, 905, 907, 911, 913, 917, 919, 923, 929,
999
};
unsigned v, vexp;
size_t i, j;
printf ("bpb = %d, blksize = %d\n", bpb, blksize);
fflush (stdout);
bitmap_init (&bm, blksize, bpb);
if (bitmap_resize (&bm, nr_blocks * blksize) == -1)
exit (EXIT_FAILURE);
/* Set some bits at known block numbers. */
for (j = 0; j < ARRAY_SIZE (blks); ++j) {
v = (j & 1) == 0 ? 1 : (1<<bpb) - 1;
bitmap_set_blk (&bm, blks[j], v);
}
/* Check the values of all bits. */
for (i = j = 0; i < nr_blocks; ++i) {
if (i == blks[j]) { /* previously set bit */
vexp = (j & 1) == 0 ? 1 : (1<<bpb) - 1;
v = bitmap_get_blk (&bm, blks[j], 0);
assert (v == vexp);
++j;
}
else { /* unset bit, except it to be zero */
v = bitmap_get_blk (&bm, i, 0);
assert (v == 0);
}
}
/* Same as above, but using bitmap_for macro. */
j = 0;
bitmap_for (&bm, i) {
if (i == blks[j]) { /* previously set bit */
vexp = (j & 1) == 0 ? 1 : (1<<bpb) - 1;
v = bitmap_get_blk (&bm, blks[j], 0);
assert (v == vexp);
++j;
}
else { /* unset bit, expect it to be zero */
v = bitmap_get_blk (&bm, i, 0);
assert (v == 0);
}
}
/* Use bitmap_next to iterate over the non-zero entries in the bitmap. */
i = bitmap_next (&bm, 0);
j = 0;
while (i != -1) {
assert (i == blks[j]);
vexp = (j & 1) == 0 ? 1 : (1<<bpb) - 1;
v = bitmap_get_blk (&bm, i, 0);
assert (v == vexp);
i = bitmap_next (&bm, i+1);
++j;
}
bitmap_free (&bm);
}
int
main (void)
{
int bpb;
size_t i;
int blksizes[] = { 1, 2, 4, 1024, 2048, 4096, 16384 };
/* Try the tests at each bpb setting and at a range of block sizes. */
for (bpb = 1; bpb <= 8; bpb <<= 1)
for (i = 0; i < sizeof blksizes / sizeof blksizes[0]; ++i)
test (bpb, blksizes[i]);
exit (EXIT_SUCCESS);
}
/* The bitmap code uses nbdkit_debug, normally provided by the main
* server program. So we have to provide it here.
*/
void
nbdkit_debug (const char *fs, ...)
{
/* do nothing */
}
/* Same for nbdkit_error. */
void
nbdkit_error (const char *fs, ...)
{
int err = errno;
va_list args;
va_start (args, fs);
fprintf (stderr, "error: ");
errno = err; /* Must restore in case fs contains %m */
vfprintf (stderr, fs, args);
fprintf (stderr, "\n");
va_end (args);
errno = err;
}
|
6220ae5cf499e003863cf015d3fdf24625c13690
|
450916eee7580beb928ed8f387db4f0a8c1aa508
|
/src/amuse/community/athena/src/athena/src/integrators/prototypes.h
|
44079a4957f0355088a48384299ee55112963299
|
[
"GPL-1.0-or-later",
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer"
] |
permissive
|
amusecode/amuse
|
42095545893f5a86ea79c2a52ce54d3ce8eb204f
|
b57c1e2fda1457d5025307be105c2aa59b19b574
|
refs/heads/main
| 2023-08-31T04:50:48.880044
| 2023-08-30T12:00:20
| 2023-08-30T12:00:20
| 18,516,331
| 158
| 118
|
Apache-2.0
| 2023-08-30T12:00:22
| 2014-04-07T12:35:07
|
AMPL
|
UTF-8
|
C
| false
| false
| 1,151
|
h
|
prototypes.h
|
#ifndef INTEGRATORS_PROTOTYPES_H
#define INTEGRATORS_PROTOTYPES_H
#include "../copyright.h"
/*============================================================================*/
/*! \file prototypes.h
* \brief Prototypes for all public functions in the /src/integrators dir */
/*============================================================================*/
#include <stdio.h>
#include <stdarg.h>
#include "../athena.h"
#include "../defs.h"
#include "../config.h"
/* integrate.c */
VDFun_t integrate_init(MeshS *pM);
void integrate_destruct(void);
/* integrate_1d_ctu.c and integrate_1d_vl.c */
void integrate_destruct_1d(void);
void integrate_init_1d(MeshS *pM);
void integrate_1d_ctu(DomainS *pD);
void integrate_1d_vl(DomainS *pD);
/* integrate_2d_ctu.c and integrate_2d_vl.c */
void integrate_destruct_2d(void);
void integrate_init_2d(MeshS *pM);
void integrate_2d_ctu(DomainS *pD);
void integrate_2d_vl(DomainS *pD);
/* integrate_3d_ctu.c and integrate_3d_vl.c */
void integrate_destruct_3d(void);
void integrate_init_3d(MeshS *pM);
void integrate_3d_ctu(DomainS *pD);
void integrate_3d_vl(DomainS *pD);
#endif /* INTEGRATORS_PROTOTYPES_H */
|
525ae8a355b6d6457942c3080efd73928d54c328
|
7eaf54a78c9e2117247cb2ab6d3a0c20719ba700
|
/SOFTWARE/A64-TERES/linux-a64/drivers/atm/eni.h
|
565e53a5cb7882984358eea9517700991d1f798f
|
[
"Linux-syscall-note",
"GPL-2.0-only",
"GPL-1.0-or-later",
"GPL-2.0-or-later",
"LicenseRef-scancode-free-unknown",
"Apache-2.0"
] |
permissive
|
OLIMEX/DIY-LAPTOP
|
ae82f4ee79c641d9aee444db9a75f3f6709afa92
|
a3fafd1309135650bab27f5eafc0c32bc3ca74ee
|
refs/heads/rel3
| 2023-08-04T01:54:19.483792
| 2023-04-03T07:18:12
| 2023-04-03T07:18:12
| 80,094,055
| 507
| 92
|
Apache-2.0
| 2023-04-03T07:05:59
| 2017-01-26T07:25:50
|
C
|
UTF-8
|
C
| false
| false
| 4,718
|
h
|
eni.h
|
/* drivers/atm/eni.h - Efficient Networks ENI155P device driver declarations */
/* Written 1995-2000 by Werner Almesberger, EPFL LRC/ICA */
#ifndef DRIVER_ATM_ENI_H
#define DRIVER_ATM_ENI_H
#include <linux/atm.h>
#include <linux/atmdev.h>
#include <linux/interrupt.h>
#include <linux/sonet.h>
#include <linux/skbuff.h>
#include <linux/time.h>
#include <linux/pci.h>
#include <linux/spinlock.h>
#include <linux/atomic.h>
#include "midway.h"
#define DEV_LABEL "eni"
#define UBR_BUFFER (128*1024) /* UBR buffer size */
#define RX_DMA_BUF 8 /* burst and skip a few things */
#define TX_DMA_BUF 100 /* should be enough for 64 kB */
#define DEFAULT_RX_MULT 300 /* max_sdu*3 */
#define DEFAULT_TX_MULT 300 /* max_sdu*3 */
#define ENI_ZEROES_SIZE 4 /* need that many DMA-able zero bytes */
struct eni_free {
void __iomem *start; /* counting in bytes */
int order;
};
struct eni_tx {
void __iomem *send; /* base, 0 if unused */
int prescaler; /* shaping prescaler */
int resolution; /* shaping divider */
unsigned long tx_pos; /* current TX write position */
unsigned long words; /* size of TX queue */
int index; /* TX channel number */
int reserved; /* reserved peak cell rate */
int shaping; /* shaped peak cell rate */
struct sk_buff_head backlog; /* queue of waiting TX buffers */
};
struct eni_vcc {
int (*rx)(struct atm_vcc *vcc); /* RX function, NULL if none */
void __iomem *recv; /* receive buffer */
unsigned long words; /* its size in words */
unsigned long descr; /* next descriptor (RX) */
unsigned long rx_pos; /* current RX descriptor pos */
struct eni_tx *tx; /* TXer, NULL if none */
int rxing; /* number of pending PDUs */
int servicing; /* number of waiting VCs (0 or 1) */
int txing; /* number of pending TX bytes */
ktime_t timestamp; /* for RX timing */
struct atm_vcc *next; /* next pending RX */
struct sk_buff *last; /* last PDU being DMAed (used to carry
discard information) */
};
struct eni_dev {
/*-------------------------------- spinlock */
spinlock_t lock; /* sync with interrupt */
struct tasklet_struct task; /* tasklet for interrupt work */
u32 events; /* pending events */
/*-------------------------------- base pointers into Midway address
space */
void __iomem *ioaddr;
void __iomem *phy; /* PHY interface chip registers */
void __iomem *reg; /* register base */
void __iomem *ram; /* RAM base */
void __iomem *vci; /* VCI table */
void __iomem *rx_dma; /* RX DMA queue */
void __iomem *tx_dma; /* TX DMA queue */
void __iomem *service; /* service list */
/*-------------------------------- TX part */
struct eni_tx tx[NR_CHAN]; /* TX channels */
struct eni_tx *ubr; /* UBR channel */
struct sk_buff_head tx_queue; /* PDUs currently being TX DMAed*/
wait_queue_head_t tx_wait; /* for close */
int tx_bw; /* remaining bandwidth */
u32 dma[TX_DMA_BUF*2]; /* DMA request scratch area */
struct eni_zero { /* aligned "magic" zeroes */
u32 *addr;
dma_addr_t dma;
} zero;
int tx_mult; /* buffer size multiplier (percent) */
/*-------------------------------- RX part */
u32 serv_read; /* host service read index */
struct atm_vcc *fast,*last_fast;/* queues of VCCs with pending PDUs */
struct atm_vcc *slow,*last_slow;
struct atm_vcc **rx_map; /* for fast lookups */
struct sk_buff_head rx_queue; /* PDUs currently being RX-DMAed */
wait_queue_head_t rx_wait; /* for close */
int rx_mult; /* buffer size multiplier (percent) */
/*-------------------------------- statistics */
unsigned long lost; /* number of lost cells (RX) */
/*-------------------------------- memory management */
unsigned long base_diff; /* virtual-real base address */
int free_len; /* free list length */
struct eni_free *free_list; /* free list */
int free_list_size; /* maximum size of free list */
/*-------------------------------- ENI links */
struct atm_dev *more; /* other ENI devices */
/*-------------------------------- general information */
int mem; /* RAM on board (in bytes) */
int asic; /* PCI interface type, 0 for FPGA */
unsigned int irq; /* IRQ */
struct pci_dev *pci_dev; /* PCI stuff */
};
#define ENI_DEV(d) ((struct eni_dev *) (d)->dev_data)
#define ENI_VCC(d) ((struct eni_vcc *) (d)->dev_data)
struct eni_skb_prv {
struct atm_skb_data _; /* reserved */
unsigned long pos; /* position of next descriptor */
int size; /* PDU size in reassembly buffer */
dma_addr_t paddr; /* DMA handle */
};
#define ENI_PRV_SIZE(skb) (((struct eni_skb_prv *) (skb)->cb)->size)
#define ENI_PRV_POS(skb) (((struct eni_skb_prv *) (skb)->cb)->pos)
#define ENI_PRV_PADDR(skb) (((struct eni_skb_prv *) (skb)->cb)->paddr)
#endif
|
454766e4f75875144743ad8dbcbd72fb95f7f94c
|
f342990997706a962df8a42867fa1b46da2d2a0d
|
/Pods/Headers/Private/ReactiveCocoa/UIStepper+RACSignalSupport.h
|
e79c4c9acc88cfe46cdb20fe7a293e40cd240f3c
|
[
"MIT"
] |
permissive
|
MarcoSero/HackerNews
|
11cd793a475fc6e875705035046f20dcce16b13a
|
92822de869c7eaaed751be98be9d0059391e5017
|
refs/heads/master
| 2021-01-21T01:59:36.492767
| 2016-03-05T10:51:02
| 2016-03-05T10:51:02
| 39,442,230
| 128
| 18
| null | 2016-03-05T10:51:05
| 2015-07-21T11:46:27
|
HTML
|
UTF-8
|
C
| false
| false
| 77
|
h
|
UIStepper+RACSignalSupport.h
|
../../../ReactiveCocoa/ReactiveCocoa/Objective-C/UIStepper+RACSignalSupport.h
|
a4fc5debb1d29e3cc7887c25396f4753f5374481
|
693bd39eb66eade67997bc608fe84e76e66eeec2
|
/mpp/hal/rkdec/h264d/hal_h264d_api.c
|
160356352c2059b3717226afbe063ee815935577
|
[] |
permissive
|
HermanChen/mpp
|
6a1751777b120b764f86e0f34975231054a3c262
|
0af9b5becc76c4685831214808e124e65543297b
|
refs/heads/develop
| 2023-08-17T07:17:49.489974
| 2023-07-31T08:26:14
| 2023-08-11T07:38:17
| 71,088,248
| 139
| 79
|
Apache-2.0
| 2023-03-08T09:44:01
| 2016-10-17T01:13:37
|
C
|
UTF-8
|
C
| false
| false
| 10,512
|
c
|
hal_h264d_api.c
|
/*
*
* Copyright 2015 Rockchip Electronics Co. LTD
*
* 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.
*/
#define MODULE_TAG "hal_h264d_api"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <dlfcn.h>
#include <unistd.h>
#include "mpp_mem.h"
#include "mpp_env.h"
#include "mpp_platform.h"
#include "mpp_common.h"
#include "osal_2str.h"
#include "dxva_syntax.h"
#include "h264d_syntax.h"
#include "hal_h264d_global.h"
#include "hal_h264d_api.h"
#include "hal_h264d_rkv_reg.h"
#include "hal_h264d_vdpu34x.h"
#include "hal_h264d_vdpu382.h"
#include "hal_h264d_vdpu2.h"
#include "hal_h264d_vdpu1.h"
RK_U32 hal_h264d_debug = 0;
static void explain_input_buffer(void *hal, HalDecTask *task)
{
RK_U32 i = 0;
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
DXVA2_DecodeBufferDesc *pdes = (DXVA2_DecodeBufferDesc *)task->syntax.data;
for (i = 0; i < task->syntax.number; i++) {
switch (pdes[i].CompressedBufferType) {
case DXVA2_PictureParametersBufferType:
p_hal->pp = (DXVA_PicParams_H264_MVC *)pdes[i].pvPVPState;
break;
case DXVA2_InverseQuantizationMatrixBufferType:
p_hal->qm = (DXVA_Qmatrix_H264 *)pdes[i].pvPVPState;
break;
case DXVA2_SliceControlBufferType:
p_hal->slice_num = pdes[i].DataSize / sizeof(DXVA_Slice_H264_Long);
p_hal->slice_long = (DXVA_Slice_H264_Long *)pdes[i].pvPVPState;
break;
case DXVA2_BitStreamDateBufferType:
p_hal->bitstream = (RK_U8 *)pdes[i].pvPVPState;
p_hal->strm_len = pdes[i].DataSize;
break;
default:
break;
}
}
}
/*!
***********************************************************************
* \brief
* init
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_init(void *hal, MppHalCfg *cfg)
{
MppHalApi *p_api = NULL;
MPP_RET ret = MPP_ERR_UNKNOW;
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
MppClientType client_type = VPU_CLIENT_BUTT;
INP_CHECK(ret, NULL == p_hal);
memset(p_hal, 0, sizeof(H264dHalCtx_t));
//!< choose hard mode
{
RK_S32 hw_type = -1;
RK_U32 mode = MODE_NULL;
RK_U32 vcodec_type = mpp_get_vcodec_type();
// check codec_type
if (!(vcodec_type & (HAVE_RKVDEC | HAVE_VDPU1 | HAVE_VDPU2))) {
mpp_err_f("can not found H.264 decoder hardware on platform %x\n", vcodec_type);
return ret;
}
mpp_env_get_u32("use_mpp_mode", &mode, MODE_NULL);
if (MODE_NULL == mode) {
MppDecBaseCfg *base = &cfg->cfg->base;
if (mpp_check_soc_cap(base->type, base->coding))
hw_type = base->hw_type;
if (hw_type > 0) {
if (vcodec_type & (1 << hw_type)) {
mpp_log("init with %s hw\n", strof_client_type(hw_type));
client_type = hw_type;
} else
mpp_err_f("invalid hw_type %d with vcodec_type %08x\n",
hw_type, vcodec_type);
}
}
if (client_type == VPU_CLIENT_BUTT) {
if ((mode <= RKVDEC_MODE) && (vcodec_type & HAVE_RKVDEC)) {
client_type = VPU_CLIENT_RKVDEC;
} else if (vcodec_type & HAVE_VDPU1) {
client_type = VPU_CLIENT_VDPU1;
} else if (vcodec_type & HAVE_VDPU2) {
client_type = VPU_CLIENT_VDPU2;
}
}
H264D_DBG(H264D_DBG_HARD_MODE, "client_type %d\n", client_type);
}
p_api = &p_hal->hal_api;
switch (client_type) {
case VPU_CLIENT_RKVDEC : {
RK_U32 hw_id = mpp_get_client_hw_id(client_type);
if (hw_id == HWID_VDPU382_RK3528 || hw_id == HWID_VDPU382_RK3562) {
p_api->init = vdpu382_h264d_init;
p_api->deinit = vdpu382_h264d_deinit;
p_api->reg_gen = vdpu382_h264d_gen_regs;
p_api->start = vdpu382_h264d_start;
p_api->wait = vdpu382_h264d_wait;
p_api->reset = vdpu382_h264d_reset;
p_api->flush = vdpu382_h264d_flush;
p_api->control = vdpu382_h264d_control;
} else if (hw_id == HWID_VDPU34X || hw_id == HWID_VDPU38X) {
p_api->init = vdpu34x_h264d_init;
p_api->deinit = vdpu34x_h264d_deinit;
p_api->reg_gen = vdpu34x_h264d_gen_regs;
p_api->start = vdpu34x_h264d_start;
p_api->wait = vdpu34x_h264d_wait;
p_api->reset = vdpu34x_h264d_reset;
p_api->flush = vdpu34x_h264d_flush;
p_api->control = vdpu34x_h264d_control;
} else {
p_api->init = rkv_h264d_init;
p_api->deinit = rkv_h264d_deinit;
p_api->reg_gen = rkv_h264d_gen_regs;
p_api->start = rkv_h264d_start;
p_api->wait = rkv_h264d_wait;
p_api->reset = rkv_h264d_reset;
p_api->flush = rkv_h264d_flush;
p_api->control = rkv_h264d_control;
}
cfg->support_fast_mode = 1;
} break;
case VPU_CLIENT_VDPU1 : {
p_api->init = vdpu1_h264d_init;
p_api->deinit = vdpu1_h264d_deinit;
p_api->reg_gen = vdpu1_h264d_gen_regs;
p_api->start = vdpu1_h264d_start;
p_api->wait = vdpu1_h264d_wait;
p_api->reset = vdpu1_h264d_reset;
p_api->flush = vdpu1_h264d_flush;
p_api->control = vdpu1_h264d_control;
} break;
case VPU_CLIENT_VDPU2 : {
p_api->init = vdpu2_h264d_init;
p_api->deinit = vdpu2_h264d_deinit;
p_api->reg_gen = vdpu2_h264d_gen_regs;
p_api->start = vdpu2_h264d_start;
p_api->wait = vdpu2_h264d_wait;
p_api->reset = vdpu2_h264d_reset;
p_api->flush = vdpu2_h264d_flush;
p_api->control = vdpu2_h264d_control;
} break;
default : {
mpp_err_f("client_type error, value=%d\n", client_type);
mpp_assert(0);
} break;
}
mpp_env_get_u32("hal_h264d_debug", &hal_h264d_debug, 0);
ret = mpp_dev_init(&cfg->dev, client_type);
if (ret) {
mpp_err("mpp_dev_init failed ret: %d\n", ret);
goto __FAILED;
}
//!< callback function to parser module
p_hal->dec_cb = cfg->dec_cb;
p_hal->cfg = cfg->cfg;
p_hal->dev = cfg->dev;
p_hal->frame_slots = cfg->frame_slots;
p_hal->packet_slots = cfg->packet_slots;
p_hal->fast_mode = cfg->cfg->base.fast_parse;
//< get buffer group
if (p_hal->buf_group == NULL) {
FUN_CHECK(ret = mpp_buffer_group_get_internal
(&p_hal->buf_group, MPP_BUFFER_TYPE_ION));
}
//!< run init funtion
FUN_CHECK(ret = p_api->init(hal, cfg));
__RETURN:
return MPP_OK;
__FAILED:
return ret;
}
/*!
***********************************************************************
* \brief
* deinit
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_deinit(void *hal)
{
MPP_RET ret = MPP_ERR_UNKNOW;
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
FUN_CHECK(ret = p_hal->hal_api.deinit(hal));
if (p_hal->dev) {
mpp_dev_deinit(p_hal->dev);
p_hal->dev = NULL;
}
if (p_hal->buf_group) {
FUN_CHECK(ret = mpp_buffer_group_put(p_hal->buf_group));
}
return MPP_OK;
__FAILED:
return ret;
}
/*!
***********************************************************************
* \brief
* generate register
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_gen_regs(void *hal, HalTaskInfo *task)
{
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
explain_input_buffer(hal, &task->dec);
return p_hal->hal_api.reg_gen(hal, task);
}
/*!
***********************************************************************
* \brief h
* start hard
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_start(void *hal, HalTaskInfo *task)
{
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
return p_hal->hal_api.start(hal, task);
}
/*!
***********************************************************************
* \brief
* wait hard
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_wait(void *hal, HalTaskInfo *task)
{
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
return p_hal->hal_api.wait(hal, task);
}
/*!
***********************************************************************
* \brief
* reset
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_reset(void *hal)
{
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
return p_hal->hal_api.reset(hal);
}
/*!
***********************************************************************
* \brief
* flush
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_flush(void *hal)
{
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
return p_hal->hal_api.flush(hal);
}
/*!
***********************************************************************
* \brief
* control
***********************************************************************
*/
//extern "C"
MPP_RET hal_h264d_control(void *hal, MpiCmd cmd_type, void *param)
{
H264dHalCtx_t *p_hal = (H264dHalCtx_t *)hal;
return p_hal->hal_api.control(hal, cmd_type, param);
}
const MppHalApi hal_api_h264d = {
.name = "h264d_rkdec",
.type = MPP_CTX_DEC,
.coding = MPP_VIDEO_CodingAVC,
.ctx_size = sizeof(H264dHalCtx_t),
.flag = 0,
.init = hal_h264d_init,
.deinit = hal_h264d_deinit,
.reg_gen = hal_h264d_gen_regs,
.start = hal_h264d_start,
.wait = hal_h264d_wait,
.reset = hal_h264d_reset,
.flush = hal_h264d_flush,
.control = hal_h264d_control,
};
|
a34e1d17ec8e659f635737f94b8f521929c83eff
|
64b0a5eaa5d9fd71c3d0a4e236bd5f32ba2cef13
|
/src/esp_idf_lmic_config.h
|
ee65f1f3756c3b88f2850006f07072992d327cb0
|
[
"MIT"
] |
permissive
|
manuelbl/ttn-esp32
|
1f8b19cdc1a0c592c27771e997471c01ab0a3f2e
|
89ad39d46313e8944dc125a3dc6f9693d75ad753
|
refs/heads/master
| 2023-07-07T19:35:03.486340
| 2023-06-14T20:07:08
| 2023-06-14T20:07:08
| 140,975,542
| 278
| 67
|
MIT
| 2023-08-07T21:04:44
| 2018-07-14T20:21:18
|
C
|
UTF-8
|
C
| false
| false
| 2,096
|
h
|
esp_idf_lmic_config.h
|
/*******************************************************************************
*
* ttn-esp32 - The Things Network device library for ESP-IDF / SX127x
*
* Copyright (c) 2018 Manuel Bleichenbacher
*
* Licensed under MIT License
* https://opensource.org/licenses/MIT
*
* Convert SDK configuration (make menuconfig) into LMIC configuration.
*******************************************************************************/
#include "sdkconfig.h"
#if defined(CONFIG_TTN_LORA_FREQ_EU_868)
#define CFG_eu868 1
#elif defined(CONFIG_TTN_LORA_FREQ_US_915)
#define CFG_us915 1
#elif defined(CONFIG_TTN_LORA_FREQ_AU_921)
#warning \
"CONFIG_TTN_LORA_FREQ_AU_921 was deprecated in favour of CONFIG_TTN_LORA_FREQ_AU_921. Support for CONFIG_TTN_LORA_FREQ_AU_921 will be removed in the future."
#define CFG_au915 1
#elif defined(CONFIG_TTN_LORA_FREQ_AU_915)
#define CFG_au915 1
#elif defined(CONFIG_TTN_LORA_FREQ_AS_923)
#define CFG_as923 1
#elif defined(CONFIG_TTN_LORA_FREQ_AS_923_JP)
#define CFG_as923 1
#define LMIC_COUNTRY_CODE LMIC_COUNTRY_CODE_JP
#elif defined(CONFIG_TTN_LORA_FREQ_KR_920)
#define CFG_kr920 1
#elif defined(CONFIG_TTN_LORA_FREQ_IN_866)
#define CFG_in866 1
#else
#define TTN_IS_DISABLED 1
#define CFG_eu868 1
#endif
#if defined(CONFIG_TTN_RADIO_SX1272_73)
#define CFG_sx1272_radio 1
#elif defined(CONFIG_TTN_RADIO_SX1276_77_78_79)
#define CFG_sx1276_radio 1
#else
#error TTN LoRa radio chip must be configured using 'make menuconfig'
#endif
#if !defined(CONFIG_TTN_PROVISION_UART_NONE)
#define TTN_HAS_AT_COMMANDS 1
#if defined(CONFIG_TTN_PROVISION_UART_CONFIG_YES)
#define TTN_CONFIG_UART 1
#endif
#endif
// 16 μs per tick
// LMIC requires ticks to be 15.5μs - 100 μs long
#define US_PER_OSTICK 16
#define OSTICKS_PER_SEC (1000000 / US_PER_OSTICK)
//#define USE_ORIGINAL_AES
#define USE_MBEDTLS_AES
#if LMIC_DEBUG_LEVEL > 0 || LMIC_X_DEBUG_LEVEL > 0
#include <stdio.h>
#endif
#define LMIC_ENABLE_onEvent 0
#define DISABLE_PING
#define DISABLE_BEACONS
|
492c41e1ef5250c3b4e9656278b586bb38b2d438
|
984bc4181baec6e5a4b05a657e666b0e9f89f3f3
|
/3rdparty/mongo-c-driver-1.21.2/src/libmongoc/examples/example-session.c
|
163e0087386cbc51cf6fd5eb25625ecc9d4b444d
|
[
"Apache-2.0",
"BSD-3-Clause"
] |
permissive
|
treefrogframework/treefrog-framework
|
0173245ff92162d2107af79861505981980d1eca
|
a1df97793e8cc628779378e5adae9af6987460c1
|
refs/heads/master
| 2023-08-22T03:57:58.891846
| 2023-05-18T14:00:42
| 2023-05-18T14:00:42
| 7,067,532
| 1,152
| 263
|
BSD-3-Clause
| 2023-08-08T20:25:03
| 2012-12-08T13:17:01
|
C++
|
UTF-8
|
C
| false
| false
| 3,923
|
c
|
example-session.c
|
/* gcc example-session.c -o example-session \
* $(pkg-config --cflags --libs libmongoc-1.0) */
/* ./example-session [CONNECTION_STRING] */
#include <stdio.h>
#include <mongoc/mongoc.h>
int
main (int argc, char *argv[])
{
int exit_code = EXIT_FAILURE;
mongoc_client_t *client = NULL;
const char *uri_string = "mongodb://127.0.0.1/?appname=session-example";
mongoc_uri_t *uri = NULL;
mongoc_client_session_t *client_session = NULL;
mongoc_collection_t *collection = NULL;
bson_error_t error;
bson_t *selector = NULL;
bson_t *update = NULL;
bson_t *update_opts = NULL;
bson_t *find_opts = NULL;
mongoc_read_prefs_t *secondary = NULL;
mongoc_cursor_t *cursor = NULL;
const bson_t *doc;
char *str;
bool r;
mongoc_init ();
if (argc > 1) {
uri_string = argv[1];
}
uri = mongoc_uri_new_with_error (uri_string, &error);
if (!uri) {
fprintf (stderr,
"failed to parse URI: %s\n"
"error message: %s\n",
uri_string,
error.message);
goto done;
}
client = mongoc_client_new_from_uri (uri);
if (!client) {
goto done;
}
mongoc_client_set_error_api (client, 2);
/* pass NULL for options - by default the session is causally consistent */
client_session = mongoc_client_start_session (client, NULL, &error);
if (!client_session) {
fprintf (stderr, "Failed to start session: %s\n", error.message);
goto done;
}
collection = mongoc_client_get_collection (client, "test", "collection");
selector = BCON_NEW ("_id", BCON_INT32 (1));
update = BCON_NEW ("$inc", "{", "x", BCON_INT32 (1), "}");
update_opts = bson_new ();
if (!mongoc_client_session_append (client_session, update_opts, &error)) {
fprintf (stderr, "Could not add session to opts: %s\n", error.message);
goto done;
}
r = mongoc_collection_update_one (
collection, selector, update, update_opts, NULL /* reply */, &error);
if (!r) {
fprintf (stderr, "Update failed: %s\n", error.message);
goto done;
}
bson_destroy (selector);
selector = BCON_NEW ("_id", BCON_INT32 (1));
secondary = mongoc_read_prefs_new (MONGOC_READ_SECONDARY);
find_opts = BCON_NEW ("maxTimeMS", BCON_INT32 (2000));
if (!mongoc_client_session_append (client_session, find_opts, &error)) {
fprintf (stderr, "Could not add session to opts: %s\n", error.message);
goto done;
};
/* read from secondary. since we're in a causally consistent session, the
* data is guaranteed to reflect the update we did on the primary. the query
* blocks waiting for the secondary to catch up, if necessary, or times out
* and fails after 2000 ms.
*/
cursor = mongoc_collection_find_with_opts (
collection, selector, find_opts, secondary);
while (mongoc_cursor_next (cursor, &doc)) {
str = bson_as_json (doc, NULL);
fprintf (stdout, "%s\n", str);
bson_free (str);
}
if (mongoc_cursor_error (cursor, &error)) {
fprintf (stderr, "Cursor Failure: %s\n", error.message);
goto done;
}
exit_code = EXIT_SUCCESS;
done:
if (find_opts) {
bson_destroy (find_opts);
}
if (update) {
bson_destroy (update);
}
if (selector) {
bson_destroy (selector);
}
if (update_opts) {
bson_destroy (update_opts);
}
if (secondary) {
mongoc_read_prefs_destroy (secondary);
}
/* destroy cursor, collection, session before the client they came from */
if (cursor) {
mongoc_cursor_destroy (cursor);
}
if (collection) {
mongoc_collection_destroy (collection);
}
if (client_session) {
mongoc_client_session_destroy (client_session);
}
if (uri) {
mongoc_uri_destroy (uri);
}
if (client) {
mongoc_client_destroy (client);
}
mongoc_cleanup ();
return exit_code;
}
|
71b84b8d0a29bea7b99d691e68c02748ff3d26d8
|
41c7328eadeab5ed7c0584b7db51996a05dd9f2d
|
/F1:F103/uart/main.c
|
5314846ce1bfa4919c2a9d197f0e57bfde8e376d
|
[] |
no_license
|
eddyem/stm32samples
|
1c00ccb8593ea270cae536c85f178a522f704ed5
|
dce73d358b1fca3e7fa397f5c6d0d5c1cb28aba0
|
refs/heads/master
| 2023-07-28T11:13:10.361942
| 2023-07-24T20:04:22
| 2023-07-24T20:04:22
| 32,647,425
| 152
| 42
| null | null | null | null |
UTF-8
|
C
| false
| false
| 6,301
|
c
|
main.c
|
/*
* main.c
*
* Copyright 2018 Edward V. Emelianov <eddy@sao.ru, edward.emelianoff@gmail.com>
*
* 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 2 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, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
* MA 02110-1301, USA.
*/
#include "stm32f1.h"
#include "usart.h"
// debounce pause (ms - 1)
#define DEBOUNCE_PAUSE (9)
static volatile uint32_t Tms = 0; // milliseconds from last reset
// Called when systick fires
void sys_tick_handler(void){
++Tms;
}
// setup
static void gpio_setup(void){
// Enable clocks to the GPIO subsystems
RCC->APB2ENR |= RCC_APB2ENR_IOPBEN | RCC_APB2ENR_IOPCEN;
// Set leds (PB8/PB9) as opendrain output
GPIOB->CRH = CRH(8, CNF_ODOUTPUT|MODE_SLOW) | CRH(9, CNF_ODOUTPUT|MODE_SLOW);
// Set buttons (PC0/1) as inputs with weak pullups
GPIOC->ODR = 3; // pullups for PC0/1
GPIOC->CRL = CRL(0, CNF_PUDINPUT|MODE_INPUT) | CRL(1, CNF_PUDINPUT|MODE_INPUT);
}
typedef enum{
BTN_PRESSED
,BTN_RELEASED
,BTN_DEBOUNCE
,BTN_RELAX
} button_state;
button_state check_state(uint8_t N){
static uint32_t tlast[2] = {0,0};
static button_state oldstate[2] = {BTN_RELEASED, BTN_RELEASED};
button_state s = BTN_RELAX;
uint8_t b = pin_read(GPIOC, N+1); // == 1 if button released
if(b){
switch(oldstate[N]){
case BTN_PRESSED: // debounce pause for DEBOUNCE_PAUSE ms
s = oldstate[N] = BTN_DEBOUNCE;
tlast[N] = Tms;
break;
case BTN_DEBOUNCE: // check debounce pause
if(Tms - tlast[N] > DEBOUNCE_PAUSE){
s = oldstate[N] = BTN_RELEASED;
}
break;
default: // BTN_RELEASED - do nothing -> return BTN_RELAX
;
}
}else{
switch(oldstate[N]){
case BTN_RELEASED:
s = BTN_PRESSED; // button was just pressed
__attribute__((fallthrough)); // change oldstate too
case BTN_DEBOUNCE: // change old state to BTN_PRESSED again
oldstate[N] = BTN_PRESSED; // returned state still relax
break;
default: // BTN_PRESSED before - do nothing
;
}
}
return s;
}
int main(){
int L;
char *txt;
sysreset();
StartHSE();
gpio_setup();
usart_setup();
uint32_t Told = 0;
SysTick_Config(72000); // interrupt each ms
SEND("Greetings!"); newline();
pin_set(GPIOB, 3<<8); // turn off LEDs
/* Do nothing in main loop */
while (1){
if(Tms - Told > 499){ // blink LED1 every 1 second
pin_toggle(GPIOB, 1<<9);
Told = Tms;
transmit_tbuf();
}
if(usartrx()){ // usart1 received data, store in in buffer
L = usart_getline(&txt);
char _1st = txt[0];
if(L == 2 && txt[1] == '\n'){
L = 0;
switch(_1st){
case '0': // turn off LED2
SEND("LED2 off");
pin_set(GPIOB, 1<<8);
newline();
break;
case '1': // turn it on
SEND("LED2 on");
pin_clear(GPIOB, 1<<8);
newline();
break;
case 's':
case 'S':
SEND("LED2 state: ");
if(pin_read(GPIOB, 1<<8)) SEND("off");
else SEND("on");
newline();
break;
default: // help
SEND(
"'0' - turn off LED2\n"
"'1' - turn on LED2\n"
"'s' - test LED2 state\n"
);
break;
}
}
transmit_tbuf();
}
if(L){ // echo all other data
txt[L] = 0;
usart_send(txt);
transmit_tbuf();
L = 0;
}
for(int i = 0; i < 2; ++i){
const char *st = NULL;
switch(check_state(i)){
case BTN_PRESSED:
st = "pressed";
break;
case BTN_RELEASED:
st = "released";
break;
default:
; // nothing
}
if(st){
SEND("The button");
usart_putchar('2' + i);
SEND(" was ");
SEND(st);
newline();
}
}
/*
uint8_t
if(pin_read(GPIOC, 1) && pin_read(GPIOC, 2)){ // no buttons present - morze @ LED1 (PB9)
if(oldctr != blink_ctr){
uint32_t T = blink_ctr % 18;
systick_setup(L[T]);
if(T & 1) pin_set(GPIOB, 1<<9);
else pin_clear(GPIOB, 1<<9);
oldctr = blink_ctr;
}
}else{ // button pressed: turn ON given LED
if(pin_read(GPIOC, 1) == 0){ // PC0 pressed (button S2)
systick_setup(5);
if(blink_ctr - oldctr > 499){
pin_toggle(GPIOB, 1<<9);
oldctr = blink_ctr;
}
}else pin_set(GPIOB, 1<<9);
if(pin_read(GPIOC, 2) == 0){ // PC1 pressed (button S3)
systick_setup(1);
if(blink_ctr - oldctr > 499){
pin_toggle(GPIOB, 1<<8);
oldctr = blink_ctr;
}
}else pin_set(GPIOB, 1<<8);
}*/
}
}
|
a8b332cbb7d85d9aec379beee5b51968e5c2b2c8
|
c8b39acfd4a857dc15ed3375e0d93e75fa3f1f64
|
/Engine/Plugins/Experimental/AlembicImporter/Source/ThirdParty/Alembic/hdf5/test/tconfig.c
|
14c863e86bc3584c17a036c24a9c27497d632a7d
|
[
"MIT",
"LicenseRef-scancode-proprietary-license"
] |
permissive
|
windystrife/UnrealEngine_NVIDIAGameWorks
|
c3c7863083653caf1bc67d3ef104fb4b9f302e2a
|
b50e6338a7c5b26374d66306ebc7807541ff815e
|
refs/heads/4.18-GameWorks
| 2023-03-11T02:50:08.471040
| 2022-01-13T20:50:29
| 2022-01-13T20:50:29
| 124,100,479
| 262
| 179
|
MIT
| 2022-12-16T05:36:38
| 2018-03-06T15:44:09
|
C++
|
UTF-8
|
C
| false
| false
| 7,082
|
c
|
tconfig.c
|
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
* Copyright by the Board of Trustees of the University of Illinois. *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
* terms governing use, modification, and redistribution, is contained in *
* the files COPYING and Copyright.html. COPYING can be found at the root *
* of the source code distribution tree; Copyright.html can be found at the *
* root level of an installed copy of the electronic HDF5 document set and *
* is linked from the top-level documents page. It can also be found at *
* http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have *
* access to either file, you may request a copy from help@hdfgroup.org. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/***********************************************************
*
* Test program: tconfig
*
* Test the definitions in the H5config.h as much as possible
*
*************************************************************/
#include "hdf5.h"
#include "testhdf5.h"
/* macros definitions */
/* verify C int type: verify the size of signed and unsigned int type
* with the macro size.
*/
#define vrfy_cint_type(ctype, uctype, ctype_macro) \
/* check signed type size */ \
vrfy_macrosize(ctype, ctype_macro, #ctype_macro);\
/* check unsigned type size */ \
vrfy_macrosize(uctype, ctype_macro, #ctype_macro);
/* verify C type sizes: verify the sizeof type with the macro size. */
#define vrfy_ctype(type, macro) \
vrfy_macrosize(type, macro, #macro);
/* verify if the sizeof(type) matches size defined in macro. */
/* Needs this extra step so that we can print the macro name. */
#define vrfy_macrosize(type, macro, macroname) \
if (sizeof(type) != macro) \
TestErrPrintf("Error: sizeof(%s) is %d but %s is %d\n", \
#type, sizeof(type), macroname, macro);
/* local routine prototypes */
void test_config_ctypes(void);
void test_exit_definitions(void);
/*-------------------------------------------------------------------------
* Function: test_configure
*
* Purpose: Main configure definitions testing routine
*
* Return: none (error is fed back via global variable num_errs)
*
* Programmer: Albert Cheng
* September 25, 2001
*
*-------------------------------------------------------------------------
*/
void
test_configure(void)
{
/* Output message about test being performed */
MESSAGE(5, ("Testing configure definitions\n"));
test_config_ctypes();
test_exit_definitions();
}
/*-------------------------------------------------------------------------
* Function: cleanup_configure
*
* Purpose: Cleanup temporary test files
*
* Return: none
*
* Programmer: Albert Cheng
* September 25, 2001
*
* Modifications:
*
*-------------------------------------------------------------------------
*/
void
cleanup_configure(void)
{
/* no file to clean */
}
/*-------------------------------------------------------------------------
* Function: test_config_ctypes
*
* Purpose: test C language data type sizes
*
* Return: none (error is fed back via global variable num_errs)
*
* Programmer: Albert Cheng
* September 25, 2001
*
* Modifications:
* Albert Cheng, 2004/10/14
* Verified both signed and unsigned int types.
*
*-------------------------------------------------------------------------
*/
void
test_config_ctypes(void)
{
/* standard C89 basic types */
/* char, signed char, unsigned char are three distinct types. */
vrfy_ctype(char, H5_SIZEOF_CHAR);
vrfy_cint_type(signed char, unsigned char, H5_SIZEOF_CHAR);
vrfy_cint_type(int, unsigned int, H5_SIZEOF_INT);
vrfy_cint_type(short, unsigned short, H5_SIZEOF_SHORT);
vrfy_cint_type(long, unsigned long, H5_SIZEOF_LONG);
vrfy_ctype(float, H5_SIZEOF_FLOAT);
vrfy_ctype(double, H5_SIZEOF_DOUBLE);
#if H5_SIZEOF_LONG_DOUBLE >0
vrfy_ctype(long double, H5_SIZEOF_LONG_DOUBLE);
#endif
/* standard C99 basic types */
#if H5_SIZEOF_LONG_LONG > 0
vrfy_cint_type(long long, unsigned long long, H5_SIZEOF_LONG_LONG);
#endif
#if H5_SIZEOF_INT8_T > 0
vrfy_cint_type(int8_t, uint8_t, H5_SIZEOF_INT8_T);
#endif
#if H5_SIZEOF_INT16_T > 0
vrfy_cint_type(int16_t, uint16_t, H5_SIZEOF_INT16_T);
#endif
#if H5_SIZEOF_INT32_T > 0
vrfy_cint_type(int32_t, uint32_t, H5_SIZEOF_INT32_T);
#endif
#if H5_SIZEOF_INT64_T > 0
vrfy_cint_type(int64_t, uint64_t, H5_SIZEOF_INT64_T);
#endif
/* Some vendors have different sizes for the signed and unsigned */
/* fast8_t. Need to check them individually. */
#if H5_SIZEOF_INT_FAST8_T > 0
vrfy_ctype(int_fast8_t, H5_SIZEOF_INT_FAST8_T);
#endif
#if H5_SIZEOF_UINT_FAST8_T > 0
vrfy_ctype(uint_fast8_t, H5_SIZEOF_UINT_FAST8_T);
#endif
#if H5_SIZEOF_INT_FAST16_T > 0
vrfy_cint_type(int_fast16_t, uint_fast16_t, H5_SIZEOF_INT_FAST16_T);
#endif
#if H5_SIZEOF_INT_FAST32_T > 0
vrfy_cint_type(int_fast32_t, uint_fast32_t, H5_SIZEOF_INT_FAST32_T);
#endif
#if H5_SIZEOF_INT_FAST64_T > 0
vrfy_cint_type(int_fast64_t, uint_fast64_t, H5_SIZEOF_INT_FAST64_T);
#endif
#if H5_SIZEOF_INT_LEAST8_T > 0
vrfy_cint_type(int_least8_t, uint_least8_t, H5_SIZEOF_INT_LEAST8_T);
#endif
#if H5_SIZEOF_INT_LEAST16_T > 0
vrfy_cint_type(int_least16_t, uint_least16_t, H5_SIZEOF_INT_LEAST16_T);
#endif
#if H5_SIZEOF_INT_LEAST32_T > 0
vrfy_cint_type(int_least32_t, uint_least32_t, H5_SIZEOF_INT_LEAST32_T);
#endif
#if H5_SIZEOF_INT_LEAST64_T > 0
vrfy_cint_type(int_least64_t, uint_least64_t, H5_SIZEOF_INT_LEAST64_T);
#endif
/* pseudo standard basic types */
#if H5_SIZEOF___INT64 > 0
vrfy_cint_type(__int64, unsigned __int64, H5_SIZEOF___INT64);
#endif
#if H5_SIZEOF_OFF_T > 0
vrfy_ctype(off_t, H5_SIZEOF_OFF_T);
#endif
#if H5_SIZEOF_SIZE_T > 0
vrfy_ctype(size_t, H5_SIZEOF_SIZE_T);
#endif
#if H5_SIZEOF_SSIZE_T > 0
vrfy_ctype(ssize_t, H5_SIZEOF_SSIZE_T);
#endif
}
/*-------------------------------------------------------------------------
* Function: test_exit_definitions
*
* Purpose: test the exit macros values
*
* Return: none (error is fed back via global variable num_errs)
*
* Programmer: Albert Cheng
* October 12, 2009
*
* Modifications:
*
*-------------------------------------------------------------------------
*/
void
test_exit_definitions(void)
{
/* Verify the EXIT_SUCCESS and EXIT_FAILURE are 0 and 1 respectively. */
/* This should be true for POSIX compliant systems. */
if (EXIT_SUCCESS != 0) \
TestErrPrintf("Error: EXIT_SUCCESS is %d, should be %d\n", \
EXIT_SUCCESS, 0);
if (EXIT_FAILURE != 1) \
TestErrPrintf("Error: EXIT_FAILURE is %d, should be %d\n", \
EXIT_FAILURE, 1);
}
|
bc1ff7f5fe7710694b602f7c2fe60fa626670bb8
|
7744859512f027ef0da8b1bde0f8518e631b98eb
|
/soh/assets/textures/message_texture_static/message_texture_static.h
|
43f2a54b5643aad619b5016550a090079a35fed7
|
[] |
no_license
|
HarbourMasters/Shipwright
|
7f70b9470e4f9a117f3fe2d6e4deb776b8742182
|
0e7c6585239c0d7ea2c039b8b8cb7eaedf8928a9
|
refs/heads/develop
| 2023-08-31T20:50:56.253521
| 2023-08-30T17:34:06
| 2023-08-30T17:34:06
| 472,575,717
| 2,104
| 459
| null | 2023-09-14T20:29:01
| 2022-03-22T01:42:52
|
C
|
UTF-8
|
C
| false
| false
| 388
|
h
|
message_texture_static.h
|
#pragma once
#include "align_asset_macro.h"
#define dgRedMessageXLeftTex "__OTR__textures/message_texture_static/gRedMessageXLeftTex"
static const ALIGN_ASSET(2) char gRedMessageXLeftTex[] = dgRedMessageXLeftTex;
#define dgRedMessageXRightTex "__OTR__textures/message_texture_static/gRedMessageXRightTex"
static const ALIGN_ASSET(2) char gRedMessageXRightTex[] = dgRedMessageXRightTex;
|
ddaec611f5cb251d889fb525e365792d164947ee
|
d10090b0c23c789baaac67f40cccb61f39554e07
|
/Chapter_13/Src/pwmImplementation.c
|
5cac48e395cf341821abfa25bef0c41f7746e7be
|
[
"MIT"
] |
permissive
|
PacktPublishing/Hands-On-RTOS-with-Microcontrollers
|
b6b78ebf4a462a10c115338f85edb2769ac6cd58
|
9cb30e4846482cd2cf19aa631757bfe916cc245f
|
refs/heads/master
| 2023-08-08T16:48:34.456178
| 2023-01-30T10:00:49
| 2023-01-30T10:00:49
| 206,287,816
| 128
| 84
|
MIT
| 2023-07-22T15:18:15
| 2019-09-04T09:55:46
|
C
|
UTF-8
|
C
| false
| false
| 3,544
|
c
|
pwmImplementation.c
|
#include <pwmImplementation.h>
#include <main.h>
#include <stm32f7xx_hal.h>
/**
* PWM implementation supplies implementations of iPWM for the red, green, and blue
* LED's on the Nucleo board
*/
/**
* Initialize pins for PWM output to the 3 LED's
* Configures each timer to provide 16 bits of PWM resolution
* per channel : 0 - 65535 (0-100%)
*
* Color Pin Timer Alt Func main.h
* Red PB14 TIM12CH1 AF9 LD3_Pin
* Green PB0 TIM3CH3 AF2 LD1_Pin
* Blue PB7 TIM4CH2 AF2 LD2_Pin
*/
void PWMInit( void )
{
GPIO_InitTypeDef GPIO_InitStruct;
//take care of timer initialization
TIM_HandleTypeDef TimHandle;
TIM_OC_InitTypeDef sConfig;
//first, initialize all of the relevant timer clocks
__HAL_RCC_TIM12_CLK_ENABLE();
__HAL_RCC_TIM3_CLK_ENABLE();
__HAL_RCC_TIM4_CLK_ENABLE();
//init prescalar value for the counter to run at 216 Mhz
uint32_t uhPrescalerValue = (uint32_t)((SystemCoreClock/2) / 21600000) - 1;
TimHandle.Init.Prescaler = uhPrescalerValue;
TimHandle.Init.Period = 65535;
TimHandle.Init.ClockDivision = 0;
TimHandle.Init.CounterMode = TIM_COUNTERMODE_UP;
TimHandle.Init.RepetitionCounter = 0;
TimHandle.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE;
sConfig.OCMode = TIM_OCMODE_PWM1;
sConfig.OCPolarity = TIM_OCPOLARITY_HIGH;
sConfig.OCFastMode = TIM_OCFAST_DISABLE;
sConfig.OCNPolarity = TIM_OCNPOLARITY_HIGH;
sConfig.OCNIdleState = TIM_OCNIDLESTATE_RESET;
sConfig.OCIdleState = TIM_OCIDLESTATE_RESET;
//green LED timer configuration
TimHandle.Instance = TIM3;
assert_param(HAL_TIM_PWM_Init(&TimHandle) == HAL_OK);
assert_param(HAL_TIM_PWM_ConfigChannel(&TimHandle, &sConfig, TIM_CHANNEL_3) == HAL_OK);
assert_param(HAL_TIM_PWM_Start(&TimHandle, TIM_CHANNEL_3) == HAL_OK);
//blue LED timer configuration
TimHandle.Instance = TIM4;
assert_param(HAL_TIM_PWM_Init(&TimHandle) == HAL_OK);
assert_param(HAL_TIM_PWM_ConfigChannel(&TimHandle, &sConfig, TIM_CHANNEL_2) == HAL_OK);
assert_param(HAL_TIM_PWM_Start(&TimHandle, TIM_CHANNEL_2) == HAL_OK);
//red LED timer configuration
TimHandle.Instance = TIM12;
assert_param(HAL_TIM_PWM_Init(&TimHandle) == HAL_OK);
assert_param(HAL_TIM_PWM_ConfigChannel(&TimHandle, &sConfig, TIM_CHANNEL_1) == HAL_OK);
assert_param(HAL_TIM_PWM_Start(&TimHandle, TIM_CHANNEL_1) == HAL_OK);
// initialize all GPIO lines and map alternate functions
// so the timer channels are output to the GPIO pins
__HAL_RCC_GPIOB_CLK_ENABLE();
// common GPIO settings PB14, PB0, PB7
GPIO_InitStruct.Mode = GPIO_MODE_AF_PP;
GPIO_InitStruct.Pull = GPIO_NOPULL;
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
//assign AF2_TIM3 LD1_Pin
//Green LED is TIM3CH3
GPIO_InitStruct.Pin = LD1_Pin;
GPIO_InitStruct.Alternate = GPIO_AF2_TIM3;
HAL_GPIO_Init(GPIOB, &GPIO_InitStruct);
//assign AF2_TIM4 LD2_Pin
//Blue LED is TIM3CH3
GPIO_InitStruct.Pin = LD2_Pin;
GPIO_InitStruct.Alternate = GPIO_AF2_TIM4;
HAL_GPIO_Init(GPIOB, &GPIO_InitStruct);
//assign AF9_TIM12 LD3_Pin
//Red LED is TIM12CH1
GPIO_InitStruct.Pin = LD3_Pin;
GPIO_InitStruct.Alternate = GPIO_AF9_TIM12;
HAL_GPIO_Init(GPIOB, &GPIO_InitStruct);
}
void SetBlueDuty( float DutyCycle )
{
TIM4->CCR2 = DutyCycle/100.0 * 65535;
}
iPWM BluePWM = {.SetDutyCycle = SetBlueDuty};
void SetGreenDuty( float DutyCycle )
{
TIM3->CCR3 = DutyCycle/100.0 * 65535;
}
iPWM GreenPWM = {.SetDutyCycle = SetGreenDuty};
void SetRedDuty( float DutyCycle )
{
TIM12->CCR1 = DutyCycle/100.0 * 65535;
}
iPWM RedPWM = {.SetDutyCycle = SetRedDuty};
|
7d583873ff649ec317e3b6b75c3867fc3a9859b3
|
a949ca9f1f0994d4429267f91b186323a17863ad
|
/src/versioned_stream.h
|
4fe91d51301841a2fc2ff21913d49e0a1be55fdb
|
[
"MIT"
] |
permissive
|
willbryant/kitchen_sync
|
2fff9a7936064ef284bc7b874635f54eea7dc565
|
c2d7aa3dc66b15da4476b2f53519d83c11a62e49
|
refs/heads/main
| 2023-05-05T14:54:11.160113
| 2023-04-23T21:47:39
| 2023-04-23T21:47:39
| 9,129,496
| 279
| 43
|
MIT
| 2023-04-18T10:06:24
| 2013-03-31T11:45:45
|
C++
|
UTF-8
|
C
| false
| false
| 379
|
h
|
versioned_stream.h
|
#ifndef VERSIONED_STREAM_H
#define VERSIONED_STREAM_H
#include "fdstream.h"
struct VersionedFDWriteStream: FDWriteStream {
VersionedFDWriteStream(int fd): FDWriteStream(fd), protocol_version(0) {}
int protocol_version;
};
struct VersionedFDReadStream: FDReadStream {
VersionedFDReadStream(int fd): FDReadStream(fd), protocol_version(0) {}
int protocol_version;
};
#endif
|
f11e92422f67a9ffadad66545b8a102acbe3d1e0
|
88ae8695987ada722184307301e221e1ba3cc2fa
|
/third_party/ffmpeg/libavcodec/wmavoice.c
|
bb98f841a50038568e664149e24d0d6b3e7c0948
|
[
"Apache-2.0",
"LGPL-2.0-or-later",
"MIT",
"GPL-1.0-or-later",
"BSD-3-Clause",
"LGPL-2.1-only",
"LGPL-3.0-only",
"GPL-2.0-only",
"LGPL-2.1-or-later",
"GPL-3.0-or-later",
"LGPL-3.0-or-later",
"IJG",
"LicenseRef-scancode-other-permissive",
"GPL-2.0-or-later",
"GPL-3.0-only"
] |
permissive
|
iridium-browser/iridium-browser
|
71d9c5ff76e014e6900b825f67389ab0ccd01329
|
5ee297f53dc7f8e70183031cff62f37b0f19d25f
|
refs/heads/master
| 2023-08-03T16:44:16.844552
| 2023-07-20T15:17:00
| 2023-07-23T16:09:30
| 220,016,632
| 341
| 40
|
BSD-3-Clause
| 2021-08-13T13:54:45
| 2019-11-06T14:32:31
| null |
UTF-8
|
C
| false
| false
| 80,573
|
c
|
wmavoice.c
|
/*
* Windows Media Audio Voice decoder.
* Copyright (c) 2009 Ronald S. Bultje
*
* This file is part of FFmpeg.
*
* FFmpeg is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* FFmpeg 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with FFmpeg; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
/**
* @file
* @brief Windows Media Audio Voice compatible decoder
* @author Ronald S. Bultje <rsbultje@gmail.com>
*/
#include <math.h>
#include "libavutil/channel_layout.h"
#include "libavutil/float_dsp.h"
#include "libavutil/mem_internal.h"
#include "libavutil/thread.h"
#include "avcodec.h"
#include "codec_internal.h"
#include "decode.h"
#include "get_bits.h"
#include "put_bits.h"
#include "wmavoice_data.h"
#include "celp_filters.h"
#include "acelp_vectors.h"
#include "acelp_filters.h"
#include "lsp.h"
#include "dct.h"
#include "rdft.h"
#include "sinewin.h"
#define MAX_BLOCKS 8 ///< maximum number of blocks per frame
#define MAX_LSPS 16 ///< maximum filter order
#define MAX_LSPS_ALIGN16 16 ///< same as #MAX_LSPS; needs to be multiple
///< of 16 for ASM input buffer alignment
#define MAX_FRAMES 3 ///< maximum number of frames per superframe
#define MAX_FRAMESIZE 160 ///< maximum number of samples per frame
#define MAX_SIGNAL_HISTORY 416 ///< maximum excitation signal history
#define MAX_SFRAMESIZE (MAX_FRAMESIZE * MAX_FRAMES)
///< maximum number of samples per superframe
#define SFRAME_CACHE_MAXSIZE 256 ///< maximum cache size for frame data that
///< was split over two packets
#define VLC_NBITS 6 ///< number of bits to read per VLC iteration
/**
* Frame type VLC coding.
*/
static VLC frame_type_vlc;
/**
* Adaptive codebook types.
*/
enum {
ACB_TYPE_NONE = 0, ///< no adaptive codebook (only hardcoded fixed)
ACB_TYPE_ASYMMETRIC = 1, ///< adaptive codebook with per-frame pitch, which
///< we interpolate to get a per-sample pitch.
///< Signal is generated using an asymmetric sinc
///< window function
///< @note see #wmavoice_ipol1_coeffs
ACB_TYPE_HAMMING = 2 ///< Per-block pitch with signal generation using
///< a Hamming sinc window function
///< @note see #wmavoice_ipol2_coeffs
};
/**
* Fixed codebook types.
*/
enum {
FCB_TYPE_SILENCE = 0, ///< comfort noise during silence
///< generated from a hardcoded (fixed) codebook
///< with per-frame (low) gain values
FCB_TYPE_HARDCODED = 1, ///< hardcoded (fixed) codebook with per-block
///< gain values
FCB_TYPE_AW_PULSES = 2, ///< Pitch-adaptive window (AW) pulse signals,
///< used in particular for low-bitrate streams
FCB_TYPE_EXC_PULSES = 3, ///< Innovation (fixed) codebook pulse sets in
///< combinations of either single pulses or
///< pulse pairs
};
/**
* Description of frame types.
*/
static const struct frame_type_desc {
uint8_t n_blocks; ///< amount of blocks per frame (each block
///< (contains 160/#n_blocks samples)
uint8_t log_n_blocks; ///< log2(#n_blocks)
uint8_t acb_type; ///< Adaptive codebook type (ACB_TYPE_*)
uint8_t fcb_type; ///< Fixed codebook type (FCB_TYPE_*)
uint8_t dbl_pulses; ///< how many pulse vectors have pulse pairs
///< (rather than just one single pulse)
///< only if #fcb_type == #FCB_TYPE_EXC_PULSES
} frame_descs[17] = {
{ 1, 0, ACB_TYPE_NONE, FCB_TYPE_SILENCE, 0 },
{ 2, 1, ACB_TYPE_NONE, FCB_TYPE_HARDCODED, 0 },
{ 2, 1, ACB_TYPE_ASYMMETRIC, FCB_TYPE_AW_PULSES, 0 },
{ 2, 1, ACB_TYPE_ASYMMETRIC, FCB_TYPE_EXC_PULSES, 2 },
{ 2, 1, ACB_TYPE_ASYMMETRIC, FCB_TYPE_EXC_PULSES, 5 },
{ 4, 2, ACB_TYPE_ASYMMETRIC, FCB_TYPE_EXC_PULSES, 0 },
{ 4, 2, ACB_TYPE_ASYMMETRIC, FCB_TYPE_EXC_PULSES, 2 },
{ 4, 2, ACB_TYPE_ASYMMETRIC, FCB_TYPE_EXC_PULSES, 5 },
{ 2, 1, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 0 },
{ 2, 1, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 2 },
{ 2, 1, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 5 },
{ 4, 2, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 0 },
{ 4, 2, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 2 },
{ 4, 2, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 5 },
{ 8, 3, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 0 },
{ 8, 3, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 2 },
{ 8, 3, ACB_TYPE_HAMMING, FCB_TYPE_EXC_PULSES, 5 }
};
/**
* WMA Voice decoding context.
*/
typedef struct WMAVoiceContext {
/**
* @name Global values specified in the stream header / extradata or used all over.
* @{
*/
GetBitContext gb; ///< packet bitreader. During decoder init,
///< it contains the extradata from the
///< demuxer. During decoding, it contains
///< packet data.
int8_t vbm_tree[25]; ///< converts VLC codes to frame type
int spillover_bitsize; ///< number of bits used to specify
///< #spillover_nbits in the packet header
///< = ceil(log2(ctx->block_align << 3))
int history_nsamples; ///< number of samples in history for signal
///< prediction (through ACB)
/* postfilter specific values */
int do_apf; ///< whether to apply the averaged
///< projection filter (APF)
int denoise_strength; ///< strength of denoising in Wiener filter
///< [0-11]
int denoise_tilt_corr; ///< Whether to apply tilt correction to the
///< Wiener filter coefficients (postfilter)
int dc_level; ///< Predicted amount of DC noise, based
///< on which a DC removal filter is used
int lsps; ///< number of LSPs per frame [10 or 16]
int lsp_q_mode; ///< defines quantizer defaults [0, 1]
int lsp_def_mode; ///< defines different sets of LSP defaults
///< [0, 1]
int min_pitch_val; ///< base value for pitch parsing code
int max_pitch_val; ///< max value + 1 for pitch parsing
int pitch_nbits; ///< number of bits used to specify the
///< pitch value in the frame header
int block_pitch_nbits; ///< number of bits used to specify the
///< first block's pitch value
int block_pitch_range; ///< range of the block pitch
int block_delta_pitch_nbits; ///< number of bits used to specify the
///< delta pitch between this and the last
///< block's pitch value, used in all but
///< first block
int block_delta_pitch_hrange; ///< 1/2 range of the delta (full range is
///< from -this to +this-1)
uint16_t block_conv_table[4]; ///< boundaries for block pitch unit/scale
///< conversion
/**
* @}
*
* @name Packet values specified in the packet header or related to a packet.
*
* A packet is considered to be a single unit of data provided to this
* decoder by the demuxer.
* @{
*/
int spillover_nbits; ///< number of bits of the previous packet's
///< last superframe preceding this
///< packet's first full superframe (useful
///< for re-synchronization also)
int has_residual_lsps; ///< if set, superframes contain one set of
///< LSPs that cover all frames, encoded as
///< independent and residual LSPs; if not
///< set, each frame contains its own, fully
///< independent, LSPs
int skip_bits_next; ///< number of bits to skip at the next call
///< to #wmavoice_decode_packet() (since
///< they're part of the previous superframe)
uint8_t sframe_cache[SFRAME_CACHE_MAXSIZE + AV_INPUT_BUFFER_PADDING_SIZE];
///< cache for superframe data split over
///< multiple packets
int sframe_cache_size; ///< set to >0 if we have data from an
///< (incomplete) superframe from a previous
///< packet that spilled over in the current
///< packet; specifies the amount of bits in
///< #sframe_cache
PutBitContext pb; ///< bitstream writer for #sframe_cache
/**
* @}
*
* @name Frame and superframe values
* Superframe and frame data - these can change from frame to frame,
* although some of them do in that case serve as a cache / history for
* the next frame or superframe.
* @{
*/
double prev_lsps[MAX_LSPS]; ///< LSPs of the last frame of the previous
///< superframe
int last_pitch_val; ///< pitch value of the previous frame
int last_acb_type; ///< frame type [0-2] of the previous frame
int pitch_diff_sh16; ///< ((cur_pitch_val - #last_pitch_val)
///< << 16) / #MAX_FRAMESIZE
float silence_gain; ///< set for use in blocks if #ACB_TYPE_NONE
int aw_idx_is_ext; ///< whether the AW index was encoded in
///< 8 bits (instead of 6)
int aw_pulse_range; ///< the range over which #aw_pulse_set1()
///< can apply the pulse, relative to the
///< value in aw_first_pulse_off. The exact
///< position of the first AW-pulse is within
///< [pulse_off, pulse_off + this], and
///< depends on bitstream values; [16 or 24]
int aw_n_pulses[2]; ///< number of AW-pulses in each block; note
///< that this number can be negative (in
///< which case it basically means "zero")
int aw_first_pulse_off[2]; ///< index of first sample to which to
///< apply AW-pulses, or -0xff if unset
int aw_next_pulse_off_cache; ///< the position (relative to start of the
///< second block) at which pulses should
///< start to be positioned, serves as a
///< cache for pitch-adaptive window pulses
///< between blocks
int frame_cntr; ///< current frame index [0 - 0xFFFE]; is
///< only used for comfort noise in #pRNG()
int nb_superframes; ///< number of superframes in current packet
float gain_pred_err[6]; ///< cache for gain prediction
float excitation_history[MAX_SIGNAL_HISTORY];
///< cache of the signal of previous
///< superframes, used as a history for
///< signal generation
float synth_history[MAX_LSPS]; ///< see #excitation_history
/**
* @}
*
* @name Postfilter values
*
* Variables used for postfilter implementation, mostly history for
* smoothing and so on, and context variables for FFT/iFFT.
* @{
*/
RDFTContext rdft, irdft; ///< contexts for FFT-calculation in the
///< postfilter (for denoise filter)
DCTContext dct, dst; ///< contexts for phase shift (in Hilbert
///< transform, part of postfilter)
float sin[511], cos[511]; ///< 8-bit cosine/sine windows over [-pi,pi]
///< range
float postfilter_agc; ///< gain control memory, used in
///< #adaptive_gain_control()
float dcf_mem[2]; ///< DC filter history
float zero_exc_pf[MAX_SIGNAL_HISTORY + MAX_SFRAMESIZE];
///< zero filter output (i.e. excitation)
///< by postfilter
float denoise_filter_cache[MAX_FRAMESIZE];
int denoise_filter_cache_size; ///< samples in #denoise_filter_cache
DECLARE_ALIGNED(32, float, tilted_lpcs_pf)[0x80];
///< aligned buffer for LPC tilting
DECLARE_ALIGNED(32, float, denoise_coeffs_pf)[0x80];
///< aligned buffer for denoise coefficients
DECLARE_ALIGNED(32, float, synth_filter_out_buf)[0x80 + MAX_LSPS_ALIGN16];
///< aligned buffer for postfilter speech
///< synthesis
/**
* @}
*/
} WMAVoiceContext;
/**
* Set up the variable bit mode (VBM) tree from container extradata.
* @param gb bit I/O context.
* The bit context (s->gb) should be loaded with byte 23-46 of the
* container extradata (i.e. the ones containing the VBM tree).
* @param vbm_tree pointer to array to which the decoded VBM tree will be
* written.
* @return 0 on success, <0 on error.
*/
static av_cold int decode_vbmtree(GetBitContext *gb, int8_t vbm_tree[25])
{
int cntr[8] = { 0 }, n, res;
memset(vbm_tree, 0xff, sizeof(vbm_tree[0]) * 25);
for (n = 0; n < 17; n++) {
res = get_bits(gb, 3);
if (cntr[res] > 3) // should be >= 3 + (res == 7))
return -1;
vbm_tree[res * 3 + cntr[res]++] = n;
}
return 0;
}
static av_cold void wmavoice_init_static_data(void)
{
static const uint8_t bits[] = {
2, 2, 2, 4, 4, 4,
6, 6, 6, 8, 8, 8,
10, 10, 10, 12, 12, 12,
14, 14, 14, 14
};
INIT_VLC_STATIC_FROM_LENGTHS(&frame_type_vlc, VLC_NBITS,
FF_ARRAY_ELEMS(bits), bits,
1, NULL, 0, 0, 0, 0, 132);
}
static av_cold void wmavoice_flush(AVCodecContext *ctx)
{
WMAVoiceContext *s = ctx->priv_data;
int n;
s->postfilter_agc = 0;
s->sframe_cache_size = 0;
s->skip_bits_next = 0;
for (n = 0; n < s->lsps; n++)
s->prev_lsps[n] = M_PI * (n + 1.0) / (s->lsps + 1.0);
memset(s->excitation_history, 0,
sizeof(*s->excitation_history) * MAX_SIGNAL_HISTORY);
memset(s->synth_history, 0,
sizeof(*s->synth_history) * MAX_LSPS);
memset(s->gain_pred_err, 0,
sizeof(s->gain_pred_err));
if (s->do_apf) {
memset(&s->synth_filter_out_buf[MAX_LSPS_ALIGN16 - s->lsps], 0,
sizeof(*s->synth_filter_out_buf) * s->lsps);
memset(s->dcf_mem, 0,
sizeof(*s->dcf_mem) * 2);
memset(s->zero_exc_pf, 0,
sizeof(*s->zero_exc_pf) * s->history_nsamples);
memset(s->denoise_filter_cache, 0, sizeof(s->denoise_filter_cache));
}
}
/**
* Set up decoder with parameters from demuxer (extradata etc.).
*/
static av_cold int wmavoice_decode_init(AVCodecContext *ctx)
{
static AVOnce init_static_once = AV_ONCE_INIT;
int n, flags, pitch_range, lsp16_flag, ret;
WMAVoiceContext *s = ctx->priv_data;
ff_thread_once(&init_static_once, wmavoice_init_static_data);
/**
* Extradata layout:
* - byte 0-18: WMAPro-in-WMAVoice extradata (see wmaprodec.c),
* - byte 19-22: flags field (annoyingly in LE; see below for known
* values),
* - byte 23-46: variable bitmode tree (really just 17 * 3 bits,
* rest is 0).
*/
if (ctx->extradata_size != 46) {
av_log(ctx, AV_LOG_ERROR,
"Invalid extradata size %d (should be 46)\n",
ctx->extradata_size);
return AVERROR_INVALIDDATA;
}
if (ctx->block_align <= 0 || ctx->block_align > (1<<22)) {
av_log(ctx, AV_LOG_ERROR, "Invalid block alignment %d.\n", ctx->block_align);
return AVERROR_INVALIDDATA;
}
flags = AV_RL32(ctx->extradata + 18);
s->spillover_bitsize = 3 + av_ceil_log2(ctx->block_align);
s->do_apf = flags & 0x1;
if (s->do_apf) {
if ((ret = ff_rdft_init(&s->rdft, 7, DFT_R2C)) < 0 ||
(ret = ff_rdft_init(&s->irdft, 7, IDFT_C2R)) < 0 ||
(ret = ff_dct_init (&s->dct, 6, DCT_I)) < 0 ||
(ret = ff_dct_init (&s->dst, 6, DST_I)) < 0)
return ret;
ff_sine_window_init(s->cos, 256);
memcpy(&s->sin[255], s->cos, 256 * sizeof(s->cos[0]));
for (n = 0; n < 255; n++) {
s->sin[n] = -s->sin[510 - n];
s->cos[510 - n] = s->cos[n];
}
}
s->denoise_strength = (flags >> 2) & 0xF;
if (s->denoise_strength >= 12) {
av_log(ctx, AV_LOG_ERROR,
"Invalid denoise filter strength %d (max=11)\n",
s->denoise_strength);
return AVERROR_INVALIDDATA;
}
s->denoise_tilt_corr = !!(flags & 0x40);
s->dc_level = (flags >> 7) & 0xF;
s->lsp_q_mode = !!(flags & 0x2000);
s->lsp_def_mode = !!(flags & 0x4000);
lsp16_flag = flags & 0x1000;
if (lsp16_flag) {
s->lsps = 16;
} else {
s->lsps = 10;
}
for (n = 0; n < s->lsps; n++)
s->prev_lsps[n] = M_PI * (n + 1.0) / (s->lsps + 1.0);
init_get_bits(&s->gb, ctx->extradata + 22, (ctx->extradata_size - 22) << 3);
if (decode_vbmtree(&s->gb, s->vbm_tree) < 0) {
av_log(ctx, AV_LOG_ERROR, "Invalid VBM tree; broken extradata?\n");
return AVERROR_INVALIDDATA;
}
if (ctx->sample_rate >= INT_MAX / (256 * 37))
return AVERROR_INVALIDDATA;
s->min_pitch_val = ((ctx->sample_rate << 8) / 400 + 50) >> 8;
s->max_pitch_val = ((ctx->sample_rate << 8) * 37 / 2000 + 50) >> 8;
pitch_range = s->max_pitch_val - s->min_pitch_val;
if (pitch_range <= 0) {
av_log(ctx, AV_LOG_ERROR, "Invalid pitch range; broken extradata?\n");
return AVERROR_INVALIDDATA;
}
s->pitch_nbits = av_ceil_log2(pitch_range);
s->last_pitch_val = 40;
s->last_acb_type = ACB_TYPE_NONE;
s->history_nsamples = s->max_pitch_val + 8;
if (s->min_pitch_val < 1 || s->history_nsamples > MAX_SIGNAL_HISTORY) {
int min_sr = ((((1 << 8) - 50) * 400) + 0xFF) >> 8,
max_sr = ((((MAX_SIGNAL_HISTORY - 8) << 8) + 205) * 2000 / 37) >> 8;
av_log(ctx, AV_LOG_ERROR,
"Unsupported samplerate %d (min=%d, max=%d)\n",
ctx->sample_rate, min_sr, max_sr); // 322-22097 Hz
return AVERROR(ENOSYS);
}
s->block_conv_table[0] = s->min_pitch_val;
s->block_conv_table[1] = (pitch_range * 25) >> 6;
s->block_conv_table[2] = (pitch_range * 44) >> 6;
s->block_conv_table[3] = s->max_pitch_val - 1;
s->block_delta_pitch_hrange = (pitch_range >> 3) & ~0xF;
if (s->block_delta_pitch_hrange <= 0) {
av_log(ctx, AV_LOG_ERROR, "Invalid delta pitch hrange; broken extradata?\n");
return AVERROR_INVALIDDATA;
}
s->block_delta_pitch_nbits = 1 + av_ceil_log2(s->block_delta_pitch_hrange);
s->block_pitch_range = s->block_conv_table[2] +
s->block_conv_table[3] + 1 +
2 * (s->block_conv_table[1] - 2 * s->min_pitch_val);
s->block_pitch_nbits = av_ceil_log2(s->block_pitch_range);
av_channel_layout_uninit(&ctx->ch_layout);
ctx->ch_layout = (AVChannelLayout)AV_CHANNEL_LAYOUT_MONO;
ctx->sample_fmt = AV_SAMPLE_FMT_FLT;
return 0;
}
/**
* @name Postfilter functions
* Postfilter functions (gain control, wiener denoise filter, DC filter,
* kalman smoothening, plus surrounding code to wrap it)
* @{
*/
/**
* Adaptive gain control (as used in postfilter).
*
* Identical to #ff_adaptive_gain_control() in acelp_vectors.c, except
* that the energy here is calculated using sum(abs(...)), whereas the
* other codecs (e.g. AMR-NB, SIPRO) use sqrt(dotproduct(...)).
*
* @param out output buffer for filtered samples
* @param in input buffer containing the samples as they are after the
* postfilter steps so far
* @param speech_synth input buffer containing speech synth before postfilter
* @param size input buffer size
* @param alpha exponential filter factor
* @param gain_mem pointer to filter memory (single float)
*/
static void adaptive_gain_control(float *out, const float *in,
const float *speech_synth,
int size, float alpha, float *gain_mem)
{
int i;
float speech_energy = 0.0, postfilter_energy = 0.0, gain_scale_factor;
float mem = *gain_mem;
for (i = 0; i < size; i++) {
speech_energy += fabsf(speech_synth[i]);
postfilter_energy += fabsf(in[i]);
}
gain_scale_factor = postfilter_energy == 0.0 ? 0.0 :
(1.0 - alpha) * speech_energy / postfilter_energy;
for (i = 0; i < size; i++) {
mem = alpha * mem + gain_scale_factor;
out[i] = in[i] * mem;
}
*gain_mem = mem;
}
/**
* Kalman smoothing function.
*
* This function looks back pitch +/- 3 samples back into history to find
* the best fitting curve (that one giving the optimal gain of the two
* signals, i.e. the highest dot product between the two), and then
* uses that signal history to smoothen the output of the speech synthesis
* filter.
*
* @param s WMA Voice decoding context
* @param pitch pitch of the speech signal
* @param in input speech signal
* @param out output pointer for smoothened signal
* @param size input/output buffer size
*
* @returns -1 if no smoothening took place, e.g. because no optimal
* fit could be found, or 0 on success.
*/
static int kalman_smoothen(WMAVoiceContext *s, int pitch,
const float *in, float *out, int size)
{
int n;
float optimal_gain = 0, dot;
const float *ptr = &in[-FFMAX(s->min_pitch_val, pitch - 3)],
*end = &in[-FFMIN(s->max_pitch_val, pitch + 3)],
*best_hist_ptr = NULL;
/* find best fitting point in history */
do {
dot = avpriv_scalarproduct_float_c(in, ptr, size);
if (dot > optimal_gain) {
optimal_gain = dot;
best_hist_ptr = ptr;
}
} while (--ptr >= end);
if (optimal_gain <= 0)
return -1;
dot = avpriv_scalarproduct_float_c(best_hist_ptr, best_hist_ptr, size);
if (dot <= 0) // would be 1.0
return -1;
if (optimal_gain <= dot) {
dot = dot / (dot + 0.6 * optimal_gain); // 0.625-1.000
} else
dot = 0.625;
/* actual smoothing */
for (n = 0; n < size; n++)
out[n] = best_hist_ptr[n] + dot * (in[n] - best_hist_ptr[n]);
return 0;
}
/**
* Get the tilt factor of a formant filter from its transfer function
* @see #tilt_factor() in amrnbdec.c, which does essentially the same,
* but somehow (??) it does a speech synthesis filter in the
* middle, which is missing here
*
* @param lpcs LPC coefficients
* @param n_lpcs Size of LPC buffer
* @returns the tilt factor
*/
static float tilt_factor(const float *lpcs, int n_lpcs)
{
float rh0, rh1;
rh0 = 1.0 + avpriv_scalarproduct_float_c(lpcs, lpcs, n_lpcs);
rh1 = lpcs[0] + avpriv_scalarproduct_float_c(lpcs, &lpcs[1], n_lpcs - 1);
return rh1 / rh0;
}
/**
* Derive denoise filter coefficients (in real domain) from the LPCs.
*/
static void calc_input_response(WMAVoiceContext *s, float *lpcs,
int fcb_type, float *coeffs, int remainder)
{
float last_coeff, min = 15.0, max = -15.0;
float irange, angle_mul, gain_mul, range, sq;
int n, idx;
/* Create frequency power spectrum of speech input (i.e. RDFT of LPCs) */
s->rdft.rdft_calc(&s->rdft, lpcs);
#define log_range(var, assign) do { \
float tmp = log10f(assign); var = tmp; \
max = FFMAX(max, tmp); min = FFMIN(min, tmp); \
} while (0)
log_range(last_coeff, lpcs[1] * lpcs[1]);
for (n = 1; n < 64; n++)
log_range(lpcs[n], lpcs[n * 2] * lpcs[n * 2] +
lpcs[n * 2 + 1] * lpcs[n * 2 + 1]);
log_range(lpcs[0], lpcs[0] * lpcs[0]);
#undef log_range
range = max - min;
lpcs[64] = last_coeff;
/* Now, use this spectrum to pick out these frequencies with higher
* (relative) power/energy (which we then take to be "not noise"),
* and set up a table (still in lpc[]) of (relative) gains per frequency.
* These frequencies will be maintained, while others ("noise") will be
* decreased in the filter output. */
irange = 64.0 / range; // so irange*(max-value) is in the range [0, 63]
gain_mul = range * (fcb_type == FCB_TYPE_HARDCODED ? (5.0 / 13.0) :
(5.0 / 14.7));
angle_mul = gain_mul * (8.0 * M_LN10 / M_PI);
for (n = 0; n <= 64; n++) {
float pwr;
idx = lrint((max - lpcs[n]) * irange - 1);
idx = FFMAX(0, idx);
pwr = wmavoice_denoise_power_table[s->denoise_strength][idx];
lpcs[n] = angle_mul * pwr;
/* 70.57 =~ 1/log10(1.0331663) */
idx = av_clipf((pwr * gain_mul - 0.0295) * 70.570526123, 0, INT_MAX / 2);
if (idx > 127) { // fall back if index falls outside table range
coeffs[n] = wmavoice_energy_table[127] *
powf(1.0331663, idx - 127);
} else
coeffs[n] = wmavoice_energy_table[FFMAX(0, idx)];
}
/* calculate the Hilbert transform of the gains, which we do (since this
* is a sine input) by doing a phase shift (in theory, H(sin())=cos()).
* Hilbert_Transform(RDFT(x)) = Laplace_Transform(x), which calculates the
* "moment" of the LPCs in this filter. */
s->dct.dct_calc(&s->dct, lpcs);
s->dst.dct_calc(&s->dst, lpcs);
/* Split out the coefficient indexes into phase/magnitude pairs */
idx = 255 + av_clip(lpcs[64], -255, 255);
coeffs[0] = coeffs[0] * s->cos[idx];
idx = 255 + av_clip(lpcs[64] - 2 * lpcs[63], -255, 255);
last_coeff = coeffs[64] * s->cos[idx];
for (n = 63;; n--) {
idx = 255 + av_clip(-lpcs[64] - 2 * lpcs[n - 1], -255, 255);
coeffs[n * 2 + 1] = coeffs[n] * s->sin[idx];
coeffs[n * 2] = coeffs[n] * s->cos[idx];
if (!--n) break;
idx = 255 + av_clip( lpcs[64] - 2 * lpcs[n - 1], -255, 255);
coeffs[n * 2 + 1] = coeffs[n] * s->sin[idx];
coeffs[n * 2] = coeffs[n] * s->cos[idx];
}
coeffs[1] = last_coeff;
/* move into real domain */
s->irdft.rdft_calc(&s->irdft, coeffs);
/* tilt correction and normalize scale */
memset(&coeffs[remainder], 0, sizeof(coeffs[0]) * (128 - remainder));
if (s->denoise_tilt_corr) {
float tilt_mem = 0;
coeffs[remainder - 1] = 0;
ff_tilt_compensation(&tilt_mem,
-1.8 * tilt_factor(coeffs, remainder - 1),
coeffs, remainder);
}
sq = (1.0 / 64.0) * sqrtf(1 / avpriv_scalarproduct_float_c(coeffs, coeffs,
remainder));
for (n = 0; n < remainder; n++)
coeffs[n] *= sq;
}
/**
* This function applies a Wiener filter on the (noisy) speech signal as
* a means to denoise it.
*
* - take RDFT of LPCs to get the power spectrum of the noise + speech;
* - using this power spectrum, calculate (for each frequency) the Wiener
* filter gain, which depends on the frequency power and desired level
* of noise subtraction (when set too high, this leads to artifacts)
* We can do this symmetrically over the X-axis (so 0-4kHz is the inverse
* of 4-8kHz);
* - by doing a phase shift, calculate the Hilbert transform of this array
* of per-frequency filter-gains to get the filtering coefficients;
* - smoothen/normalize/de-tilt these filter coefficients as desired;
* - take RDFT of noisy sound, apply the coefficients and take its IRDFT
* to get the denoised speech signal;
* - the leftover (i.e. output of the IRDFT on denoised speech data beyond
* the frame boundary) are saved and applied to subsequent frames by an
* overlap-add method (otherwise you get clicking-artifacts).
*
* @param s WMA Voice decoding context
* @param fcb_type Frame (codebook) type
* @param synth_pf input: the noisy speech signal, output: denoised speech
* data; should be 16-byte aligned (for ASM purposes)
* @param size size of the speech data
* @param lpcs LPCs used to synthesize this frame's speech data
*/
static void wiener_denoise(WMAVoiceContext *s, int fcb_type,
float *synth_pf, int size,
const float *lpcs)
{
int remainder, lim, n;
if (fcb_type != FCB_TYPE_SILENCE) {
float *tilted_lpcs = s->tilted_lpcs_pf,
*coeffs = s->denoise_coeffs_pf, tilt_mem = 0;
tilted_lpcs[0] = 1.0;
memcpy(&tilted_lpcs[1], lpcs, sizeof(lpcs[0]) * s->lsps);
memset(&tilted_lpcs[s->lsps + 1], 0,
sizeof(tilted_lpcs[0]) * (128 - s->lsps - 1));
ff_tilt_compensation(&tilt_mem, 0.7 * tilt_factor(lpcs, s->lsps),
tilted_lpcs, s->lsps + 2);
/* The IRDFT output (127 samples for 7-bit filter) beyond the frame
* size is applied to the next frame. All input beyond this is zero,
* and thus all output beyond this will go towards zero, hence we can
* limit to min(size-1, 127-size) as a performance consideration. */
remainder = FFMIN(127 - size, size - 1);
calc_input_response(s, tilted_lpcs, fcb_type, coeffs, remainder);
/* apply coefficients (in frequency spectrum domain), i.e. complex
* number multiplication */
memset(&synth_pf[size], 0, sizeof(synth_pf[0]) * (128 - size));
s->rdft.rdft_calc(&s->rdft, synth_pf);
s->rdft.rdft_calc(&s->rdft, coeffs);
synth_pf[0] *= coeffs[0];
synth_pf[1] *= coeffs[1];
for (n = 1; n < 64; n++) {
float v1 = synth_pf[n * 2], v2 = synth_pf[n * 2 + 1];
synth_pf[n * 2] = v1 * coeffs[n * 2] - v2 * coeffs[n * 2 + 1];
synth_pf[n * 2 + 1] = v2 * coeffs[n * 2] + v1 * coeffs[n * 2 + 1];
}
s->irdft.rdft_calc(&s->irdft, synth_pf);
}
/* merge filter output with the history of previous runs */
if (s->denoise_filter_cache_size) {
lim = FFMIN(s->denoise_filter_cache_size, size);
for (n = 0; n < lim; n++)
synth_pf[n] += s->denoise_filter_cache[n];
s->denoise_filter_cache_size -= lim;
memmove(s->denoise_filter_cache, &s->denoise_filter_cache[size],
sizeof(s->denoise_filter_cache[0]) * s->denoise_filter_cache_size);
}
/* move remainder of filter output into a cache for future runs */
if (fcb_type != FCB_TYPE_SILENCE) {
lim = FFMIN(remainder, s->denoise_filter_cache_size);
for (n = 0; n < lim; n++)
s->denoise_filter_cache[n] += synth_pf[size + n];
if (lim < remainder) {
memcpy(&s->denoise_filter_cache[lim], &synth_pf[size + lim],
sizeof(s->denoise_filter_cache[0]) * (remainder - lim));
s->denoise_filter_cache_size = remainder;
}
}
}
/**
* Averaging projection filter, the postfilter used in WMAVoice.
*
* This uses the following steps:
* - A zero-synthesis filter (generate excitation from synth signal)
* - Kalman smoothing on excitation, based on pitch
* - Re-synthesized smoothened output
* - Iterative Wiener denoise filter
* - Adaptive gain filter
* - DC filter
*
* @param s WMAVoice decoding context
* @param synth Speech synthesis output (before postfilter)
* @param samples Output buffer for filtered samples
* @param size Buffer size of synth & samples
* @param lpcs Generated LPCs used for speech synthesis
* @param zero_exc_pf destination for zero synthesis filter (16-byte aligned)
* @param fcb_type Frame type (silence, hardcoded, AW-pulses or FCB-pulses)
* @param pitch Pitch of the input signal
*/
static void postfilter(WMAVoiceContext *s, const float *synth,
float *samples, int size,
const float *lpcs, float *zero_exc_pf,
int fcb_type, int pitch)
{
float synth_filter_in_buf[MAX_FRAMESIZE / 2],
*synth_pf = &s->synth_filter_out_buf[MAX_LSPS_ALIGN16],
*synth_filter_in = zero_exc_pf;
av_assert0(size <= MAX_FRAMESIZE / 2);
/* generate excitation from input signal */
ff_celp_lp_zero_synthesis_filterf(zero_exc_pf, lpcs, synth, size, s->lsps);
if (fcb_type >= FCB_TYPE_AW_PULSES &&
!kalman_smoothen(s, pitch, zero_exc_pf, synth_filter_in_buf, size))
synth_filter_in = synth_filter_in_buf;
/* re-synthesize speech after smoothening, and keep history */
ff_celp_lp_synthesis_filterf(synth_pf, lpcs,
synth_filter_in, size, s->lsps);
memcpy(&synth_pf[-s->lsps], &synth_pf[size - s->lsps],
sizeof(synth_pf[0]) * s->lsps);
wiener_denoise(s, fcb_type, synth_pf, size, lpcs);
adaptive_gain_control(samples, synth_pf, synth, size, 0.99,
&s->postfilter_agc);
if (s->dc_level > 8) {
/* remove ultra-low frequency DC noise / highpass filter;
* coefficients are identical to those used in SIPR decoding,
* and very closely resemble those used in AMR-NB decoding. */
ff_acelp_apply_order_2_transfer_function(samples, samples,
(const float[2]) { -1.99997, 1.0 },
(const float[2]) { -1.9330735188, 0.93589198496 },
0.93980580475, s->dcf_mem, size);
}
}
/**
* @}
*/
/**
* Dequantize LSPs
* @param lsps output pointer to the array that will hold the LSPs
* @param num number of LSPs to be dequantized
* @param values quantized values, contains n_stages values
* @param sizes range (i.e. max value) of each quantized value
* @param n_stages number of dequantization runs
* @param table dequantization table to be used
* @param mul_q LSF multiplier
* @param base_q base (lowest) LSF values
*/
static void dequant_lsps(double *lsps, int num,
const uint16_t *values,
const uint16_t *sizes,
int n_stages, const uint8_t *table,
const double *mul_q,
const double *base_q)
{
int n, m;
memset(lsps, 0, num * sizeof(*lsps));
for (n = 0; n < n_stages; n++) {
const uint8_t *t_off = &table[values[n] * num];
double base = base_q[n], mul = mul_q[n];
for (m = 0; m < num; m++)
lsps[m] += base + mul * t_off[m];
table += sizes[n] * num;
}
}
/**
* @name LSP dequantization routines
* LSP dequantization routines, for 10/16LSPs and independent/residual coding.
* lsp10i() consumes 24 bits; lsp10r() consumes an additional 24 bits;
* lsp16i() consumes 34 bits; lsp16r() consumes an additional 26 bits.
* @{
*/
/**
* Parse 10 independently-coded LSPs.
*/
static void dequant_lsp10i(GetBitContext *gb, double *lsps)
{
static const uint16_t vec_sizes[4] = { 256, 64, 32, 32 };
static const double mul_lsf[4] = {
5.2187144800e-3, 1.4626986422e-3,
9.6179549166e-4, 1.1325736225e-3
};
static const double base_lsf[4] = {
M_PI * -2.15522e-1, M_PI * -6.1646e-2,
M_PI * -3.3486e-2, M_PI * -5.7408e-2
};
uint16_t v[4];
v[0] = get_bits(gb, 8);
v[1] = get_bits(gb, 6);
v[2] = get_bits(gb, 5);
v[3] = get_bits(gb, 5);
dequant_lsps(lsps, 10, v, vec_sizes, 4, wmavoice_dq_lsp10i,
mul_lsf, base_lsf);
}
/**
* Parse 10 independently-coded LSPs, and then derive the tables to
* generate LSPs for the other frames from them (residual coding).
*/
static void dequant_lsp10r(GetBitContext *gb,
double *i_lsps, const double *old,
double *a1, double *a2, int q_mode)
{
static const uint16_t vec_sizes[3] = { 128, 64, 64 };
static const double mul_lsf[3] = {
2.5807601174e-3, 1.2354460219e-3, 1.1763821673e-3
};
static const double base_lsf[3] = {
M_PI * -1.07448e-1, M_PI * -5.2706e-2, M_PI * -5.1634e-2
};
const float (*ipol_tab)[2][10] = q_mode ?
wmavoice_lsp10_intercoeff_b : wmavoice_lsp10_intercoeff_a;
uint16_t interpol, v[3];
int n;
dequant_lsp10i(gb, i_lsps);
interpol = get_bits(gb, 5);
v[0] = get_bits(gb, 7);
v[1] = get_bits(gb, 6);
v[2] = get_bits(gb, 6);
for (n = 0; n < 10; n++) {
double delta = old[n] - i_lsps[n];
a1[n] = ipol_tab[interpol][0][n] * delta + i_lsps[n];
a1[10 + n] = ipol_tab[interpol][1][n] * delta + i_lsps[n];
}
dequant_lsps(a2, 20, v, vec_sizes, 3, wmavoice_dq_lsp10r,
mul_lsf, base_lsf);
}
/**
* Parse 16 independently-coded LSPs.
*/
static void dequant_lsp16i(GetBitContext *gb, double *lsps)
{
static const uint16_t vec_sizes[5] = { 256, 64, 128, 64, 128 };
static const double mul_lsf[5] = {
3.3439586280e-3, 6.9908173703e-4,
3.3216608306e-3, 1.0334960326e-3,
3.1899104283e-3
};
static const double base_lsf[5] = {
M_PI * -1.27576e-1, M_PI * -2.4292e-2,
M_PI * -1.28094e-1, M_PI * -3.2128e-2,
M_PI * -1.29816e-1
};
uint16_t v[5];
v[0] = get_bits(gb, 8);
v[1] = get_bits(gb, 6);
v[2] = get_bits(gb, 7);
v[3] = get_bits(gb, 6);
v[4] = get_bits(gb, 7);
dequant_lsps( lsps, 5, v, vec_sizes, 2,
wmavoice_dq_lsp16i1, mul_lsf, base_lsf);
dequant_lsps(&lsps[5], 5, &v[2], &vec_sizes[2], 2,
wmavoice_dq_lsp16i2, &mul_lsf[2], &base_lsf[2]);
dequant_lsps(&lsps[10], 6, &v[4], &vec_sizes[4], 1,
wmavoice_dq_lsp16i3, &mul_lsf[4], &base_lsf[4]);
}
/**
* Parse 16 independently-coded LSPs, and then derive the tables to
* generate LSPs for the other frames from them (residual coding).
*/
static void dequant_lsp16r(GetBitContext *gb,
double *i_lsps, const double *old,
double *a1, double *a2, int q_mode)
{
static const uint16_t vec_sizes[3] = { 128, 128, 128 };
static const double mul_lsf[3] = {
1.2232979501e-3, 1.4062241527e-3, 1.6114744851e-3
};
static const double base_lsf[3] = {
M_PI * -5.5830e-2, M_PI * -5.2908e-2, M_PI * -5.4776e-2
};
const float (*ipol_tab)[2][16] = q_mode ?
wmavoice_lsp16_intercoeff_b : wmavoice_lsp16_intercoeff_a;
uint16_t interpol, v[3];
int n;
dequant_lsp16i(gb, i_lsps);
interpol = get_bits(gb, 5);
v[0] = get_bits(gb, 7);
v[1] = get_bits(gb, 7);
v[2] = get_bits(gb, 7);
for (n = 0; n < 16; n++) {
double delta = old[n] - i_lsps[n];
a1[n] = ipol_tab[interpol][0][n] * delta + i_lsps[n];
a1[16 + n] = ipol_tab[interpol][1][n] * delta + i_lsps[n];
}
dequant_lsps( a2, 10, v, vec_sizes, 1,
wmavoice_dq_lsp16r1, mul_lsf, base_lsf);
dequant_lsps(&a2[10], 10, &v[1], &vec_sizes[1], 1,
wmavoice_dq_lsp16r2, &mul_lsf[1], &base_lsf[1]);
dequant_lsps(&a2[20], 12, &v[2], &vec_sizes[2], 1,
wmavoice_dq_lsp16r3, &mul_lsf[2], &base_lsf[2]);
}
/**
* @}
* @name Pitch-adaptive window coding functions
* The next few functions are for pitch-adaptive window coding.
* @{
*/
/**
* Parse the offset of the first pitch-adaptive window pulses, and
* the distribution of pulses between the two blocks in this frame.
* @param s WMA Voice decoding context private data
* @param gb bit I/O context
* @param pitch pitch for each block in this frame
*/
static void aw_parse_coords(WMAVoiceContext *s, GetBitContext *gb,
const int *pitch)
{
static const int16_t start_offset[94] = {
-11, -9, -7, -5, -3, -1, 1, 3, 5, 7, 9, 11,
13, 15, 18, 17, 19, 20, 21, 22, 23, 24, 25, 26,
27, 28, 29, 30, 31, 32, 33, 35, 37, 39, 41, 43,
45, 47, 49, 51, 53, 55, 57, 59, 61, 63, 65, 67,
69, 71, 73, 75, 77, 79, 81, 83, 85, 87, 89, 91,
93, 95, 97, 99, 101, 103, 105, 107, 109, 111, 113, 115,
117, 119, 121, 123, 125, 127, 129, 131, 133, 135, 137, 139,
141, 143, 145, 147, 149, 151, 153, 155, 157, 159
};
int bits, offset;
/* position of pulse */
s->aw_idx_is_ext = 0;
if ((bits = get_bits(gb, 6)) >= 54) {
s->aw_idx_is_ext = 1;
bits += (bits - 54) * 3 + get_bits(gb, 2);
}
/* for a repeated pulse at pulse_off with a pitch_lag of pitch[], count
* the distribution of the pulses in each block contained in this frame. */
s->aw_pulse_range = FFMIN(pitch[0], pitch[1]) > 32 ? 24 : 16;
for (offset = start_offset[bits]; offset < 0; offset += pitch[0]) ;
s->aw_n_pulses[0] = (pitch[0] - 1 + MAX_FRAMESIZE / 2 - offset) / pitch[0];
s->aw_first_pulse_off[0] = offset - s->aw_pulse_range / 2;
offset += s->aw_n_pulses[0] * pitch[0];
s->aw_n_pulses[1] = (pitch[1] - 1 + MAX_FRAMESIZE - offset) / pitch[1];
s->aw_first_pulse_off[1] = offset - (MAX_FRAMESIZE + s->aw_pulse_range) / 2;
/* if continuing from a position before the block, reset position to
* start of block (when corrected for the range over which it can be
* spread in aw_pulse_set1()). */
if (start_offset[bits] < MAX_FRAMESIZE / 2) {
while (s->aw_first_pulse_off[1] - pitch[1] + s->aw_pulse_range > 0)
s->aw_first_pulse_off[1] -= pitch[1];
if (start_offset[bits] < 0)
while (s->aw_first_pulse_off[0] - pitch[0] + s->aw_pulse_range > 0)
s->aw_first_pulse_off[0] -= pitch[0];
}
}
/**
* Apply second set of pitch-adaptive window pulses.
* @param s WMA Voice decoding context private data
* @param gb bit I/O context
* @param block_idx block index in frame [0, 1]
* @param fcb structure containing fixed codebook vector info
* @return -1 on error, 0 otherwise
*/
static int aw_pulse_set2(WMAVoiceContext *s, GetBitContext *gb,
int block_idx, AMRFixed *fcb)
{
uint16_t use_mask_mem[9]; // only 5 are used, rest is padding
uint16_t *use_mask = use_mask_mem + 2;
/* in this function, idx is the index in the 80-bit (+ padding) use_mask
* bit-array. Since use_mask consists of 16-bit values, the lower 4 bits
* of idx are the position of the bit within a particular item in the
* array (0 being the most significant bit, and 15 being the least
* significant bit), and the remainder (>> 4) is the index in the
* use_mask[]-array. This is faster and uses less memory than using a
* 80-byte/80-int array. */
int pulse_off = s->aw_first_pulse_off[block_idx],
pulse_start, n, idx, range, aidx, start_off = 0;
/* set offset of first pulse to within this block */
if (s->aw_n_pulses[block_idx] > 0)
while (pulse_off + s->aw_pulse_range < 1)
pulse_off += fcb->pitch_lag;
/* find range per pulse */
if (s->aw_n_pulses[0] > 0) {
if (block_idx == 0) {
range = 32;
} else /* block_idx = 1 */ {
range = 8;
if (s->aw_n_pulses[block_idx] > 0)
pulse_off = s->aw_next_pulse_off_cache;
}
} else
range = 16;
pulse_start = s->aw_n_pulses[block_idx] > 0 ? pulse_off - range / 2 : 0;
/* aw_pulse_set1() already applies pulses around pulse_off (to be exactly,
* in the range of [pulse_off, pulse_off + s->aw_pulse_range], and thus
* we exclude that range from being pulsed again in this function. */
memset(&use_mask[-2], 0, 2 * sizeof(use_mask[0]));
memset( use_mask, -1, 5 * sizeof(use_mask[0]));
memset(&use_mask[5], 0, 2 * sizeof(use_mask[0]));
if (s->aw_n_pulses[block_idx] > 0)
for (idx = pulse_off; idx < MAX_FRAMESIZE / 2; idx += fcb->pitch_lag) {
int excl_range = s->aw_pulse_range; // always 16 or 24
uint16_t *use_mask_ptr = &use_mask[idx >> 4];
int first_sh = 16 - (idx & 15);
*use_mask_ptr++ &= 0xFFFFu << first_sh;
excl_range -= first_sh;
if (excl_range >= 16) {
*use_mask_ptr++ = 0;
*use_mask_ptr &= 0xFFFF >> (excl_range - 16);
} else
*use_mask_ptr &= 0xFFFF >> excl_range;
}
/* find the 'aidx'th offset that is not excluded */
aidx = get_bits(gb, s->aw_n_pulses[0] > 0 ? 5 - 2 * block_idx : 4);
for (n = 0; n <= aidx; pulse_start++) {
for (idx = pulse_start; idx < 0; idx += fcb->pitch_lag) ;
if (idx >= MAX_FRAMESIZE / 2) { // find from zero
if (use_mask[0]) idx = 0x0F;
else if (use_mask[1]) idx = 0x1F;
else if (use_mask[2]) idx = 0x2F;
else if (use_mask[3]) idx = 0x3F;
else if (use_mask[4]) idx = 0x4F;
else return -1;
idx -= av_log2_16bit(use_mask[idx >> 4]);
}
if (use_mask[idx >> 4] & (0x8000 >> (idx & 15))) {
use_mask[idx >> 4] &= ~(0x8000 >> (idx & 15));
n++;
start_off = idx;
}
}
fcb->x[fcb->n] = start_off;
fcb->y[fcb->n] = get_bits1(gb) ? -1.0 : 1.0;
fcb->n++;
/* set offset for next block, relative to start of that block */
n = (MAX_FRAMESIZE / 2 - start_off) % fcb->pitch_lag;
s->aw_next_pulse_off_cache = n ? fcb->pitch_lag - n : 0;
return 0;
}
/**
* Apply first set of pitch-adaptive window pulses.
* @param s WMA Voice decoding context private data
* @param gb bit I/O context
* @param block_idx block index in frame [0, 1]
* @param fcb storage location for fixed codebook pulse info
*/
static void aw_pulse_set1(WMAVoiceContext *s, GetBitContext *gb,
int block_idx, AMRFixed *fcb)
{
int val = get_bits(gb, 12 - 2 * (s->aw_idx_is_ext && !block_idx));
float v;
if (s->aw_n_pulses[block_idx] > 0) {
int n, v_mask, i_mask, sh, n_pulses;
if (s->aw_pulse_range == 24) { // 3 pulses, 1:sign + 3:index each
n_pulses = 3;
v_mask = 8;
i_mask = 7;
sh = 4;
} else { // 4 pulses, 1:sign + 2:index each
n_pulses = 4;
v_mask = 4;
i_mask = 3;
sh = 3;
}
for (n = n_pulses - 1; n >= 0; n--, val >>= sh) {
fcb->y[fcb->n] = (val & v_mask) ? -1.0 : 1.0;
fcb->x[fcb->n] = (val & i_mask) * n_pulses + n +
s->aw_first_pulse_off[block_idx];
while (fcb->x[fcb->n] < 0)
fcb->x[fcb->n] += fcb->pitch_lag;
if (fcb->x[fcb->n] < MAX_FRAMESIZE / 2)
fcb->n++;
}
} else {
int num2 = (val & 0x1FF) >> 1, delta, idx;
if (num2 < 1 * 79) { delta = 1; idx = num2 + 1; }
else if (num2 < 2 * 78) { delta = 3; idx = num2 + 1 - 1 * 77; }
else if (num2 < 3 * 77) { delta = 5; idx = num2 + 1 - 2 * 76; }
else { delta = 7; idx = num2 + 1 - 3 * 75; }
v = (val & 0x200) ? -1.0 : 1.0;
fcb->no_repeat_mask |= 3 << fcb->n;
fcb->x[fcb->n] = idx - delta;
fcb->y[fcb->n] = v;
fcb->x[fcb->n + 1] = idx;
fcb->y[fcb->n + 1] = (val & 1) ? -v : v;
fcb->n += 2;
}
}
/**
* @}
*
* Generate a random number from frame_cntr and block_idx, which will live
* in the range [0, 1000 - block_size] (so it can be used as an index in a
* table of size 1000 of which you want to read block_size entries).
*
* @param frame_cntr current frame number
* @param block_num current block index
* @param block_size amount of entries we want to read from a table
* that has 1000 entries
* @return a (non-)random number in the [0, 1000 - block_size] range.
*/
static int pRNG(int frame_cntr, int block_num, int block_size)
{
/* array to simplify the calculation of z:
* y = (x % 9) * 5 + 6;
* z = (49995 * x) / y;
* Since y only has 9 values, we can remove the division by using a
* LUT and using FASTDIV-style divisions. For each of the 9 values
* of y, we can rewrite z as:
* z = x * (49995 / y) + x * ((49995 % y) / y)
* In this table, each col represents one possible value of y, the
* first number is 49995 / y, and the second is the FASTDIV variant
* of 49995 % y / y. */
static const unsigned int div_tbl[9][2] = {
{ 8332, 3 * 715827883U }, // y = 6
{ 4545, 0 * 390451573U }, // y = 11
{ 3124, 11 * 268435456U }, // y = 16
{ 2380, 15 * 204522253U }, // y = 21
{ 1922, 23 * 165191050U }, // y = 26
{ 1612, 23 * 138547333U }, // y = 31
{ 1388, 27 * 119304648U }, // y = 36
{ 1219, 16 * 104755300U }, // y = 41
{ 1086, 39 * 93368855U } // y = 46
};
unsigned int z, y, x = MUL16(block_num, 1877) + frame_cntr;
if (x >= 0xFFFF) x -= 0xFFFF; // max value of x is 8*1877+0xFFFE=0x13AA6,
// so this is effectively a modulo (%)
y = x - 9 * MULH(477218589, x); // x % 9
z = (uint16_t) (x * div_tbl[y][0] + UMULH(x, div_tbl[y][1]));
// z = x * 49995 / (y * 5 + 6)
return z % (1000 - block_size);
}
/**
* Parse hardcoded signal for a single block.
* @note see #synth_block().
*/
static void synth_block_hardcoded(WMAVoiceContext *s, GetBitContext *gb,
int block_idx, int size,
const struct frame_type_desc *frame_desc,
float *excitation)
{
float gain;
int n, r_idx;
av_assert0(size <= MAX_FRAMESIZE);
/* Set the offset from which we start reading wmavoice_std_codebook */
if (frame_desc->fcb_type == FCB_TYPE_SILENCE) {
r_idx = pRNG(s->frame_cntr, block_idx, size);
gain = s->silence_gain;
} else /* FCB_TYPE_HARDCODED */ {
r_idx = get_bits(gb, 8);
gain = wmavoice_gain_universal[get_bits(gb, 6)];
}
/* Clear gain prediction parameters */
memset(s->gain_pred_err, 0, sizeof(s->gain_pred_err));
/* Apply gain to hardcoded codebook and use that as excitation signal */
for (n = 0; n < size; n++)
excitation[n] = wmavoice_std_codebook[r_idx + n] * gain;
}
/**
* Parse FCB/ACB signal for a single block.
* @note see #synth_block().
*/
static void synth_block_fcb_acb(WMAVoiceContext *s, GetBitContext *gb,
int block_idx, int size,
int block_pitch_sh2,
const struct frame_type_desc *frame_desc,
float *excitation)
{
static const float gain_coeff[6] = {
0.8169, -0.06545, 0.1726, 0.0185, -0.0359, 0.0458
};
float pulses[MAX_FRAMESIZE / 2], pred_err, acb_gain, fcb_gain;
int n, idx, gain_weight;
AMRFixed fcb;
av_assert0(size <= MAX_FRAMESIZE / 2);
memset(pulses, 0, sizeof(*pulses) * size);
fcb.pitch_lag = block_pitch_sh2 >> 2;
fcb.pitch_fac = 1.0;
fcb.no_repeat_mask = 0;
fcb.n = 0;
/* For the other frame types, this is where we apply the innovation
* (fixed) codebook pulses of the speech signal. */
if (frame_desc->fcb_type == FCB_TYPE_AW_PULSES) {
aw_pulse_set1(s, gb, block_idx, &fcb);
if (aw_pulse_set2(s, gb, block_idx, &fcb)) {
/* Conceal the block with silence and return.
* Skip the correct amount of bits to read the next
* block from the correct offset. */
int r_idx = pRNG(s->frame_cntr, block_idx, size);
for (n = 0; n < size; n++)
excitation[n] =
wmavoice_std_codebook[r_idx + n] * s->silence_gain;
skip_bits(gb, 7 + 1);
return;
}
} else /* FCB_TYPE_EXC_PULSES */ {
int offset_nbits = 5 - frame_desc->log_n_blocks;
fcb.no_repeat_mask = -1;
/* similar to ff_decode_10_pulses_35bits(), but with single pulses
* (instead of double) for a subset of pulses */
for (n = 0; n < 5; n++) {
float sign;
int pos1, pos2;
sign = get_bits1(gb) ? 1.0 : -1.0;
pos1 = get_bits(gb, offset_nbits);
fcb.x[fcb.n] = n + 5 * pos1;
fcb.y[fcb.n++] = sign;
if (n < frame_desc->dbl_pulses) {
pos2 = get_bits(gb, offset_nbits);
fcb.x[fcb.n] = n + 5 * pos2;
fcb.y[fcb.n++] = (pos1 < pos2) ? -sign : sign;
}
}
}
ff_set_fixed_vector(pulses, &fcb, 1.0, size);
/* Calculate gain for adaptive & fixed codebook signal.
* see ff_amr_set_fixed_gain(). */
idx = get_bits(gb, 7);
fcb_gain = expf(avpriv_scalarproduct_float_c(s->gain_pred_err,
gain_coeff, 6) -
5.2409161640 + wmavoice_gain_codebook_fcb[idx]);
acb_gain = wmavoice_gain_codebook_acb[idx];
pred_err = av_clipf(wmavoice_gain_codebook_fcb[idx],
-2.9957322736 /* log(0.05) */,
1.6094379124 /* log(5.0) */);
gain_weight = 8 >> frame_desc->log_n_blocks;
memmove(&s->gain_pred_err[gain_weight], s->gain_pred_err,
sizeof(*s->gain_pred_err) * (6 - gain_weight));
for (n = 0; n < gain_weight; n++)
s->gain_pred_err[n] = pred_err;
/* Calculation of adaptive codebook */
if (frame_desc->acb_type == ACB_TYPE_ASYMMETRIC) {
int len;
for (n = 0; n < size; n += len) {
int next_idx_sh16;
int abs_idx = block_idx * size + n;
int pitch_sh16 = (s->last_pitch_val << 16) +
s->pitch_diff_sh16 * abs_idx;
int pitch = (pitch_sh16 + 0x6FFF) >> 16;
int idx_sh16 = ((pitch << 16) - pitch_sh16) * 8 + 0x58000;
idx = idx_sh16 >> 16;
if (s->pitch_diff_sh16) {
if (s->pitch_diff_sh16 > 0) {
next_idx_sh16 = (idx_sh16) &~ 0xFFFF;
} else
next_idx_sh16 = (idx_sh16 + 0x10000) &~ 0xFFFF;
len = av_clip((idx_sh16 - next_idx_sh16) / s->pitch_diff_sh16 / 8,
1, size - n);
} else
len = size;
ff_acelp_interpolatef(&excitation[n], &excitation[n - pitch],
wmavoice_ipol1_coeffs, 17,
idx, 9, len);
}
} else /* ACB_TYPE_HAMMING */ {
int block_pitch = block_pitch_sh2 >> 2;
idx = block_pitch_sh2 & 3;
if (idx) {
ff_acelp_interpolatef(excitation, &excitation[-block_pitch],
wmavoice_ipol2_coeffs, 4,
idx, 8, size);
} else
av_memcpy_backptr((uint8_t *) excitation, sizeof(float) * block_pitch,
sizeof(float) * size);
}
/* Interpolate ACB/FCB and use as excitation signal */
ff_weighted_vector_sumf(excitation, excitation, pulses,
acb_gain, fcb_gain, size);
}
/**
* Parse data in a single block.
*
* @param s WMA Voice decoding context private data
* @param gb bit I/O context
* @param block_idx index of the to-be-read block
* @param size amount of samples to be read in this block
* @param block_pitch_sh2 pitch for this block << 2
* @param lsps LSPs for (the end of) this frame
* @param prev_lsps LSPs for the last frame
* @param frame_desc frame type descriptor
* @param excitation target memory for the ACB+FCB interpolated signal
* @param synth target memory for the speech synthesis filter output
* @return 0 on success, <0 on error.
*/
static void synth_block(WMAVoiceContext *s, GetBitContext *gb,
int block_idx, int size,
int block_pitch_sh2,
const double *lsps, const double *prev_lsps,
const struct frame_type_desc *frame_desc,
float *excitation, float *synth)
{
double i_lsps[MAX_LSPS];
float lpcs[MAX_LSPS];
float fac;
int n;
if (frame_desc->acb_type == ACB_TYPE_NONE)
synth_block_hardcoded(s, gb, block_idx, size, frame_desc, excitation);
else
synth_block_fcb_acb(s, gb, block_idx, size, block_pitch_sh2,
frame_desc, excitation);
/* convert interpolated LSPs to LPCs */
fac = (block_idx + 0.5) / frame_desc->n_blocks;
for (n = 0; n < s->lsps; n++) // LSF -> LSP
i_lsps[n] = cos(prev_lsps[n] + fac * (lsps[n] - prev_lsps[n]));
ff_acelp_lspd2lpc(i_lsps, lpcs, s->lsps >> 1);
/* Speech synthesis */
ff_celp_lp_synthesis_filterf(synth, lpcs, excitation, size, s->lsps);
}
/**
* Synthesize output samples for a single frame.
*
* @param ctx WMA Voice decoder context
* @param gb bit I/O context (s->gb or one for cross-packet superframes)
* @param frame_idx Frame number within superframe [0-2]
* @param samples pointer to output sample buffer, has space for at least 160
* samples
* @param lsps LSP array
* @param prev_lsps array of previous frame's LSPs
* @param excitation target buffer for excitation signal
* @param synth target buffer for synthesized speech data
* @return 0 on success, <0 on error.
*/
static int synth_frame(AVCodecContext *ctx, GetBitContext *gb, int frame_idx,
float *samples,
const double *lsps, const double *prev_lsps,
float *excitation, float *synth)
{
WMAVoiceContext *s = ctx->priv_data;
int n, n_blocks_x2, log_n_blocks_x2, av_uninit(cur_pitch_val);
int pitch[MAX_BLOCKS], av_uninit(last_block_pitch);
/* Parse frame type ("frame header"), see frame_descs */
int bd_idx = s->vbm_tree[get_vlc2(gb, frame_type_vlc.table, 6, 3)], block_nsamples;
if (bd_idx < 0) {
av_log(ctx, AV_LOG_ERROR,
"Invalid frame type VLC code, skipping\n");
return AVERROR_INVALIDDATA;
}
block_nsamples = MAX_FRAMESIZE / frame_descs[bd_idx].n_blocks;
/* Pitch calculation for ACB_TYPE_ASYMMETRIC ("pitch-per-frame") */
if (frame_descs[bd_idx].acb_type == ACB_TYPE_ASYMMETRIC) {
/* Pitch is provided per frame, which is interpreted as the pitch of
* the last sample of the last block of this frame. We can interpolate
* the pitch of other blocks (and even pitch-per-sample) by gradually
* incrementing/decrementing prev_frame_pitch to cur_pitch_val. */
n_blocks_x2 = frame_descs[bd_idx].n_blocks << 1;
log_n_blocks_x2 = frame_descs[bd_idx].log_n_blocks + 1;
cur_pitch_val = s->min_pitch_val + get_bits(gb, s->pitch_nbits);
cur_pitch_val = FFMIN(cur_pitch_val, s->max_pitch_val - 1);
if (s->last_acb_type == ACB_TYPE_NONE ||
20 * abs(cur_pitch_val - s->last_pitch_val) >
(cur_pitch_val + s->last_pitch_val))
s->last_pitch_val = cur_pitch_val;
/* pitch per block */
for (n = 0; n < frame_descs[bd_idx].n_blocks; n++) {
int fac = n * 2 + 1;
pitch[n] = (MUL16(fac, cur_pitch_val) +
MUL16((n_blocks_x2 - fac), s->last_pitch_val) +
frame_descs[bd_idx].n_blocks) >> log_n_blocks_x2;
}
/* "pitch-diff-per-sample" for calculation of pitch per sample */
s->pitch_diff_sh16 =
(cur_pitch_val - s->last_pitch_val) * (1 << 16) / MAX_FRAMESIZE;
}
/* Global gain (if silence) and pitch-adaptive window coordinates */
switch (frame_descs[bd_idx].fcb_type) {
case FCB_TYPE_SILENCE:
s->silence_gain = wmavoice_gain_silence[get_bits(gb, 8)];
break;
case FCB_TYPE_AW_PULSES:
aw_parse_coords(s, gb, pitch);
break;
}
for (n = 0; n < frame_descs[bd_idx].n_blocks; n++) {
int bl_pitch_sh2;
/* Pitch calculation for ACB_TYPE_HAMMING ("pitch-per-block") */
switch (frame_descs[bd_idx].acb_type) {
case ACB_TYPE_HAMMING: {
/* Pitch is given per block. Per-block pitches are encoded as an
* absolute value for the first block, and then delta values
* relative to this value) for all subsequent blocks. The scale of
* this pitch value is semi-logarithmic compared to its use in the
* decoder, so we convert it to normal scale also. */
int block_pitch,
t1 = (s->block_conv_table[1] - s->block_conv_table[0]) << 2,
t2 = (s->block_conv_table[2] - s->block_conv_table[1]) << 1,
t3 = s->block_conv_table[3] - s->block_conv_table[2] + 1;
if (n == 0) {
block_pitch = get_bits(gb, s->block_pitch_nbits);
} else
block_pitch = last_block_pitch - s->block_delta_pitch_hrange +
get_bits(gb, s->block_delta_pitch_nbits);
/* Convert last_ so that any next delta is within _range */
last_block_pitch = av_clip(block_pitch,
s->block_delta_pitch_hrange,
s->block_pitch_range -
s->block_delta_pitch_hrange);
/* Convert semi-log-style scale back to normal scale */
if (block_pitch < t1) {
bl_pitch_sh2 = (s->block_conv_table[0] << 2) + block_pitch;
} else {
block_pitch -= t1;
if (block_pitch < t2) {
bl_pitch_sh2 =
(s->block_conv_table[1] << 2) + (block_pitch << 1);
} else {
block_pitch -= t2;
if (block_pitch < t3) {
bl_pitch_sh2 =
(s->block_conv_table[2] + block_pitch) << 2;
} else
bl_pitch_sh2 = s->block_conv_table[3] << 2;
}
}
pitch[n] = bl_pitch_sh2 >> 2;
break;
}
case ACB_TYPE_ASYMMETRIC: {
bl_pitch_sh2 = pitch[n] << 2;
break;
}
default: // ACB_TYPE_NONE has no pitch
bl_pitch_sh2 = 0;
break;
}
synth_block(s, gb, n, block_nsamples, bl_pitch_sh2,
lsps, prev_lsps, &frame_descs[bd_idx],
&excitation[n * block_nsamples],
&synth[n * block_nsamples]);
}
/* Averaging projection filter, if applicable. Else, just copy samples
* from synthesis buffer */
if (s->do_apf) {
double i_lsps[MAX_LSPS];
float lpcs[MAX_LSPS];
for (n = 0; n < s->lsps; n++) // LSF -> LSP
i_lsps[n] = cos(0.5 * (prev_lsps[n] + lsps[n]));
ff_acelp_lspd2lpc(i_lsps, lpcs, s->lsps >> 1);
postfilter(s, synth, samples, 80, lpcs,
&s->zero_exc_pf[s->history_nsamples + MAX_FRAMESIZE * frame_idx],
frame_descs[bd_idx].fcb_type, pitch[0]);
for (n = 0; n < s->lsps; n++) // LSF -> LSP
i_lsps[n] = cos(lsps[n]);
ff_acelp_lspd2lpc(i_lsps, lpcs, s->lsps >> 1);
postfilter(s, &synth[80], &samples[80], 80, lpcs,
&s->zero_exc_pf[s->history_nsamples + MAX_FRAMESIZE * frame_idx + 80],
frame_descs[bd_idx].fcb_type, pitch[0]);
} else
memcpy(samples, synth, 160 * sizeof(synth[0]));
/* Cache values for next frame */
s->frame_cntr++;
if (s->frame_cntr >= 0xFFFF) s->frame_cntr -= 0xFFFF; // i.e. modulo (%)
s->last_acb_type = frame_descs[bd_idx].acb_type;
switch (frame_descs[bd_idx].acb_type) {
case ACB_TYPE_NONE:
s->last_pitch_val = 0;
break;
case ACB_TYPE_ASYMMETRIC:
s->last_pitch_val = cur_pitch_val;
break;
case ACB_TYPE_HAMMING:
s->last_pitch_val = pitch[frame_descs[bd_idx].n_blocks - 1];
break;
}
return 0;
}
/**
* Ensure minimum value for first item, maximum value for last value,
* proper spacing between each value and proper ordering.
*
* @param lsps array of LSPs
* @param num size of LSP array
*
* @note basically a double version of #ff_acelp_reorder_lsf(), might be
* useful to put in a generic location later on. Parts are also
* present in #ff_set_min_dist_lsf() + #ff_sort_nearly_sorted_floats(),
* which is in float.
*/
static void stabilize_lsps(double *lsps, int num)
{
int n, m, l;
/* set minimum value for first, maximum value for last and minimum
* spacing between LSF values.
* Very similar to ff_set_min_dist_lsf(), but in double. */
lsps[0] = FFMAX(lsps[0], 0.0015 * M_PI);
for (n = 1; n < num; n++)
lsps[n] = FFMAX(lsps[n], lsps[n - 1] + 0.0125 * M_PI);
lsps[num - 1] = FFMIN(lsps[num - 1], 0.9985 * M_PI);
/* reorder (looks like one-time / non-recursed bubblesort).
* Very similar to ff_sort_nearly_sorted_floats(), but in double. */
for (n = 1; n < num; n++) {
if (lsps[n] < lsps[n - 1]) {
for (m = 1; m < num; m++) {
double tmp = lsps[m];
for (l = m - 1; l >= 0; l--) {
if (lsps[l] <= tmp) break;
lsps[l + 1] = lsps[l];
}
lsps[l + 1] = tmp;
}
break;
}
}
}
/**
* Synthesize output samples for a single superframe. If we have any data
* cached in s->sframe_cache, that will be used instead of whatever is loaded
* in s->gb.
*
* WMA Voice superframes contain 3 frames, each containing 160 audio samples,
* to give a total of 480 samples per frame. See #synth_frame() for frame
* parsing. In addition to 3 frames, superframes can also contain the LSPs
* (if these are globally specified for all frames (residually); they can
* also be specified individually per-frame. See the s->has_residual_lsps
* option), and can specify the number of samples encoded in this superframe
* (if less than 480), usually used to prevent blanks at track boundaries.
*
* @param ctx WMA Voice decoder context
* @return 0 on success, <0 on error or 1 if there was not enough data to
* fully parse the superframe
*/
static int synth_superframe(AVCodecContext *ctx, AVFrame *frame,
int *got_frame_ptr)
{
WMAVoiceContext *s = ctx->priv_data;
GetBitContext *gb = &s->gb, s_gb;
int n, res, n_samples = MAX_SFRAMESIZE;
double lsps[MAX_FRAMES][MAX_LSPS];
const double *mean_lsf = s->lsps == 16 ?
wmavoice_mean_lsf16[s->lsp_def_mode] : wmavoice_mean_lsf10[s->lsp_def_mode];
float excitation[MAX_SIGNAL_HISTORY + MAX_SFRAMESIZE + 12];
float synth[MAX_LSPS + MAX_SFRAMESIZE];
float *samples;
memcpy(synth, s->synth_history,
s->lsps * sizeof(*synth));
memcpy(excitation, s->excitation_history,
s->history_nsamples * sizeof(*excitation));
if (s->sframe_cache_size > 0) {
gb = &s_gb;
init_get_bits(gb, s->sframe_cache, s->sframe_cache_size);
s->sframe_cache_size = 0;
}
/* First bit is speech/music bit, it differentiates between WMAVoice
* speech samples (the actual codec) and WMAVoice music samples, which
* are really WMAPro-in-WMAVoice-superframes. I've never seen those in
* the wild yet. */
if (!get_bits1(gb)) {
avpriv_request_sample(ctx, "WMAPro-in-WMAVoice");
return AVERROR_PATCHWELCOME;
}
/* (optional) nr. of samples in superframe; always <= 480 and >= 0 */
if (get_bits1(gb)) {
if ((n_samples = get_bits(gb, 12)) > MAX_SFRAMESIZE) {
av_log(ctx, AV_LOG_ERROR,
"Superframe encodes > %d samples (%d), not allowed\n",
MAX_SFRAMESIZE, n_samples);
return AVERROR_INVALIDDATA;
}
}
/* Parse LSPs, if global for the superframe (can also be per-frame). */
if (s->has_residual_lsps) {
double prev_lsps[MAX_LSPS], a1[MAX_LSPS * 2], a2[MAX_LSPS * 2];
for (n = 0; n < s->lsps; n++)
prev_lsps[n] = s->prev_lsps[n] - mean_lsf[n];
if (s->lsps == 10) {
dequant_lsp10r(gb, lsps[2], prev_lsps, a1, a2, s->lsp_q_mode);
} else /* s->lsps == 16 */
dequant_lsp16r(gb, lsps[2], prev_lsps, a1, a2, s->lsp_q_mode);
for (n = 0; n < s->lsps; n++) {
lsps[0][n] = mean_lsf[n] + (a1[n] - a2[n * 2]);
lsps[1][n] = mean_lsf[n] + (a1[s->lsps + n] - a2[n * 2 + 1]);
lsps[2][n] += mean_lsf[n];
}
for (n = 0; n < 3; n++)
stabilize_lsps(lsps[n], s->lsps);
}
/* synth_superframe can run multiple times per packet
* free potential previous frame */
av_frame_unref(frame);
/* get output buffer */
frame->nb_samples = MAX_SFRAMESIZE;
if ((res = ff_get_buffer(ctx, frame, 0)) < 0)
return res;
frame->nb_samples = n_samples;
samples = (float *)frame->data[0];
/* Parse frames, optionally preceded by per-frame (independent) LSPs. */
for (n = 0; n < 3; n++) {
if (!s->has_residual_lsps) {
int m;
if (s->lsps == 10) {
dequant_lsp10i(gb, lsps[n]);
} else /* s->lsps == 16 */
dequant_lsp16i(gb, lsps[n]);
for (m = 0; m < s->lsps; m++)
lsps[n][m] += mean_lsf[m];
stabilize_lsps(lsps[n], s->lsps);
}
if ((res = synth_frame(ctx, gb, n,
&samples[n * MAX_FRAMESIZE],
lsps[n], n == 0 ? s->prev_lsps : lsps[n - 1],
&excitation[s->history_nsamples + n * MAX_FRAMESIZE],
&synth[s->lsps + n * MAX_FRAMESIZE]))) {
*got_frame_ptr = 0;
return res;
}
}
/* Statistics? FIXME - we don't check for length, a slight overrun
* will be caught by internal buffer padding, and anything else
* will be skipped, not read. */
if (get_bits1(gb)) {
res = get_bits(gb, 4);
skip_bits(gb, 10 * (res + 1));
}
if (get_bits_left(gb) < 0) {
wmavoice_flush(ctx);
return AVERROR_INVALIDDATA;
}
*got_frame_ptr = 1;
/* Update history */
memcpy(s->prev_lsps, lsps[2],
s->lsps * sizeof(*s->prev_lsps));
memcpy(s->synth_history, &synth[MAX_SFRAMESIZE],
s->lsps * sizeof(*synth));
memcpy(s->excitation_history, &excitation[MAX_SFRAMESIZE],
s->history_nsamples * sizeof(*excitation));
if (s->do_apf)
memmove(s->zero_exc_pf, &s->zero_exc_pf[MAX_SFRAMESIZE],
s->history_nsamples * sizeof(*s->zero_exc_pf));
return 0;
}
/**
* Parse the packet header at the start of each packet (input data to this
* decoder).
*
* @param s WMA Voice decoding context private data
* @return <0 on error, nb_superframes on success.
*/
static int parse_packet_header(WMAVoiceContext *s)
{
GetBitContext *gb = &s->gb;
unsigned int res, n_superframes = 0;
skip_bits(gb, 4); // packet sequence number
s->has_residual_lsps = get_bits1(gb);
do {
if (get_bits_left(gb) < 6 + s->spillover_bitsize)
return AVERROR_INVALIDDATA;
res = get_bits(gb, 6); // number of superframes per packet
// (minus first one if there is spillover)
n_superframes += res;
} while (res == 0x3F);
s->spillover_nbits = get_bits(gb, s->spillover_bitsize);
return get_bits_left(gb) >= 0 ? n_superframes : AVERROR_INVALIDDATA;
}
/**
* Copy (unaligned) bits from gb/data/size to pb.
*
* @param pb target buffer to copy bits into
* @param data source buffer to copy bits from
* @param size size of the source data, in bytes
* @param gb bit I/O context specifying the current position in the source.
* data. This function might use this to align the bit position to
* a whole-byte boundary before calling #ff_copy_bits() on aligned
* source data
* @param nbits the amount of bits to copy from source to target
*
* @note after calling this function, the current position in the input bit
* I/O context is undefined.
*/
static void copy_bits(PutBitContext *pb,
const uint8_t *data, int size,
GetBitContext *gb, int nbits)
{
int rmn_bytes, rmn_bits;
rmn_bits = rmn_bytes = get_bits_left(gb);
if (rmn_bits < nbits)
return;
if (nbits > put_bits_left(pb))
return;
rmn_bits &= 7; rmn_bytes >>= 3;
if ((rmn_bits = FFMIN(rmn_bits, nbits)) > 0)
put_bits(pb, rmn_bits, get_bits(gb, rmn_bits));
ff_copy_bits(pb, data + size - rmn_bytes,
FFMIN(nbits - rmn_bits, rmn_bytes << 3));
}
/**
* Packet decoding: a packet is anything that the (ASF) demuxer contains,
* and we expect that the demuxer / application provides it to us as such
* (else you'll probably get garbage as output). Every packet has a size of
* ctx->block_align bytes, starts with a packet header (see
* #parse_packet_header()), and then a series of superframes. Superframe
* boundaries may exceed packets, i.e. superframes can split data over
* multiple (two) packets.
*
* For more information about frames, see #synth_superframe().
*/
static int wmavoice_decode_packet(AVCodecContext *ctx, AVFrame *frame,
int *got_frame_ptr, AVPacket *avpkt)
{
WMAVoiceContext *s = ctx->priv_data;
GetBitContext *gb = &s->gb;
const uint8_t *buf = avpkt->data;
uint8_t dummy[1];
int size, res, pos;
/* Packets are sometimes a multiple of ctx->block_align, with a packet
* header at each ctx->block_align bytes. However, FFmpeg's ASF demuxer
* feeds us ASF packets, which may concatenate multiple "codec" packets
* in a single "muxer" packet, so we artificially emulate that by
* capping the packet size at ctx->block_align. */
for (size = avpkt->size; size > ctx->block_align; size -= ctx->block_align);
buf = size ? buf : dummy;
res = init_get_bits8(&s->gb, buf, size);
if (res < 0)
return res;
/* size == ctx->block_align is used to indicate whether we are dealing with
* a new packet or a packet of which we already read the packet header
* previously. */
if (!(size % ctx->block_align)) { // new packet header
if (!size) {
s->spillover_nbits = 0;
s->nb_superframes = 0;
} else {
if ((res = parse_packet_header(s)) < 0)
return res;
s->nb_superframes = res;
}
/* If the packet header specifies a s->spillover_nbits, then we want
* to push out all data of the previous packet (+ spillover) before
* continuing to parse new superframes in the current packet. */
if (s->sframe_cache_size > 0) {
int cnt = get_bits_count(gb);
if (cnt + s->spillover_nbits > avpkt->size * 8) {
s->spillover_nbits = avpkt->size * 8 - cnt;
}
copy_bits(&s->pb, buf, size, gb, s->spillover_nbits);
flush_put_bits(&s->pb);
s->sframe_cache_size += s->spillover_nbits;
if ((res = synth_superframe(ctx, frame, got_frame_ptr)) == 0 &&
*got_frame_ptr) {
cnt += s->spillover_nbits;
s->skip_bits_next = cnt & 7;
res = cnt >> 3;
return res;
} else
skip_bits_long (gb, s->spillover_nbits - cnt +
get_bits_count(gb)); // resync
} else if (s->spillover_nbits) {
skip_bits_long(gb, s->spillover_nbits); // resync
}
} else if (s->skip_bits_next)
skip_bits(gb, s->skip_bits_next);
/* Try parsing superframes in current packet */
s->sframe_cache_size = 0;
s->skip_bits_next = 0;
pos = get_bits_left(gb);
if (s->nb_superframes-- == 0) {
*got_frame_ptr = 0;
return size;
} else if (s->nb_superframes > 0) {
if ((res = synth_superframe(ctx, frame, got_frame_ptr)) < 0) {
return res;
} else if (*got_frame_ptr) {
int cnt = get_bits_count(gb);
s->skip_bits_next = cnt & 7;
res = cnt >> 3;
return res;
}
} else if ((s->sframe_cache_size = pos) > 0) {
/* ... cache it for spillover in next packet */
init_put_bits(&s->pb, s->sframe_cache, SFRAME_CACHE_MAXSIZE);
copy_bits(&s->pb, buf, size, gb, s->sframe_cache_size);
// FIXME bad - just copy bytes as whole and add use the
// skip_bits_next field
}
return size;
}
static av_cold int wmavoice_decode_end(AVCodecContext *ctx)
{
WMAVoiceContext *s = ctx->priv_data;
if (s->do_apf) {
ff_rdft_end(&s->rdft);
ff_rdft_end(&s->irdft);
ff_dct_end(&s->dct);
ff_dct_end(&s->dst);
}
return 0;
}
const FFCodec ff_wmavoice_decoder = {
.p.name = "wmavoice",
CODEC_LONG_NAME("Windows Media Audio Voice"),
.p.type = AVMEDIA_TYPE_AUDIO,
.p.id = AV_CODEC_ID_WMAVOICE,
.priv_data_size = sizeof(WMAVoiceContext),
.init = wmavoice_decode_init,
.close = wmavoice_decode_end,
FF_CODEC_DECODE_CB(wmavoice_decode_packet),
.p.capabilities = AV_CODEC_CAP_SUBFRAMES | AV_CODEC_CAP_DR1 | AV_CODEC_CAP_DELAY,
.caps_internal = FF_CODEC_CAP_INIT_CLEANUP,
.flush = wmavoice_flush,
};
|
4d7b3e06c086d97251dc455882a4d7c2cb2689a4
|
840c14eae43e7b915d5fb23f84eb6f856c755b92
|
/IpaDownloadTool/Pods/Headers/Private/ZXTableView/ZXTableView.h
|
a68a8bb3773e6d690c6753e2aeca3ca2865a0b73
|
[
"MIT"
] |
permissive
|
SmileZXLee/IpaDownloadTool
|
a010aab3cdf67342a8a4cf3c888919b88c651f56
|
d1bdf376409da35207cd8d76d500f23c6167abc3
|
refs/heads/master
| 2023-08-16T23:58:47.346568
| 2023-08-12T12:37:04
| 2023-08-12T12:37:04
| 184,110,012
| 487
| 66
| null | null | null | null |
UTF-8
|
C
| false
| false
| 46
|
h
|
ZXTableView.h
|
../../../ZXTableView/ZXTableView/ZXTableView.h
|
51f3a4ec446cce4663052a9c3282c59a0fddb7ef
|
7eaf54a78c9e2117247cb2ab6d3a0c20719ba700
|
/SOFTWARE/A64-TERES/linux-a64/drivers/scsi/arm/cumana_2.c
|
58915f29055b8050774ce2610f987092ad8d60a1
|
[
"LicenseRef-scancode-free-unknown",
"Apache-2.0",
"Linux-syscall-note",
"GPL-2.0-only",
"GPL-1.0-or-later"
] |
permissive
|
OLIMEX/DIY-LAPTOP
|
ae82f4ee79c641d9aee444db9a75f3f6709afa92
|
a3fafd1309135650bab27f5eafc0c32bc3ca74ee
|
refs/heads/rel3
| 2023-08-04T01:54:19.483792
| 2023-04-03T07:18:12
| 2023-04-03T07:18:12
| 80,094,055
| 507
| 92
|
Apache-2.0
| 2023-04-03T07:05:59
| 2017-01-26T07:25:50
|
C
|
UTF-8
|
C
| false
| false
| 13,776
|
c
|
cumana_2.c
|
/*
* linux/drivers/acorn/scsi/cumana_2.c
*
* Copyright (C) 1997-2005 Russell King
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* Changelog:
* 30-08-1997 RMK 0.0.0 Created, READONLY version.
* 22-01-1998 RMK 0.0.1 Updated to 2.1.80.
* 15-04-1998 RMK 0.0.1 Only do PIO if FAS216 will allow it.
* 02-05-1998 RMK 0.0.2 Updated & added DMA support.
* 27-06-1998 RMK Changed asm/delay.h to linux/delay.h
* 18-08-1998 RMK 0.0.3 Fixed synchronous transfer depth.
* 02-04-2000 RMK 0.0.4 Updated for new error handling code.
*/
#include <linux/module.h>
#include <linux/blkdev.h>
#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/ioport.h>
#include <linux/proc_fs.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/init.h>
#include <linux/dma-mapping.h>
#include <asm/dma.h>
#include <asm/ecard.h>
#include <asm/io.h>
#include <asm/pgtable.h>
#include "../scsi.h"
#include <scsi/scsi_host.h>
#include "fas216.h"
#include "scsi.h"
#include <scsi/scsicam.h>
#define CUMANASCSI2_STATUS (0x0000)
#define STATUS_INT (1 << 0)
#define STATUS_DRQ (1 << 1)
#define STATUS_LATCHED (1 << 3)
#define CUMANASCSI2_ALATCH (0x0014)
#define ALATCH_ENA_INT (3)
#define ALATCH_DIS_INT (2)
#define ALATCH_ENA_TERM (5)
#define ALATCH_DIS_TERM (4)
#define ALATCH_ENA_BIT32 (11)
#define ALATCH_DIS_BIT32 (10)
#define ALATCH_ENA_DMA (13)
#define ALATCH_DIS_DMA (12)
#define ALATCH_DMA_OUT (15)
#define ALATCH_DMA_IN (14)
#define CUMANASCSI2_PSEUDODMA (0x0200)
#define CUMANASCSI2_FAS216_OFFSET (0x0300)
#define CUMANASCSI2_FAS216_SHIFT 2
/*
* Version
*/
#define VERSION "1.00 (13/11/2002 2.5.47)"
/*
* Use term=0,1,0,0,0 to turn terminators on/off
*/
static int term[MAX_ECARDS] = { 1, 1, 1, 1, 1, 1, 1, 1 };
#define NR_SG 256
struct cumanascsi2_info {
FAS216_Info info;
struct expansion_card *ec;
void __iomem *base;
unsigned int terms; /* Terminator state */
struct scatterlist sg[NR_SG]; /* Scatter DMA list */
};
#define CSTATUS_IRQ (1 << 0)
#define CSTATUS_DRQ (1 << 1)
/* Prototype: void cumanascsi_2_irqenable(ec, irqnr)
* Purpose : Enable interrupts on Cumana SCSI 2 card
* Params : ec - expansion card structure
* : irqnr - interrupt number
*/
static void
cumanascsi_2_irqenable(struct expansion_card *ec, int irqnr)
{
struct cumanascsi2_info *info = ec->irq_data;
writeb(ALATCH_ENA_INT, info->base + CUMANASCSI2_ALATCH);
}
/* Prototype: void cumanascsi_2_irqdisable(ec, irqnr)
* Purpose : Disable interrupts on Cumana SCSI 2 card
* Params : ec - expansion card structure
* : irqnr - interrupt number
*/
static void
cumanascsi_2_irqdisable(struct expansion_card *ec, int irqnr)
{
struct cumanascsi2_info *info = ec->irq_data;
writeb(ALATCH_DIS_INT, info->base + CUMANASCSI2_ALATCH);
}
static const expansioncard_ops_t cumanascsi_2_ops = {
.irqenable = cumanascsi_2_irqenable,
.irqdisable = cumanascsi_2_irqdisable,
};
/* Prototype: void cumanascsi_2_terminator_ctl(host, on_off)
* Purpose : Turn the Cumana SCSI 2 terminators on or off
* Params : host - card to turn on/off
* : on_off - !0 to turn on, 0 to turn off
*/
static void
cumanascsi_2_terminator_ctl(struct Scsi_Host *host, int on_off)
{
struct cumanascsi2_info *info = (struct cumanascsi2_info *)host->hostdata;
if (on_off) {
info->terms = 1;
writeb(ALATCH_ENA_TERM, info->base + CUMANASCSI2_ALATCH);
} else {
info->terms = 0;
writeb(ALATCH_DIS_TERM, info->base + CUMANASCSI2_ALATCH);
}
}
/* Prototype: void cumanascsi_2_intr(irq, *dev_id, *regs)
* Purpose : handle interrupts from Cumana SCSI 2 card
* Params : irq - interrupt number
* dev_id - user-defined (Scsi_Host structure)
*/
static irqreturn_t
cumanascsi_2_intr(int irq, void *dev_id)
{
struct cumanascsi2_info *info = dev_id;
return fas216_intr(&info->info);
}
/* Prototype: fasdmatype_t cumanascsi_2_dma_setup(host, SCpnt, direction, min_type)
* Purpose : initialises DMA/PIO
* Params : host - host
* SCpnt - command
* direction - DMA on to/off of card
* min_type - minimum DMA support that we must have for this transfer
* Returns : type of transfer to be performed
*/
static fasdmatype_t
cumanascsi_2_dma_setup(struct Scsi_Host *host, struct scsi_pointer *SCp,
fasdmadir_t direction, fasdmatype_t min_type)
{
struct cumanascsi2_info *info = (struct cumanascsi2_info *)host->hostdata;
struct device *dev = scsi_get_device(host);
int dmach = info->info.scsi.dma;
writeb(ALATCH_DIS_DMA, info->base + CUMANASCSI2_ALATCH);
if (dmach != NO_DMA &&
(min_type == fasdma_real_all || SCp->this_residual >= 512)) {
int bufs, map_dir, dma_dir, alatch_dir;
bufs = copy_SCp_to_sg(&info->sg[0], SCp, NR_SG);
if (direction == DMA_OUT)
map_dir = DMA_TO_DEVICE,
dma_dir = DMA_MODE_WRITE,
alatch_dir = ALATCH_DMA_OUT;
else
map_dir = DMA_FROM_DEVICE,
dma_dir = DMA_MODE_READ,
alatch_dir = ALATCH_DMA_IN;
dma_map_sg(dev, info->sg, bufs, map_dir);
disable_dma(dmach);
set_dma_sg(dmach, info->sg, bufs);
writeb(alatch_dir, info->base + CUMANASCSI2_ALATCH);
set_dma_mode(dmach, dma_dir);
enable_dma(dmach);
writeb(ALATCH_ENA_DMA, info->base + CUMANASCSI2_ALATCH);
writeb(ALATCH_DIS_BIT32, info->base + CUMANASCSI2_ALATCH);
return fasdma_real_all;
}
/*
* If we're not doing DMA,
* we'll do pseudo DMA
*/
return fasdma_pio;
}
/*
* Prototype: void cumanascsi_2_dma_pseudo(host, SCpnt, direction, transfer)
* Purpose : handles pseudo DMA
* Params : host - host
* SCpnt - command
* direction - DMA on to/off of card
* transfer - minimum number of bytes we expect to transfer
*/
static void
cumanascsi_2_dma_pseudo(struct Scsi_Host *host, struct scsi_pointer *SCp,
fasdmadir_t direction, int transfer)
{
struct cumanascsi2_info *info = (struct cumanascsi2_info *)host->hostdata;
unsigned int length;
unsigned char *addr;
length = SCp->this_residual;
addr = SCp->ptr;
if (direction == DMA_OUT)
#if 0
while (length > 1) {
unsigned long word;
unsigned int status = readb(info->base + CUMANASCSI2_STATUS);
if (status & STATUS_INT)
goto end;
if (!(status & STATUS_DRQ))
continue;
word = *addr | *(addr + 1) << 8;
writew(word, info->base + CUMANASCSI2_PSEUDODMA);
addr += 2;
length -= 2;
}
#else
printk ("PSEUDO_OUT???\n");
#endif
else {
if (transfer && (transfer & 255)) {
while (length >= 256) {
unsigned int status = readb(info->base + CUMANASCSI2_STATUS);
if (status & STATUS_INT)
return;
if (!(status & STATUS_DRQ))
continue;
readsw(info->base + CUMANASCSI2_PSEUDODMA,
addr, 256 >> 1);
addr += 256;
length -= 256;
}
}
while (length > 0) {
unsigned long word;
unsigned int status = readb(info->base + CUMANASCSI2_STATUS);
if (status & STATUS_INT)
return;
if (!(status & STATUS_DRQ))
continue;
word = readw(info->base + CUMANASCSI2_PSEUDODMA);
*addr++ = word;
if (--length > 0) {
*addr++ = word >> 8;
length --;
}
}
}
}
/* Prototype: int cumanascsi_2_dma_stop(host, SCpnt)
* Purpose : stops DMA/PIO
* Params : host - host
* SCpnt - command
*/
static void
cumanascsi_2_dma_stop(struct Scsi_Host *host, struct scsi_pointer *SCp)
{
struct cumanascsi2_info *info = (struct cumanascsi2_info *)host->hostdata;
if (info->info.scsi.dma != NO_DMA) {
writeb(ALATCH_DIS_DMA, info->base + CUMANASCSI2_ALATCH);
disable_dma(info->info.scsi.dma);
}
}
/* Prototype: const char *cumanascsi_2_info(struct Scsi_Host * host)
* Purpose : returns a descriptive string about this interface,
* Params : host - driver host structure to return info for.
* Returns : pointer to a static buffer containing null terminated string.
*/
const char *cumanascsi_2_info(struct Scsi_Host *host)
{
struct cumanascsi2_info *info = (struct cumanascsi2_info *)host->hostdata;
static char string[150];
sprintf(string, "%s (%s) in slot %d v%s terminators o%s",
host->hostt->name, info->info.scsi.type, info->ec->slot_no,
VERSION, info->terms ? "n" : "ff");
return string;
}
/* Prototype: int cumanascsi_2_set_proc_info(struct Scsi_Host *host, char *buffer, int length)
* Purpose : Set a driver specific function
* Params : host - host to setup
* : buffer - buffer containing string describing operation
* : length - length of string
* Returns : -EINVAL, or 0
*/
static int
cumanascsi_2_set_proc_info(struct Scsi_Host *host, char *buffer, int length)
{
int ret = length;
if (length >= 11 && strncmp(buffer, "CUMANASCSI2", 11) == 0) {
buffer += 11;
length -= 11;
if (length >= 5 && strncmp(buffer, "term=", 5) == 0) {
if (buffer[5] == '1')
cumanascsi_2_terminator_ctl(host, 1);
else if (buffer[5] == '0')
cumanascsi_2_terminator_ctl(host, 0);
else
ret = -EINVAL;
} else
ret = -EINVAL;
} else
ret = -EINVAL;
return ret;
}
static int cumanascsi_2_show_info(struct seq_file *m, struct Scsi_Host *host)
{
struct cumanascsi2_info *info;
info = (struct cumanascsi2_info *)host->hostdata;
seq_printf(m, "Cumana SCSI II driver v%s\n", VERSION);
fas216_print_host(&info->info, m);
seq_printf(m, "Term : o%s\n",
info->terms ? "n" : "ff");
fas216_print_stats(&info->info, m);
fas216_print_devices(&info->info, m);
return 0;
}
static struct scsi_host_template cumanascsi2_template = {
.module = THIS_MODULE,
.show_info = cumanascsi_2_show_info,
.write_info = cumanascsi_2_set_proc_info,
.name = "Cumana SCSI II",
.info = cumanascsi_2_info,
.queuecommand = fas216_queue_command,
.eh_host_reset_handler = fas216_eh_host_reset,
.eh_bus_reset_handler = fas216_eh_bus_reset,
.eh_device_reset_handler = fas216_eh_device_reset,
.eh_abort_handler = fas216_eh_abort,
.can_queue = 1,
.this_id = 7,
.sg_tablesize = SCSI_MAX_SG_CHAIN_SEGMENTS,
.dma_boundary = IOMD_DMA_BOUNDARY,
.cmd_per_lun = 1,
.use_clustering = DISABLE_CLUSTERING,
.proc_name = "cumanascsi2",
};
static int cumanascsi2_probe(struct expansion_card *ec,
const struct ecard_id *id)
{
struct Scsi_Host *host;
struct cumanascsi2_info *info;
void __iomem *base;
int ret;
ret = ecard_request_resources(ec);
if (ret)
goto out;
base = ecardm_iomap(ec, ECARD_RES_MEMC, 0, 0);
if (!base) {
ret = -ENOMEM;
goto out_region;
}
host = scsi_host_alloc(&cumanascsi2_template,
sizeof(struct cumanascsi2_info));
if (!host) {
ret = -ENOMEM;
goto out_region;
}
ecard_set_drvdata(ec, host);
info = (struct cumanascsi2_info *)host->hostdata;
info->ec = ec;
info->base = base;
cumanascsi_2_terminator_ctl(host, term[ec->slot_no]);
info->info.scsi.io_base = base + CUMANASCSI2_FAS216_OFFSET;
info->info.scsi.io_shift = CUMANASCSI2_FAS216_SHIFT;
info->info.scsi.irq = ec->irq;
info->info.scsi.dma = ec->dma;
info->info.ifcfg.clockrate = 40; /* MHz */
info->info.ifcfg.select_timeout = 255;
info->info.ifcfg.asyncperiod = 200; /* ns */
info->info.ifcfg.sync_max_depth = 7;
info->info.ifcfg.cntl3 = CNTL3_BS8 | CNTL3_FASTSCSI | CNTL3_FASTCLK;
info->info.ifcfg.disconnect_ok = 1;
info->info.ifcfg.wide_max_size = 0;
info->info.ifcfg.capabilities = FASCAP_PSEUDODMA;
info->info.dma.setup = cumanascsi_2_dma_setup;
info->info.dma.pseudo = cumanascsi_2_dma_pseudo;
info->info.dma.stop = cumanascsi_2_dma_stop;
ec->irqaddr = info->base + CUMANASCSI2_STATUS;
ec->irqmask = STATUS_INT;
ecard_setirq(ec, &cumanascsi_2_ops, info);
ret = fas216_init(host);
if (ret)
goto out_free;
ret = request_irq(ec->irq, cumanascsi_2_intr,
IRQF_DISABLED, "cumanascsi2", info);
if (ret) {
printk("scsi%d: IRQ%d not free: %d\n",
host->host_no, ec->irq, ret);
goto out_release;
}
if (info->info.scsi.dma != NO_DMA) {
if (request_dma(info->info.scsi.dma, "cumanascsi2")) {
printk("scsi%d: DMA%d not free, using PIO\n",
host->host_no, info->info.scsi.dma);
info->info.scsi.dma = NO_DMA;
} else {
set_dma_speed(info->info.scsi.dma, 180);
info->info.ifcfg.capabilities |= FASCAP_DMA;
}
}
ret = fas216_add(host, &ec->dev);
if (ret == 0)
goto out;
if (info->info.scsi.dma != NO_DMA)
free_dma(info->info.scsi.dma);
free_irq(ec->irq, host);
out_release:
fas216_release(host);
out_free:
scsi_host_put(host);
out_region:
ecard_release_resources(ec);
out:
return ret;
}
static void cumanascsi2_remove(struct expansion_card *ec)
{
struct Scsi_Host *host = ecard_get_drvdata(ec);
struct cumanascsi2_info *info = (struct cumanascsi2_info *)host->hostdata;
ecard_set_drvdata(ec, NULL);
fas216_remove(host);
if (info->info.scsi.dma != NO_DMA)
free_dma(info->info.scsi.dma);
free_irq(ec->irq, info);
fas216_release(host);
scsi_host_put(host);
ecard_release_resources(ec);
}
static const struct ecard_id cumanascsi2_cids[] = {
{ MANU_CUMANA, PROD_CUMANA_SCSI_2 },
{ 0xffff, 0xffff },
};
static struct ecard_driver cumanascsi2_driver = {
.probe = cumanascsi2_probe,
.remove = cumanascsi2_remove,
.id_table = cumanascsi2_cids,
.drv = {
.name = "cumanascsi2",
},
};
static int __init cumanascsi2_init(void)
{
return ecard_register_driver(&cumanascsi2_driver);
}
static void __exit cumanascsi2_exit(void)
{
ecard_remove_driver(&cumanascsi2_driver);
}
module_init(cumanascsi2_init);
module_exit(cumanascsi2_exit);
MODULE_AUTHOR("Russell King");
MODULE_DESCRIPTION("Cumana SCSI-2 driver for Acorn machines");
module_param_array(term, int, NULL, 0);
MODULE_PARM_DESC(term, "SCSI bus termination");
MODULE_LICENSE("GPL");
|
0be845cad0920044f79bbed641f9fcf9257fb67a
|
a1161d9e9d26e0a7b20c31269be145f13d9d3e89
|
/src/peigs/ctof/bortho_f.c
|
68323cc472f3e1ee7b2ec5116c238515e95e62d9
|
[
"LicenseRef-scancode-warranty-disclaimer",
"ECL-2.0",
"LicenseRef-scancode-public-domain"
] |
permissive
|
nwchemgit/nwchem
|
c06e7e1fe11b3afad17b167f29a97c4fa3ad0fda
|
c5a8125298a6ea7d6eb27b07c196ea8041aa7198
|
refs/heads/master
| 2023-09-05T17:18:34.513866
| 2023-09-02T02:56:47
| 2023-09-02T02:56:47
| 111,318,191
| 425
| 164
|
NOASSERTION
| 2023-09-11T16:34:14
| 2017-11-19T17:48:21
|
Fortran
|
UTF-8
|
C
| false
| false
| 4,762
|
c
|
bortho_f.c
|
/*
$Id$
*======================================================================
*
* DISCLAIMER
*
* This material was prepared as an account of work sponsored by an
* agency of the United States Government. Neither the United States
* Government nor the United States Department of Energy, nor Battelle,
* nor any of their employees, MAKES ANY WARRANTY, EXPRESS OR IMPLIED, OR
* ASSUMES ANY LEGAL LIABILITY OR RESPONSIBILITY FOR THE ACCURACY,
* COMPLETENESS, OR USEFULNESS OF ANY INFORMATION, APPARATUS, PRODUCT,
* SOFTWARE, OR PROCESS DISCLOSED, OR REPRESENTS THAT ITS USE WOULD NOT
* INFRINGE PRIVATELY OWNED RIGHTS.
*
* ACKNOWLEDGMENT
*
* This software and its documentation were produced with Government
* support under Contract Number DE-AC06-76RLO-1830 awarded by the United
* States Department of Energy. The Government retains a paid-up
* non-exclusive, irrevocable worldwide license to reproduce, prepare
* derivative works, perform publicly and display publicly by or for the
* Government, including the right to distribute to other Government
* contractors.
*
*======================================================================
*
* -- PEIGS routine (version 2.1) --
* Pacific Northwest Laboratory
* July 28, 1995
*
*======================================================================
*/
#include <stdio.h>
#include <stdlib.h>
#include "globalp.c.h"
void bortho_( n, matB, mapB, m, matZ, mapZ, iwork, work, ort, info)
Integer *n, *mapB, *m, *mapZ, *iwork, *info;
DoublePrecision *matB, *matZ, *work, *ort;
/*
FORTRAN wrapper for b_ortho.
This subroutine computes the infinity-norm measure:
ort = max_i | (Z^t.B.Z)_i - I_i | / ULP,
for the generalized symmetric eigensystem problem where
(lambda, z_i ) is a generalized eigen-pair,
(Z^t.B.Z)_i is the i-th column of Z^t.B.Z
I_i is the i-th column of the m-by-m identity matrix
ULP = (machine precision) * (machine base)
|.| is the infinity-norm.
res is reasonable if it is of order about 50 or less.
MUST have M <= N. If M > N then program exits.
This is not a limitation of this subroutine as M > N
implies the columns of Z are linearly dependent, which
implies "ort" will always be large in this case.
on input:
n = (input) Integer
Dimension of the matrix B, and 1st dimension of the matrix Z.
matB =(input) double precision
colB[i] points to the start of the ith column of B OWNED
by this processor. B is n-by-n symmetric stored in packed
format.
mapB = (input) integer array of length n
mapB[i] is the id of the processor owning column i of B.
m = (input) Integer
2nd dimension of the matrix Z
mapZ = (input) integer array of length m
mapZ[i] is the id of the processor owning column i of Z.
matZ =(input) double precision
colZ[i] points to the start of the ith column of Z OWNED
by this processor.
iwork = (Workspace) Integer array of length
work = (Workspace) DoublePrecision array of length
OUTPUT:
ort = (Output) DoublePrecision
ort as defined in equation above, but only if
info = 0.
info = (Output) Integer
= 0 if this processor is in mapZ
= -1 if this processor is NOT in mapZ, in which case
ort is undefined on exit.
*/
{
Integer i, k, nvecsB, nvecsZ, me;
DoublePrecision *scratch;
DoublePrecision **colZ, **colB, **ibuffptr;
extern Integer mxmynd_();
extern void b_ortho();
me = mxmynd_();
if( *n < *m ) {
fprintf(stderr,
"Error in routine bortho_. m (=%d) < n (=%d). me = %d \n",
*m, *n, me);
exit(-1);
}
/*
* Matrix B is triangular
*/
colB = (DoublePrecision ** ) work;
k = 0;
nvecsB = 0;
for( i = 0; i < *n; i++ ) {
if( mapB[i] == me ) {
nvecsB++;
colB[nvecsB-1] = &matB[k];
k += *n - i;
}
}
/*
* Matrix Z is full
*/
colZ = (DoublePrecision ** ) work + nvecsB + 1;
nvecsZ = -1;
for( i = 0; i < *m; i++ ) {
if( mapZ[i] == me ) {
nvecsZ++;
colZ[nvecsZ] = &matZ[*n * nvecsZ];
}
}
nvecsZ++;
ibuffptr = (DoublePrecision ** ) work + nvecsB + nvecsZ + 2;
scratch = (DoublePrecision * ) work + nvecsB + 4 * nvecsZ + 5;
b_ortho( n, colB, mapB, m, colZ, mapZ, ibuffptr, iwork, scratch, ort, info);
return;
}
|
50fcab803a1ff9f3b479e183839b01adddb3e88c
|
7664f318ed04bd0680f3d82321c18896e3ef6ad5
|
/tools/elf2rom.c
|
907e4e32b48f17155563ec4d7edcd6ffb96da6b9
|
[] |
no_license
|
zeldaret/oot
|
9c80ce17f2d8fd61514b375f92ee4739b5ce9d4e
|
2875ab4fcf5c5f81d76353d1ee0024c9ea8d0b23
|
refs/heads/master
| 2023-08-29T05:29:31.356427
| 2023-08-28T22:48:52
| 2023-08-28T22:48:52
| 247,875,738
| 4,401
| 802
| null | 2023-09-14T13:34:38
| 2020-03-17T04:02:19
|
C
|
UTF-8
|
C
| false
| false
| 7,180
|
c
|
elf2rom.c
|
#include <stdarg.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "elf32.h"
#include "n64chksum.h"
#include "util.h"
#define ROM_SEG_START_SUFFIX ".rom_start"
#define ROM_SEG_END_SUFFIX ".rom_end"
struct RomSegment
{
const char *name;
const void *data;
int size;
int romStart;
int romEnd;
};
static struct RomSegment *g_romSegments = NULL;
static int g_romSegmentsCount = 0;
static int g_romSize;
static bool parse_number(const char *str, int *num)
{
char *endptr;
long int n = strtol(str, &endptr, 0);
*num = n;
return endptr > str;
}
static unsigned int round_up(unsigned int num, unsigned int multiple)
{
num += multiple - 1;
return num / multiple * multiple;
}
static char *sprintf_alloc(const char *fmt, ...)
{
va_list args;
int size;
char *buffer;
va_start(args, fmt);
size = vsnprintf(NULL, 0, fmt, args) + 1;
va_end(args);
buffer = malloc(size);
va_start(args, fmt);
vsprintf(buffer, fmt, args);
va_end(args);
return buffer;
}
static struct RomSegment *add_rom_segment(const char *name)
{
int index = g_romSegmentsCount;
g_romSegmentsCount++;
g_romSegments = realloc(g_romSegments, g_romSegmentsCount * sizeof(*g_romSegments));
g_romSegments[index].name = name;
return &g_romSegments[index];
}
static int find_symbol_value(struct Elf32_Symbol *syms, int numsymbols, const char *name)
{
struct Elf32_Symbol *sym;
int lo, hi, mid, cmp;
// Binary search for the symbol. We maintain the invariant that [lo, hi) is
// the interval that remains to search.
lo = 0;
hi = numsymbols;
while (lo < hi)
{
mid = lo + (hi - lo) / 2;
sym = &syms[mid];
cmp = strcmp(sym->name, name);
if (cmp == 0)
return (int) sym->value;
else if (cmp < 0)
lo = mid + 1;
else
hi = mid;
}
util_fatal_error("Symbol %s is not defined\n", name);
}
static int find_rom_address(struct Elf32_Symbol *syms, int numsymbols, const char *name, const char *suffix)
{
char *symName = sprintf_alloc("_%sSegmentRom%s", name, suffix);
int ret = find_symbol_value(syms, numsymbols, symName);
free(symName);
return ret;
}
static int cmp_symbol_by_name(const void *a, const void *b)
{
return strcmp(
((struct Elf32_Symbol *)a)->name,
((struct Elf32_Symbol *)b)->name);
}
static void parse_input_file(const char *filename)
{
struct Elf32 elf;
struct Elf32_Symbol *syms;
const void *data;
size_t size;
int numRomSymbols;
int i;
data = util_read_whole_file(filename, &size);
if (!elf32_init(&elf, data, size) || elf.machine != ELF_MACHINE_MIPS)
util_fatal_error("%s is not a valid 32-bit MIPS ELF file", filename);
// sort all symbols that contain the substring "Rom" for fast access
// (sorting all symbols costs 0.1s, might as well avoid that)
syms = malloc(elf.numsymbols * sizeof(struct Elf32_Symbol));
numRomSymbols = 0;
for (i = 0; i < elf.numsymbols; i++)
{
if (!elf32_get_symbol(&elf, &syms[numRomSymbols], i))
util_fatal_error("invalid or corrupt ELF file");
if (strstr(syms[numRomSymbols].name, "Rom"))
numRomSymbols++;
}
qsort(syms, numRomSymbols, sizeof(struct Elf32_Symbol), cmp_symbol_by_name);
// get ROM segments
// sections of type SHT_PROGBITS and whose name is ..secname are considered ROM segments
for (i = 0; i < elf.shnum; i++)
{
struct Elf32_Section sec;
struct RomSegment *segment;
if (!elf32_get_section(&elf, &sec, i))
util_fatal_error("invalid or corrupt ELF file");
if (sec.type == SHT_PROGBITS && sec.name[0] == '.' && sec.name[1] == '.'
// HACK! ld sometimes marks NOLOAD sections as SHT_PROGBITS for no apparent reason,
// so we must ignore the ..secname.bss sections explicitly
&& strchr(sec.name + 2, '.') == NULL)
{
segment = add_rom_segment(sec.name + 2);
segment->data = elf.data + sec.offset;
segment->romStart = find_rom_address(syms, numRomSymbols, segment->name, "Start");
segment->romEnd = find_rom_address(syms, numRomSymbols, segment->name, "End");
}
}
g_romSize = find_symbol_value(syms, numRomSymbols, "_RomSize");
free(syms);
}
// Writes the N64 ROM, padding the file size to a multiple of 1 MiB
static void write_rom_file(const char *filename, int cicType)
{
size_t fileSize = round_up(g_romSize, 0x100000);
uint8_t *buffer = calloc(fileSize, 1);
int i;
uint32_t chksum[2];
// write segments
for (i = 0; i < g_romSegmentsCount; i++)
{
int size = g_romSegments[i].romEnd - g_romSegments[i].romStart;
memcpy(buffer + g_romSegments[i].romStart, g_romSegments[i].data, size);
}
// pad the remaining space with 0xFF
memset(buffer + g_romSize, 0xFF, fileSize - g_romSize);
// write checksum
if (!n64chksum_calculate(buffer, cicType, chksum))
util_fatal_error("invalid cic type %i", cicType);
util_write_uint32_be(buffer + 0x10, chksum[0]);
util_write_uint32_be(buffer + 0x14, chksum[1]);
util_write_whole_file(filename, buffer, fileSize);
free(buffer);
}
static void usage(const char *execname)
{
printf("usage: %s -cic <number> input.elf output.z64\n", execname);
}
int main(int argc, char **argv)
{
int i;
const char *inputFileName = NULL;
const char *outputFileName = NULL;
int cicType = -1;
for (i = 1; i < argc; i++)
{
if (argv[i][0] == '-')
{
if (strcmp(argv[i], "-cic") == 0)
{
i++;
if (i >= argc || !parse_number(argv[i], &cicType))
{
fputs("error: expected number after -cic\n", stderr);
goto bad_args;
}
}
else if (strcmp(argv[i], "-help") == 0)
{
usage(argv[0]);
return 0;
}
else
{
fprintf(stderr, "unknown option %s\n", argv[i]);
goto bad_args;
}
}
else
{
if (inputFileName == NULL)
inputFileName = argv[i];
else if (outputFileName == NULL)
outputFileName = argv[i];
else
{
fputs("error: too many parameters specified\n", stderr);
goto bad_args;
}
}
}
if (inputFileName == NULL)
{
fputs("error: no input file specified\n", stderr);
goto bad_args;
}
if (outputFileName == NULL)
{
fputs("error: no output file specified\n", stderr);
goto bad_args;
}
if (cicType == -1)
{
fputs("error: no CIC type specified\n", stderr);
goto bad_args;
}
parse_input_file(inputFileName);
write_rom_file(outputFileName, cicType);
return 0;
bad_args:
usage(argv[0]);
return 1;
}
|
bad6e63d564738df9f904b423b3dc252941cb413
|
8e9d769081965ed4baceae5348680199882a5679
|
/asylo/platform/posix/include/ifaddrs.h
|
9e6a70eb9e7999c53ef5435b0166e9044a8ab3d2
|
[
"Apache-2.0",
"BSD-3-Clause",
"BSD-4-Clause-UC",
"BSD-2-Clause"
] |
permissive
|
google/asylo
|
049b7c3e55417b64d7b3811c2e54ad34c0208fff
|
e73365548454950929d339d37d810a789e5c383b
|
refs/heads/master
| 2023-08-31T14:28:38.211229
| 2022-04-12T19:13:42
| 2022-04-12T20:00:07
| 131,036,436
| 943
| 136
|
Apache-2.0
| 2022-04-12T20:00:08
| 2018-04-25T16:43:56
|
C++
|
UTF-8
|
C
| false
| false
| 1,542
|
h
|
ifaddrs.h
|
/*
*
* Copyright 2018 Asylo authors
*
* 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.
*
*/
#ifndef ASYLO_PLATFORM_POSIX_INCLUDE_IFADDRS_H_
#define ASYLO_PLATFORM_POSIX_INCLUDE_IFADDRS_H_
#include <sys/socket.h>
#ifdef __cplusplus
extern "C" {
#endif
struct ifaddrs {
struct ifaddrs *ifa_next; /* Next item in list */
char *ifa_name; /* Name of interface */
unsigned int ifa_flags; /* Flags from SIOCGIFFLAGS */
struct sockaddr *ifa_addr; /* Address of interface */
struct sockaddr *ifa_netmask; /* Netmask of interface */
union {
struct sockaddr *ifu_broadaddr; /* Broadcast address of interface */
struct sockaddr *ifu_dstaddr; /* Point-to-point destination address */
} ifa_ifu;
#define ifa_broadaddr ifa_ifu.ifu_broadaddr
#define ifa_dstaddr ifa_ifu.ifu_dstaddr
void *ifa_data; /* Address-specific data */
};
int getifaddrs(struct ifaddrs **ifap);
void freeifaddrs(struct ifaddrs *ifa);
#ifdef __cplusplus
}
#endif
#endif // ASYLO_PLATFORM_POSIX_INCLUDE_IFADDRS_H_
|
7d3a1a8b4832dfda6d1c0ae301f7423c34ec372c
|
0744dcc5394cebf57ebcba343747af6871b67017
|
/external/iotivity/iotivity_1.2-rel/resource/csdk/security/provisioning/include/oxm/oxmmanufacturercert.h
|
cff6467b518045d56c8938bb0fe7e0d1e2d9facb
|
[
"Apache-2.0",
"MIT",
"GPL-2.0-only",
"BSD-3-Clause"
] |
permissive
|
Samsung/TizenRT
|
96abf62f1853f61fcf91ff14671a5e0c6ca48fdb
|
1a5c2e00a4b1bbf4c505bbf5cc6a8259e926f686
|
refs/heads/master
| 2023-08-31T08:59:33.327998
| 2023-08-08T06:09:20
| 2023-08-31T04:38:20
| 82,517,252
| 590
| 719
|
Apache-2.0
| 2023-09-14T06:54:49
| 2017-02-20T04:38:30
|
C
|
UTF-8
|
C
| false
| false
| 3,514
|
h
|
oxmmanufacturercert.h
|
//******************************************************************
//
// Copyright 2016 Samsung Electronics All Rights Reserved.
//
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
//
// 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.
//
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
#ifndef _OXM_MANUFACTURER_CERTIFICATE_H_
#define _OXM_MANUFACTURER_CERTIFICATE_H_
#include "ocstack.h"
#include "securevirtualresourcetypes.h"
#include "ownershiptransfermanager.h"
#include "pmtypes.h"
#ifdef __cplusplus
extern "C" {
#endif // __cplusplus
/**
* Callback implementation to prepare manufacturer certificate based OT.
*
* @param otmCtx Context of OTM, It includes current device information.
*
* @return ::OC_STACK_SUCCESS in case of success and other value otherwise.
*/
OCStackResult PrepareMCertificateCallback(OTMContext_t *otmCtx);
/**
* Callback implementation to establish a secure channel with RSA cipher suite.
*
* @param otmCtx Context of OTM, It includes current device information.
*
* @return ::OC_STACK_SUCCESS in case of success and other value otherwise.
*/
OCStackResult CreateSecureSessionMCertificateCallback(OTMContext_t *otmCtx);
/**
* Generate payload for select OxM request.
*
* @param otmCtx Context of OTM, It includes current device information.
* @param cborPayload is the DOXM CBOR payload including the selected OxM.
* @note Returned memory should be deallocated by caller.
* @param cborSize is the size of the cborPayload.
*
* @return ::OC_STACK_SUCCESS in case of success and other value otherwise.
*/
OCStackResult CreateMCertificateBasedSelectOxmPayload(OTMContext_t *otmCtx, uint8_t **cborPayload,
size_t *cborSize);
/**
* Generate payload for select OxM request for confirmed manufactrer certificate method.
*
* @param otmCtx Context of OTM, It includes current device information.
* @param cborPayload is the DOXM CBOR payload including the selected OxM.
* @note Returned memory should be deallocated by caller.
* @param cborSize is the size of the cborPayload.
*
* @return ::OC_STACK_SUCCESS in case of success and other value otherwise.
*/
OCStackResult CreateConMCertificateBasedSelectOxmPayload(OTMContext_t *otmCtx, uint8_t **cborPayload,
size_t *cborSize);
/**
* Generate payload for owner transfer request.
*
* @param otmCtx Context of OTM, It includes current device information.
* @param cborPaylaod is the DOXM CBOR payload including the owner information.
* @note Returned memory should be deallocated by caller.
* @param cborSize is the size of the cborPayload.
*
* @return ::OC_STACK_SUCCESS in case of success and other value otherwise.
*/
OCStackResult CreateMCertificateBasedOwnerTransferPayload(OTMContext_t *otmCtx, uint8_t **cborPayload,
size_t *cborSize);
#ifdef __cplusplus
}
#endif
#endif //_OXM_MANUFACTURER_CERTIFICATE_H_
|
8b793f58cd58db949b6c851d644d464ed0bd77b4
|
7eaf54a78c9e2117247cb2ab6d3a0c20719ba700
|
/SOFTWARE/A64-TERES/linux-a64/arch/arm/mach-omap2/cm44xx.c
|
535d66e2822c26ebe37f2fcaf509d678bb9570b4
|
[
"LicenseRef-scancode-free-unknown",
"Apache-2.0",
"Linux-syscall-note",
"GPL-2.0-only",
"GPL-1.0-or-later"
] |
permissive
|
OLIMEX/DIY-LAPTOP
|
ae82f4ee79c641d9aee444db9a75f3f6709afa92
|
a3fafd1309135650bab27f5eafc0c32bc3ca74ee
|
refs/heads/rel3
| 2023-08-04T01:54:19.483792
| 2023-04-03T07:18:12
| 2023-04-03T07:18:12
| 80,094,055
| 507
| 92
|
Apache-2.0
| 2023-04-03T07:05:59
| 2017-01-26T07:25:50
|
C
|
UTF-8
|
C
| false
| false
| 1,317
|
c
|
cm44xx.c
|
/*
* OMAP4 CM1, CM2 module low-level functions
*
* Copyright (C) 2010 Nokia Corporation
* Paul Walmsley
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* These functions are intended to be used only by the cminst44xx.c file.
* XXX Perhaps we should just move them there and make them static.
*/
#include <linux/kernel.h>
#include <linux/types.h>
#include <linux/errno.h>
#include <linux/err.h>
#include <linux/io.h>
#include "iomap.h"
#include "common.h"
#include "cm.h"
#include "cm1_44xx.h"
#include "cm2_44xx.h"
#include "cm-regbits-44xx.h"
/* CM1 hardware module low-level functions */
/* Read a register in CM1 */
u32 omap4_cm1_read_inst_reg(s16 inst, u16 reg)
{
return __raw_readl(OMAP44XX_CM1_REGADDR(inst, reg));
}
/* Write into a register in CM1 */
void omap4_cm1_write_inst_reg(u32 val, s16 inst, u16 reg)
{
__raw_writel(val, OMAP44XX_CM1_REGADDR(inst, reg));
}
/* Read a register in CM2 */
u32 omap4_cm2_read_inst_reg(s16 inst, u16 reg)
{
return __raw_readl(OMAP44XX_CM2_REGADDR(inst, reg));
}
/* Write into a register in CM2 */
void omap4_cm2_write_inst_reg(u32 val, s16 inst, u16 reg)
{
__raw_writel(val, OMAP44XX_CM2_REGADDR(inst, reg));
}
|
bc2dd8c48a2aec12736464c54393ecd1b26c6584
|
31474cf76ce4e4d6cc4aef1947cd7690eb24f234
|
/external/libcheevos/libretro-common/src/string/stdstring.c
|
4b36deb77fa708f367abc8e284bb3514b2806cc9
|
[
"MIT",
"Apache-2.0",
"LicenseRef-scancode-ubuntu-font-1.0"
] |
permissive
|
batocera-linux/batocera-emulationstation
|
fb83c3279477a79f9d5bfa744665bae0dac9c96f
|
cec8b875c4ceb813402731f2732f1bc902f869d0
|
refs/heads/master
| 2023-08-31T08:31:54.095596
| 2023-08-31T06:11:42
| 2023-08-31T06:11:42
| 108,592,510
| 251
| 240
|
MIT
| 2023-09-13T19:41:31
| 2017-10-27T20:26:05
|
C++
|
UTF-8
|
C
| false
| false
| 21,094
|
c
|
stdstring.c
|
/* Copyright (C) 2010-2020 The RetroArch team
*
* ---------------------------------------------------------------------------------------
* The following license statement only applies to this file (stdstring.c).
* ---------------------------------------------------------------------------------------
*
* 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.
*/
#include <stdint.h>
#include <ctype.h>
#include <string.h>
#include <compat/strl.h>
#include <string/stdstring.h>
#include <encodings/utf.h>
const uint8_t lr_char_props[256] = {
/*x0 x1 x2 x3 x4 x5 x6 x7 x8 x9 xA xB xC xD xE xF */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x00,0x00,0x80,0x00,0x00, /* 0x */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 1x */
0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 2x !"#$%&'()*+,-./ */
0x41,0x41,0x41,0x41,0x41,0x41,0x41,0x41,0x41,0x41,0x00,0x00,0x00,0x00,0x00,0x00, /* 3x 0123456789:;<=>? */
0x00,0x23,0x23,0x23,0x23,0x23,0x23,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22, /* 4x @ABCDEFGHIJKLMNO */
0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x22,0x00,0x00,0x00,0x00,0x08, /* 5x PQRSTUVWXYZ[\]^_ */
0x00,0x25,0x25,0x25,0x25,0x25,0x25,0x24,0x24,0x24,0x24,0x24,0x24,0x24,0x24,0x24, /* 6x `abcdefghijklmno */
0x24,0x24,0x24,0x24,0x24,0x24,0x24,0x24,0x24,0x24,0x24,0x00,0x00,0x00,0x00,0x00, /* 7x pqrstuvwxyz{|}~ */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 8x */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 9x */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* Ax */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* Bx */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* Cx */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* Dx */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* Ex */
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* Fx */
};
char *string_init(const char *src)
{
return src ? strdup(src) : NULL;
}
void string_set(char **string, const char *src)
{
free(*string);
*string = string_init(src);
}
char *string_to_upper(char *s)
{
char *cs = (char *)s;
for ( ; *cs != '\0'; cs++)
*cs = toupper((unsigned char)*cs);
return s;
}
char *string_to_lower(char *s)
{
char *cs = (char *)s;
for ( ; *cs != '\0'; cs++)
*cs = tolower((unsigned char)*cs);
return s;
}
char *string_ucwords(char *s)
{
char *cs = (char *)s;
for ( ; *cs != '\0'; cs++)
{
if (*cs == ' ')
*(cs+1) = toupper((unsigned char)*(cs+1));
}
s[0] = toupper((unsigned char)s[0]);
return s;
}
char *string_replace_substring(const char *in,
const char *pattern, size_t pattern_len,
const char *replacement, size_t replacement_len)
{
size_t outlen;
size_t numhits = 0;
const char *inat = NULL;
const char *inprev = NULL;
char *out = NULL;
char *outat = NULL;
/* if either pattern or replacement is NULL,
* duplicate in and let caller handle it. */
if (!pattern || !replacement)
return strdup(in);
inat = in;
while ((inat = strstr(inat, pattern)))
{
inat += pattern_len;
numhits++;
}
outlen = strlen(in) - pattern_len*numhits + replacement_len*numhits;
if (!(out = (char *)malloc(outlen+1)))
return NULL;
outat = out;
inat = in;
inprev = in;
while ((inat = strstr(inat, pattern)))
{
memcpy(outat, inprev, inat-inprev);
outat += inat-inprev;
memcpy(outat, replacement, replacement_len);
outat += replacement_len;
inat += pattern_len;
inprev = inat;
}
strcpy(outat, inprev);
return out;
}
/**
* string_trim_whitespace_left:
*
* Remove leading whitespaces
**/
char *string_trim_whitespace_left(char *const s)
{
if (s && *s)
{
size_t len = strlen(s);
char *current = s;
while (*current && ISSPACE((unsigned char)*current))
{
++current;
--len;
}
if (s != current)
memmove(s, current, len + 1);
}
return s;
}
/**
* string_trim_whitespace_right:
*
* Remove trailing whitespaces
**/
char *string_trim_whitespace_right(char *const s)
{
if (s && *s)
{
size_t len = strlen(s);
char *current = s + len - 1;
while (current != s && ISSPACE((unsigned char)*current))
{
--current;
--len;
}
current[ISSPACE((unsigned char)*current) ? 0 : 1] = '\0';
}
return s;
}
/**
* string_trim_whitespace:
*
* Remove leading and trailing whitespaces
**/
char *string_trim_whitespace(char *const s)
{
string_trim_whitespace_right(s); /* order matters */
string_trim_whitespace_left(s);
return s;
}
/**
* word_wrap:
* @dst : pointer to destination buffer.
* @dst_size : size of destination buffer.
* @src : pointer to input string.
* @line_width : max number of characters per line.
* @wideglyph_width : not used, but is necessary to keep
* compatibility with word_wrap_wideglyph().
* @max_lines : max lines of destination string.
* 0 means no limit.
*
* Wraps string specified by 'src' to destination buffer
* specified by 'dst' and 'dst_size'.
* This function assumes that all glyphs in the string
* have an on-screen pixel width similar to that of
* regular Latin characters - i.e. it will not wrap
* correctly any text containing so-called 'wide' Unicode
* characters (e.g. CJK languages, emojis, etc.).
**/
void word_wrap(
char *dst, size_t dst_size,
const char *src, size_t src_len,
int line_width, int wideglyph_width, unsigned max_lines)
{
char *lastspace = NULL;
unsigned counter = 0;
unsigned lines = 1;
const char *src_end = src + src_len;
/* Prevent buffer overflow */
if (dst_size < src_len + 1)
return;
/* Early return if src string length is less
* than line width */
if (src_len < (size_t)line_width)
{
strlcpy(dst, src, dst_size);
return;
}
while (*src != '\0')
{
unsigned char_len = (unsigned)(utf8skip(src, 1) - src);
counter++;
if (*src == ' ')
lastspace = dst; /* Remember the location of the whitespace */
else if (*src == '\n')
{
/* If newlines embedded in the input,
* reset the index */
lines++;
counter = 0;
/* Early return if remaining src string
* length is less than line width */
if (src_end - src <= line_width)
{
strlcpy(dst, src, dst_size);
return;
}
}
while (char_len--)
*dst++ = *src++;
if (counter >= (unsigned)line_width)
{
counter = 0;
if (lastspace && (max_lines == 0 || lines < max_lines))
{
/* Replace nearest (previous) whitespace
* with newline character */
*lastspace = '\n';
lines++;
src -= dst - lastspace - 1;
dst = lastspace + 1;
lastspace = NULL;
/* Early return if remaining src string
* length is less than line width */
if (src_end - src < line_width)
{
strlcpy(dst, src, dst_size);
return;
}
}
}
}
*dst = '\0';
}
/**
* word_wrap_wideglyph:
* @dst : pointer to destination buffer.
* @dst_size : size of destination buffer.
* @src : pointer to input string.
* @line_width : max number of characters per line.
* @wideglyph_width : effective width of 'wide' Unicode glyphs.
* the value here is normalised relative to the
* typical on-screen pixel width of a regular
* Latin character:
* - a regular Latin character is defined to
* have an effective width of 100
* - wideglyph_width = 100 * (wide_character_pixel_width / latin_character_pixel_width)
* - e.g. if 'wide' Unicode characters in 'src'
* have an on-screen pixel width twice that of
* regular Latin characters, wideglyph_width
* would be 200
* @max_lines : max lines of destination string.
* 0 means no limit.
*
* Wraps string specified by @src to destination buffer
* specified by @dst and @dst_size.
* This function assumes that all glyphs in the string
* are:
* - EITHER 'non-wide' Unicode glyphs, with an on-screen
* pixel width similar to that of regular Latin characters
* - OR 'wide' Unicode glyphs (e.g. CJK languages, emojis, etc.)
* with an on-screen pixel width defined by @wideglyph_width
* Note that wrapping may occur in inappropriate locations
* if @src string contains 'wide' Unicode characters whose
* on-screen pixel width deviates greatly from the set
* @wideglyph_width value.
**/
void word_wrap_wideglyph(char *dst, size_t dst_size,
const char *src, size_t src_len, int line_width,
int wideglyph_width, unsigned max_lines)
{
char *lastspace = NULL;
char *lastwideglyph = NULL;
const char *src_end = src + src_len;
unsigned lines = 1;
/* 'line_width' means max numbers of characters per line,
* but this metric is only meaningful when dealing with
* 'regular' glyphs that have an on-screen pixel width
* similar to that of regular Latin characters.
* When handing so-called 'wide' Unicode glyphs, it is
* necessary to consider the actual on-screen pixel width
* of each character.
* In order to do this, we create a distinction between
* regular Latin 'non-wide' glyphs and 'wide' glyphs, and
* normalise all values relative to the on-screen pixel
* width of regular Latin characters:
* - Regular 'non-wide' glyphs have a normalised width of 100
* - 'line_width' is therefore normalised to 100 * (width_in_characters)
* - 'wide' glyphs have a normalised width of
* 100 * (wide_character_pixel_width / latin_character_pixel_width)
* - When a character is detected, the position in the current
* line is incremented by the regular normalised width of 100
* - If that character is then determined to be a 'wide'
* glyph, the position in the current line is further incremented
* by the difference between the normalised 'wide' and 'non-wide'
* width values */
unsigned counter_normalized = 0;
int line_width_normalized = line_width * 100;
int additional_counter_normalized = wideglyph_width - 100;
/* Early return if src string length is less
* than line width */
if (src_end - src < line_width)
{
strlcpy(dst, src, dst_size);
return;
}
while (*src != '\0')
{
unsigned char_len = (unsigned)(utf8skip(src, 1) - src);
counter_normalized += 100;
/* Prevent buffer overflow */
if (char_len >= dst_size)
break;
if (*src == ' ')
lastspace = dst; /* Remember the location of the whitespace */
else if (*src == '\n')
{
/* If newlines embedded in the input,
* reset the index */
lines++;
counter_normalized = 0;
/* Early return if remaining src string
* length is less than line width */
if (src_end - src <= line_width)
{
strlcpy(dst, src, dst_size);
return;
}
}
else if (char_len >= 3)
{
/* Remember the location of the first byte
* whose length as UTF-8 >= 3*/
lastwideglyph = dst;
counter_normalized += additional_counter_normalized;
}
dst_size -= char_len;
while (char_len--)
*dst++ = *src++;
if (counter_normalized >= (unsigned)line_width_normalized)
{
counter_normalized = 0;
if (max_lines != 0 && lines >= max_lines)
continue;
else if (lastwideglyph && (!lastspace || lastwideglyph > lastspace))
{
/* Insert newline character */
*lastwideglyph = '\n';
lines++;
src -= dst - lastwideglyph;
dst = lastwideglyph + 1;
lastwideglyph = NULL;
/* Early return if remaining src string
* length is less than line width */
if (src_end - src <= line_width)
{
strlcpy(dst, src, dst_size);
return;
}
}
else if (lastspace)
{
/* Replace nearest (previous) whitespace
* with newline character */
*lastspace = '\n';
lines++;
src -= dst - lastspace - 1;
dst = lastspace + 1;
lastspace = NULL;
/* Early return if remaining src string
* length is less than line width */
if (src_end - src < line_width)
{
strlcpy(dst, src, dst_size);
return;
}
}
}
}
*dst = '\0';
}
/**
* string_tokenize:
*
* Splits string into tokens seperated by @delim
* > Returned token string must be free()'d
* > Returns NULL if token is not found
* > After each call, @str is set to the position after the
* last found token
* > Tokens *include* empty strings
* Usage example:
* char *str = "1,2,3,4,5,6,7,,,10,";
* char **str_ptr = &str;
* char *token = NULL;
* while ((token = string_tokenize(str_ptr, ",")))
* {
* printf("%s\n", token);
* free(token);
* token = NULL;
* }
**/
char* string_tokenize(char **str, const char *delim)
{
/* Taken from https://codereview.stackexchange.com/questions/216956/strtok-function-thread-safe-supports-empty-tokens-doesnt-change-string# */
char *str_ptr = NULL;
char *delim_ptr = NULL;
char *token = NULL;
size_t token_len = 0;
/* Sanity checks */
if (!str || string_is_empty(delim))
return NULL;
/* Note: we don't check string_is_empty() here,
* empty strings are valid */
if (!(str_ptr = *str))
return NULL;
/* Search for delimiter */
if ((delim_ptr = strstr(str_ptr, delim)))
token_len = delim_ptr - str_ptr;
else
token_len = strlen(str_ptr);
/* Allocate token string */
if (!(token = (char *)malloc((token_len + 1) * sizeof(char))))
return NULL;
/* Copy token */
strlcpy(token, str_ptr, (token_len + 1) * sizeof(char));
token[token_len] = '\0';
/* Update input string pointer */
*str = delim_ptr ? delim_ptr + strlen(delim) : NULL;
return token;
}
/**
* string_remove_all_chars:
* @str : input string (must be non-NULL, otherwise UB)
*
* Leaf function.
*
* Removes every instance of character @c from @str
**/
void string_remove_all_chars(char *str, char c)
{
char *read_ptr = str;
char *write_ptr = str;
while (*read_ptr != '\0')
{
*write_ptr = *read_ptr++;
if (*write_ptr != c)
write_ptr++;
}
*write_ptr = '\0';
}
/**
* string_replace_all_chars:
* @str : input string (must be non-NULL, otherwise UB)
* @find : character to find
* @replace : character to replace @find with
*
* Replaces every instance of character @find in @str
* with character @replace
**/
void string_replace_all_chars(char *str, char find, char replace)
{
char *str_ptr = str;
while ((str_ptr = strchr(str_ptr, find)))
*str_ptr++ = replace;
}
/**
* string_to_unsigned:
* @str : input string
*
* Converts string to unsigned integer.
*
* @return 0 if string is invalid, otherwise > 0
**/
unsigned string_to_unsigned(const char *str)
{
const char *ptr = NULL;
if (string_is_empty(str))
return 0;
for (ptr = str; *ptr != '\0'; ptr++)
{
if (!ISDIGIT((unsigned char)*ptr))
return 0;
}
return (unsigned)strtoul(str, NULL, 10);
}
/**
* string_hex_to_unsigned:
* @str : input string (must be non-NULL, otherwise UB)
*
* Converts hexadecimal string to unsigned integer.
* Handles optional leading '0x'.
*
* @return 0 if string is invalid, otherwise > 0
**/
unsigned string_hex_to_unsigned(const char *str)
{
const char *hex_str = str;
const char *ptr = NULL;
/* Remove leading '0x', if required */
if (str[0] != '\0' && str[1] != '\0')
{
if ( (str[0] == '0') &&
((str[1] == 'x') ||
(str[1] == 'X')))
{
hex_str = str + 2;
if (string_is_empty(hex_str))
return 0;
}
}
else
return 0;
/* Check for valid characters */
for (ptr = hex_str; *ptr != '\0'; ptr++)
{
if (!isxdigit((unsigned char)*ptr))
return 0;
}
return (unsigned)strtoul(hex_str, NULL, 16);
}
/**
* string_count_occurrences_single_character:
*
* Leaf function.
*
* Get the total number of occurrences of character @c in @str.
*
* @return Total number of occurrences of character @c
*/
int string_count_occurrences_single_character(const char *str, char c)
{
int count = 0;
for (; *str; str++)
if (*str == c)
count++;
return count;
}
/**
* string_replace_whitespace_with_single_character:
*
* Leaf function.
*
* Replaces all spaces with given character @c.
**/
void string_replace_whitespace_with_single_character(char *str, char c)
{
for (; *str; str++)
if (ISSPACE(*str))
*str = c;
}
/**
* string_replace_multi_space_with_single_space:
*
* Leaf function.
*
* Replaces multiple spaces with a single space in a string.
**/
void string_replace_multi_space_with_single_space(char *str)
{
char *str_trimmed = str;
bool prev_is_space = false;
bool curr_is_space = false;
for (; *str; str++)
{
curr_is_space = ISSPACE(*str);
if (prev_is_space && curr_is_space)
continue;
*str_trimmed++ = *str;
prev_is_space = curr_is_space;
}
*str_trimmed = '\0';
}
/**
* string_remove_all_whitespace:
*
* Leaf function.
*
* Remove all spaces from the given string.
**/
void string_remove_all_whitespace(char *str_trimmed, const char *str)
{
for (; *str; str++)
if (!ISSPACE(*str))
*str_trimmed++ = *str;
*str_trimmed = '\0';
}
/**
* Retrieve the last occurance of the given character in a string.
*/
int string_index_last_occurance(const char *str, char c)
{
const char *pos = strrchr(str, c);
if (pos)
return (int)(pos - str);
return -1;
}
/**
* string_find_index_substring_string:
* @str : input string (must be non-NULL, otherwise UB)
* @substr : substring to find in @str
*
* Find the position of substring @substr in string @str.
**/
int string_find_index_substring_string(const char *str, const char *substr)
{
const char *pos = strstr(str, substr);
if (pos)
return (int)(pos - str);
return -1;
}
/**
* string_copy_only_ascii:
*
* Leaf function.
*
* Strips non-ASCII characters from a string.
**/
void string_copy_only_ascii(char *str_stripped, const char *str)
{
for (; *str; str++)
if (*str > 0x1F && *str < 0x7F)
*str_stripped++ = *str;
*str_stripped = '\0';
}
|
07b42c039031dad70a91d0f1ebd2fb154c703417
|
9ceacf33fd96913cac7ef15492c126d96cae6911
|
/regress/lib/libradius/test04.c
|
d868a22640457bf31e43bc69f1db542c849aa2aa
|
[] |
no_license
|
openbsd/src
|
ab97ef834fd2d5a7f6729814665e9782b586c130
|
9e79f3a0ebd11a25b4bff61e900cb6de9e7795e9
|
refs/heads/master
| 2023-09-02T18:54:56.624627
| 2023-09-02T15:16:12
| 2023-09-02T15:16:12
| 66,966,208
| 3,394
| 1,235
| null | 2023-08-08T02:42:25
| 2016-08-30T18:18:25
|
C
|
UTF-8
|
C
| false
| false
| 2,207
|
c
|
test04.c
|
#include "incs.h"
/*
* put/get cat attributes
*/
void test04(void)
{
RADIUS_PACKET *packet;
uint8_t buf[1024];
size_t len;
uint8_t *p;
#define ATTRLEN (256 + 256 + 103)
uint8_t data0[ATTRLEN];
uint8_t data1[ATTRLEN];
uint8_t data2[] = { 0x10, 0x20, 0x30, 0x40 };
uint8_t data3[] = { 0x10, 0x20, 0x30, 0x40, 0x10, 0x20, 0x30, 0x40 };
uint8_t attrs[2048];
packet = radius_new_request_packet(RADIUS_CODE_ACCESS_REQUEST);
for (int i = 0; i < ATTRLEN; i++)
data0[i] = random();
for (int i = 0; i < ATTRLEN; i++)
data1[i] = random();
p = attrs;
*p++ = 20; *p++ = 6;
memcpy(p, data2, 4); p += 4;
*p++ = 10; *p++ = 255;
memcpy(p, data0, 253); p += 253;
*p++ = 10; *p++ = 255;
memcpy(p, data0 + 253, 253); p += 253;
*p++ = 10; *p++ = ATTRLEN-253*2+2;
memcpy(p, data0 + 253*2, ATTRLEN-253*2); p += ATTRLEN-253*2;
*p++ = RADIUS_TYPE_VENDOR_SPECIFIC; *p++ = 255;
*p++ = 0; *p++ = 0; *p++ = 0; *p++ = 20; *p++ = 30; *p++ = 249;
memcpy(p, data1, 247); p += 247;
*p++ = RADIUS_TYPE_VENDOR_SPECIFIC; *p++ = 255;
*p++ = 0; *p++ = 0; *p++ = 0; *p++ = 20; *p++ = 30; *p++ = 249;
memcpy(p, data1 + 247, 247); p += 247;
*p++ = RADIUS_TYPE_VENDOR_SPECIFIC; *p++ = ATTRLEN-247*2+8;
*p++ = 0; *p++ = 0; *p++ = 0; *p++ = 20; *p++ = 30; *p++ = ATTRLEN-247*2+2;
memcpy(p, data1 + 247*2, ATTRLEN-247*2); p += ATTRLEN-247*2;
*p++ = 20; *p++ = 6;
memcpy(p, data2, 4); p += 4;
radius_put_raw_attr(packet, 20, data2, sizeof(data2));
radius_put_raw_attr_cat(packet, 10, data0, ATTRLEN);
radius_put_vs_raw_attr_cat(packet, 20, 30, data1, ATTRLEN);
radius_put_raw_attr(packet, 20, data2, sizeof(data2));
CHECK(radius_get_length(packet) == 20 + (p-attrs));
CHECK(memcmp(radius_get_data(packet) + 20, attrs, p-attrs) == 0);
len = sizeof(buf);
CHECK(radius_get_raw_attr_cat(packet, 10, buf, &len) == 0);
CHECK(len == ATTRLEN);
CHECK(memcmp(buf, data0, len) == 0);
len = sizeof(buf);
CHECK(radius_get_vs_raw_attr_cat(packet, 20, 30, buf, &len) == 0);
CHECK(len == ATTRLEN);
CHECK(memcmp(buf, data1, len) == 0);
len = sizeof(buf);
CHECK(radius_get_raw_attr_cat(packet, 20,buf, &len) == 0);
CHECK(len == sizeof(data3));
CHECK(memcmp(buf, data3, len) == 0);
}
ADD_TEST(test04)
|
02094a9e5662967f90d956941b604fe146d21e30
|
c72e8e7a91acfc92d6cbd02dfbbcc20f00aab63f
|
/src/common/io/http/common.h
|
a928751177edaa3162b5c9bbf714c55b8a1cf6f9
|
[
"MIT"
] |
permissive
|
pgbackrest/pgbackrest
|
83b3760b0faaaf7a0da4a54caeaa2231d6144704
|
e3fcd8cd9e0be42a32fc4cbd2ae3db2c072eabcd
|
refs/heads/main
| 2023-09-03T22:27:01.317021
| 2023-08-31T20:36:52
| 2023-08-31T20:36:52
| 14,313,288
| 1,826
| 211
|
NOASSERTION
| 2023-09-14T13:56:30
| 2013-11-11T21:08:39
|
C
|
UTF-8
|
C
| false
| false
| 1,121
|
h
|
common.h
|
/***********************************************************************************************************************************
HTTP Common
***********************************************************************************************************************************/
#ifndef COMMON_IO_HTTP_COMMON_H
#define COMMON_IO_HTTP_COMMON_H
#include <time.h>
#include "common/type/string.h"
/***********************************************************************************************************************************
Functions
***********************************************************************************************************************************/
// Convert HTTP date to time_t and vice versa
FN_EXTERN time_t httpDateToTime(const String *lastModified);
FN_EXTERN String *httpDateFromTime(time_t time);
// Encode string to conform with URI specifications. If a path is being encoded then / characters won't be encoded.
FN_EXTERN String *httpUriEncode(const String *uri, bool path);
// Decode string that conforms to URI specifications
FN_EXTERN String *httpUriDecode(const String *uri);
#endif
|
2ca43374c297cd71521e94e03f374ef9b660c483
|
78014f186b458c0dfbd4dd4dc660adfe858d4c62
|
/src/jc.c
|
544d36759921796222655a6519dbdba7790e6544
|
[] |
no_license
|
r-spatial/spdep
|
a1a8cebe6c86724bc4431afefc2ba2f06a3eb60c
|
a02d7aa6be8a42e62ba37d2999a35aff06a0ea59
|
refs/heads/main
| 2023-08-21T19:27:09.562669
| 2023-08-07T12:08:51
| 2023-08-07T12:08:51
| 109,153,369
| 109
| 30
| null | 2022-12-10T12:31:36
| 2017-11-01T16:10:35
|
R
|
UTF-8
|
C
| false
| false
| 691
|
c
|
jc.c
|
/* Copyright 2003 by Roger S. Bivand. */
#include "spdep.h"
SEXP jcintern(SEXP nb, SEXP weights, SEXP dum, SEXP card) {
int i, j, k, n=length(card), pc=0;
double sum, sum1, wt;
SEXP ans;
PROTECT(ans = NEW_NUMERIC(1)); pc++;
sum1 = 0.0;
for (i=0; i < n; i++) {
sum = 0.0;
if (INTEGER_POINTER(card)[i] > 0) {
for (j=0; j<INTEGER_POINTER(card)[i]; j++) {
k = INTEGER_POINTER(VECTOR_ELT(nb, i))[j];
wt = NUMERIC_POINTER(VECTOR_ELT(weights, i))[j];
sum += ((double) INTEGER_POINTER(dum)[k-ROFFSET]) * wt;
}
sum1 += ((double) INTEGER_POINTER(dum)[i]) * sum;
}
}
NUMERIC_POINTER(ans)[0] = sum1;
UNPROTECT(pc); /* ans */
return(ans);
}
|
e7e8cb92360bccbea2dc44146bc318a693336daf
|
154cf7c3c956dbb270c2113ec63cfd4695185e95
|
/filters_common.inc.h
|
abeb0fefee4154971feea8e4413ede9c1238c0c8
|
[
"CC0-1.0",
"LicenseRef-scancode-public-domain",
"LicenseRef-scancode-public-domain-disclaimer"
] |
permissive
|
cathugger/mkp224o
|
4826846a252cc555a1bd2ddc4fa14336f0db8016
|
42e4d3a5fcea3a7d5072e9b354265e2ced18367b
|
refs/heads/master
| 2023-08-24T23:55:39.736945
| 2023-08-06T18:22:54
| 2023-08-06T18:22:54
| 104,667,971
| 1,000
| 153
|
CC0-1.0
| 2023-08-06T18:22:55
| 2017-09-24T18:49:18
|
C
|
UTF-8
|
C
| false
| false
| 886
|
h
|
filters_common.inc.h
|
#ifdef INTFILTER
static inline size_t S(filter_len)(size_t i)
{
# ifndef OMITMASK
const u8 *m = (const u8 *)&VEC_BUF(filters,i).m;
# else // OMITMASK
(void) i;
const u8 *m = (const u8 *)&ifiltermask;
# endif // OMITMASK
size_t c = 0;
for (size_t j = 0;;) {
u8 v = m[j];
for (size_t k = 0;;) {
if (!v)
return c;
++c;
if (++k >= 8)
break;
v <<= 1;
}
if (++j >= sizeof(IFT))
break;
}
return c;
}
#define filter_len S(filter_len)
#endif // INTFILTER
#ifdef BINFILTER
static inline size_t S(filter_len)(size_t i)
{
size_t c = VEC_BUF(filters,i).len * 8;
u8 v = VEC_BUF(filters,i).mask;
for (size_t k = 0;;) {
if (!v)
return c;
++c;
if (++k >= 8)
return c;
v <<= 1;
}
}
#define filter_len S(filter_len)
#endif // BINFILTER
#ifdef PCRE2FILTER
#define filter_len(i) ((pcre2ovector[1] - pcre2ovector[0]) * 5)
#endif // PCRE2FILTER
|
fc08c559a7d0a6cc87081cd9ac7a4f3b8085463d
|
376e1818d427b5e4d32fa6dd6c7b71e9fd88afdb
|
/math/xfractint/patches/patch-common_frasetup.c
|
1e23ad73b517bf7b52f667e56e347c7ece5d71d5
|
[] |
no_license
|
NetBSD/pkgsrc
|
a0732c023519650ef821ab89c23ab6ab59e25bdb
|
d042034ec4896cc5b47ed6f2e5b8802d9bc5c556
|
refs/heads/trunk
| 2023-09-01T07:40:12.138283
| 2023-09-01T05:25:19
| 2023-09-01T05:25:19
| 88,439,572
| 321
| 138
| null | 2023-07-12T22:34:14
| 2017-04-16T20:04:15
| null |
UTF-8
|
C
| false
| false
| 501
|
c
|
patch-common_frasetup.c
|
$NetBSD: patch-common_frasetup.c,v 1.1 2018/08/28 11:54:54 schmonz Exp $
--- common/frasetup.c.orig 2014-05-03 13:12:35.000000000 +0000
+++ common/frasetup.c
@@ -1,12 +1,6 @@
#include <limits.h>
#include <string.h>
-#ifdef __TURBOC__
-#include <alloc.h>
-#elif defined(__APPLE__)
-#include <malloc/malloc.h>
-#elif !defined(__386BSD__)
-#include <malloc.h>
-#endif
+#include <stdlib.h>
/* see Fractint.c for a description of the "include" hierarchy */
#include "port.h"
#include "prototyp.h"
|
977bd8f7e142fedc1a0a179f47f9363fc05a5ccc
|
6a78f00818827dbcaa42628e556c50e34558138c
|
/tar/ccache/ccache_internal.h
|
43075970892a4b39c7334563ebd3e5ce121960e7
|
[
"LicenseRef-scancode-warranty-disclaimer"
] |
no_license
|
Tarsnap/tarsnap
|
54abaa9ce37e8cad088eb37f3609eaa37d947323
|
00c9231e784c25d519b679668707e8ce644003cb
|
refs/heads/master
| 2023-09-03T01:25:06.886320
| 2023-08-26T18:52:09
| 2023-08-26T18:52:09
| 35,801,306
| 905
| 80
|
NOASSERTION
| 2023-08-29T18:55:34
| 2015-05-18T06:44:50
|
C
|
UTF-8
|
C
| false
| false
| 1,989
|
h
|
ccache_internal.h
|
#ifndef CCACHE_INTERNAL_H_
#define CCACHE_INTERNAL_H_
#include <sys/stat.h>
#include <stdint.h>
#include "ccache.h"
#include "ctassert.h"
#include "multitape.h"
#include "patricia.h"
/*
* Maximum number of times tarsnap can be run without accessing a cache
* entry before the entry is removed from the cache.
*/
#define MAXAGE 10
/* Cache data structure. */
struct ccache_internal {
PATRICIA * tree; /* Tree of ccache_record structures. */
void * data; /* Mmapped data. */
size_t datalen; /* Size of mmapped data. */
size_t chunksusage; /* Memory used by chunks. */
size_t trailerusage; /* Memory used by trailers. */
};
/* An entry stored in the cache. */
struct ccache_record {
/* Values stored in ccache_record_external structure. */
ino_t ino; /* Inode number. */
off_t size; /* File size. */
time_t mtime; /* Modification time, seconds since epoch. */
size_t nch; /* Number of struct chunkheader records. */
size_t tlen; /* Length of trailer (unchunked data). */
size_t tzlen; /* Length of deflated trailer. */
int age; /* Age of entry in read/write cycles. */
size_t nchalloc; /* Number of records of space allocated. */
struct chunkheader * chp; /* Points to nch records if non-NULL. */
uint8_t * ztrailer; /* Points to deflated trailer if non-NULL. */
int flags; /* CCR_* flags. */
};
#define CCR_ZTRAILER_MALLOC 1
/* On-disk data structure. Integers are little-endian. */
struct ccache_record_external {
uint8_t ino[8];
uint8_t size[8];
uint8_t mtime[8];
uint8_t nch[8];
uint8_t tlen[4];
uint8_t tzlen[4];
uint8_t prefixlen[4];
uint8_t suffixlen[4];
uint8_t age[4];
/* Immediately following each record is suffix[]. */
};
/**
* After all of the ccache_record_external and suffix[] pairs, the
* struct chunkheader chp[] and uint8_t ztrailer[] data is stored in the
* same order.
*/
/* Make sure the compiler isn't padding inappropriately. */
CTASSERT(sizeof(struct ccache_record_external) == 52);
#endif /* !CCACHE_INTERNAL_H_ */
|
ff57d39f2c7423bff8cff77de7b5005c0994e61a
|
ae3e9369882d46a2a009c41a58449c3da9cb3ae1
|
/src/enclave/enclave_signal.c
|
009a545f71c5f066f049539f1ff21fa1822fff96
|
[
"MIT"
] |
permissive
|
lsds/sgx-lkl
|
efc1f9bc0b9621ff1d301abf0b5bbbcc7c80ef96
|
b6e838e0034de86b48470b6a6bf87d2e262e65c9
|
refs/heads/oe_port
| 2023-06-04T04:44:34.776274
| 2021-04-12T17:33:53
| 2021-04-12T17:33:53
| 113,332,442
| 267
| 109
|
MIT
| 2022-12-29T04:35:40
| 2017-12-06T15:22:02
|
C
|
UTF-8
|
C
| false
| false
| 9,673
|
c
|
enclave_signal.c
|
#include <signal.h>
#include <string.h>
#include <asm/sigcontext.h>
#include <asm-generic/ucontext.h>
#include <lkl_host.h>
#include <lkl/setup.h>
#include <string.h>
#include <openenclave/enclave.h>
#include <openenclave/internal/cpuid.h>
#include "enclave/enclave_oe.h"
#include "enclave/enclave_util.h"
#include "enclave/lthread.h"
#include "enclave/sgxlkl_t.h"
#include "shared/env.h"
#define RDTSC_OPCODE 0x310F
/* Mapping between OE and hardware exception */
struct oe_hw_exception_map
{
uint32_t oe_code; /* OE exception code */
int trapnr; /* Hardware trap no */
int signo; /* Signal for trap */
bool supported; /* Enabled in SGX-LKL */
char* description; /* Description string */
};
// clang-format off
/* Encapsulating the exception information to a datastructure.
* supported field is marked a true/false based on the current
* support. Once all signal support is enabled from OE, then
* all entry will be marked as true.
*/
static struct oe_hw_exception_map exception_map[] = {
{OE_EXCEPTION_DIVIDE_BY_ZERO, X86_TRAP_DE, SIGFPE, true, "SIGFPE (divide by zero)"},
{OE_EXCEPTION_BREAKPOINT, X86_TRAP_BP, SIGTRAP, true, "SIGTRAP (breakpoint)"},
{OE_EXCEPTION_BOUND_OUT_OF_RANGE, X86_TRAP_BR, SIGSEGV, true, "SIGSEGV (bound out of range)"},
{OE_EXCEPTION_ILLEGAL_INSTRUCTION, X86_TRAP_UD, SIGILL, true, "SIGILL (illegal instruction)"},
{OE_EXCEPTION_ACCESS_VIOLATION, X86_TRAP_BR, SIGSEGV, true, "SIGSEGV (access violation)"},
{OE_EXCEPTION_PAGE_FAULT, X86_TRAP_PF, SIGSEGV, true, "SIGSEGV (page fault)"},
{OE_EXCEPTION_X87_FLOAT_POINT, X86_TRAP_MF, SIGFPE, true, "SIGFPE (x87 floating point)"},
{OE_EXCEPTION_MISALIGNMENT, X86_TRAP_AC, SIGBUS, true, "SIGBUS (misalignment)"},
{OE_EXCEPTION_SIMD_FLOAT_POINT, X86_TRAP_XF, SIGFPE, true, "SIGFPE (SIMD float point)"},
};
// clang-format on
static void _sgxlkl_illegal_instr_hook(uint16_t opcode, oe_context_t* context);
static int get_trap_details(
uint32_t oe_code,
struct oe_hw_exception_map* trap_map_info)
{
int index = 0;
int trap_map_size = ARRAY_SIZE(exception_map);
for (index = 0; index < trap_map_size; index++)
{
if ((exception_map[index].oe_code == oe_code) &&
(exception_map[index].supported == true))
{
*trap_map_info = exception_map[index];
return 0;
}
}
return -1;
}
static void serialize_ucontext(const oe_context_t* octx, struct ucontext* uctx)
{
uctx->uc_mcontext.rax = octx->rax;
uctx->uc_mcontext.rbx = octx->rbx;
uctx->uc_mcontext.rcx = octx->rcx;
uctx->uc_mcontext.rdx = octx->rdx;
uctx->uc_mcontext.rbp = octx->rbp;
uctx->uc_mcontext.rsp = octx->rsp;
uctx->uc_mcontext.rdi = octx->rdi;
uctx->uc_mcontext.rsi = octx->rsi;
uctx->uc_mcontext.r8 = octx->r8;
uctx->uc_mcontext.r9 = octx->r9;
uctx->uc_mcontext.r10 = octx->r10;
uctx->uc_mcontext.r11 = octx->r11;
uctx->uc_mcontext.r12 = octx->r12;
uctx->uc_mcontext.r13 = octx->r13;
uctx->uc_mcontext.r14 = octx->r14;
uctx->uc_mcontext.r15 = octx->r15;
uctx->uc_mcontext.rip = octx->rip;
}
static void deserialize_ucontext(
const struct ucontext* uctx,
oe_context_t* octx)
{
octx->rax = uctx->uc_mcontext.rax;
octx->rbx = uctx->uc_mcontext.rbx;
octx->rcx = uctx->uc_mcontext.rcx;
octx->rdx = uctx->uc_mcontext.rdx;
octx->rbp = uctx->uc_mcontext.rbp;
octx->rsp = uctx->uc_mcontext.rsp;
octx->rdi = uctx->uc_mcontext.rdi;
octx->rsi = uctx->uc_mcontext.rsi;
octx->r8 = uctx->uc_mcontext.r8;
octx->r9 = uctx->uc_mcontext.r9;
octx->r10 = uctx->uc_mcontext.r10;
octx->r11 = uctx->uc_mcontext.r11;
octx->r12 = uctx->uc_mcontext.r12;
octx->r13 = uctx->uc_mcontext.r13;
octx->r14 = uctx->uc_mcontext.r14;
octx->r15 = uctx->uc_mcontext.r15;
octx->rip = uctx->uc_mcontext.rip;
}
static uint64_t sgxlkl_enclave_signal_handler(
oe_exception_record_t* exception_record)
{
int ret = -1;
siginfo_t info;
struct ucontext uctx;
struct oe_hw_exception_map trap_info;
oe_context_t* oe_ctx = exception_record->context;
uint16_t* instr_addr = ((uint16_t*)exception_record->context->rip);
uint16_t opcode = instr_addr ? *instr_addr : 0;
/* Emulate illegal instructions in SGX hardware mode */
if (exception_record->code == OE_EXCEPTION_ILLEGAL_INSTRUCTION)
{
SGXLKL_TRACE_SIGNAL(
"Exception SIGILL (illegal instruction) received (code=%d "
"address=0x%lx opcode=0x%x)\n",
exception_record->code,
exception_record->address,
opcode);
_sgxlkl_illegal_instr_hook(opcode, exception_record->context);
return OE_EXCEPTION_CONTINUE_EXECUTION;
}
memset(&trap_info, 0, sizeof(trap_info));
ret = get_trap_details(exception_record->code, &trap_info);
if (ret != -1)
{
SGXLKL_TRACE_SIGNAL(
"Exception %s received (code=%d address=0x%lx opcode=0x%x)\n",
trap_info.description,
exception_record->code,
exception_record->address,
opcode);
#ifdef DEBUG
if (sgxlkl_trace_signal)
{
sgxlkl_print_backtrace((void*)oe_ctx->rbp);
}
#endif
/**
* If LKL has not yet been initialised or is terminating (and thus no
* longer accepts signals), we cannot handle the exception and fail
* instead.
*/
if (!lkl_is_running() || is_lkl_terminating())
{
#ifdef DEBUG
sgxlkl_error("Exception received but LKL is unable to handle it. "
"Printing stack trace saved by exception handler:\n");
/**
* Since we cannot unwind the frames in the OE exception handler,
* we need to print a backtrace with the frame pointer from the
* saved exception context.
*/
sgxlkl_print_backtrace((void*)oe_ctx->rbp);
#endif
struct lthread* lt = lthread_self();
sgxlkl_fail(
"Exception %s received before LKL initialisation/after LKL "
"shutdown (lt->tid=%i [%s] "
"code=%i "
"addr=0x%lx opcode=0x%x "
"ret=%i)\n",
trap_info.description,
lt ? lt->tid : -1,
lt ? lt->attr.funcname : "(?)",
exception_record->code,
(void*)exception_record->address,
opcode,
ret);
}
memset(&uctx, 0, sizeof(uctx));
serialize_ucontext(oe_ctx, &uctx);
info.si_errno = 0;
info.si_code = exception_record->code;
info.si_addr = (void*)exception_record->address;
info.si_signo = trap_info.signo;
/**
* The trap is is passed to LKL. If it can be handled, excecution will
* continue, otherwise LKL will abort the process.
*/
lkl_do_trap(trap_info.trapnr, trap_info.signo, NULL, &uctx, 0, &info);
deserialize_ucontext(&uctx, oe_ctx);
}
else
{
struct lthread* lt = lthread_self();
sgxlkl_fail(
"Unknown exception %s received (lt->tid=%i [%s]"
"code=%i "
"addr=0x%lx opcode=0x%x "
"ret=%i)\n",
trap_info.description,
lt ? lt->tid : -1,
lt ? lt->attr.funcname : "(?)",
exception_record->code,
(void*)exception_record->address,
opcode,
ret);
}
return OE_EXCEPTION_CONTINUE_EXECUTION;
}
static void _sgxlkl_illegal_instr_hook(uint16_t opcode, oe_context_t* context)
{
uint32_t rax, rbx, rcx, rdx;
char* instruction_name = "";
switch (opcode)
{
case OE_CPUID_OPCODE:
rax = 0xaa, rbx = 0xbb, rcx = 0xcc, rdx = 0xdd;
if (context->rax != 0xff)
{
/* Call into host to execute the CPUID instruction. */
sgxlkl_host_hw_cpuid(
(uint32_t)context->rax, /* leaf */
(uint32_t)context->rcx, /* subleaf */
&rax,
&rbx,
&rcx,
&rdx);
}
context->rax = rax;
context->rbx = rbx;
context->rcx = rcx;
context->rdx = rdx;
break;
case RDTSC_OPCODE:
rax = 0, rdx = 0;
/* Call into host to execute the RDTSC instruction */
sgxlkl_host_hw_rdtsc(&rax, &rdx);
context->rax = rax;
context->rdx = rdx;
break;
default:
switch (opcode)
{
case (0x50f):
instruction_name = "syscall";
break;
}
sgxlkl_fail(
"Encountered an illegal instruction inside enclave "
"(opcode=0x%x [%s])\n",
opcode,
instruction_name);
}
/* Skip over the illegal instruction. */
context->rip += 2;
}
void _register_enclave_signal_handlers(int mode)
{
oe_result_t result;
SGXLKL_VERBOSE("Registering OE exception handler...\n");
if (sgxlkl_in_sw_debug_mode())
{
sgxlkl_host_sw_register_signal_handler(
(void*)sgxlkl_enclave_signal_handler);
}
else
{
result = oe_add_vectored_exception_handler(
true, sgxlkl_enclave_signal_handler);
if (result != OE_OK)
sgxlkl_fail("OE exception handler registration failed.\n");
}
}
|
d0ede32bc78c4c9e2ddf7ab61736cc1d33fef438
|
52db6253baa4bf3d32cc7ce0e9e5694b48391e65
|
/tests/platform-independent-tests/tests/first-person-maze/main.c
|
9516eafd7b606cfc5d8b0c0e31e7dac0b7af3a93
|
[
"Unlicense"
] |
permissive
|
SasLuca/rayfork
|
02a8e185002b872a115318410e94abfc0a015bb0
|
0db32b2c80384e89555aa8f64d5be390bbb28573
|
refs/heads/rayfork-0.9
| 2021-09-11T06:30:40.597951
| 2020-12-03T10:59:55
| 2020-12-03T10:59:55
| 228,938,024
| 347
| 27
|
Unlicense
| 2022-08-22T06:09:44
| 2019-12-18T23:25:18
|
C
|
UTF-8
|
C
| false
| false
| 5,911
|
c
|
main.c
|
#include "include/rayfork.h"
#include "glad.h"
#include "GLFW/glfw3.h"
#define SCREEN_WIDTH (800*2)
#define SCREEN_HEIGHT (450*2)
rf_input_state_for_update_camera input;
static void key_callback(GLFWwindow* window, int key, int scancode, int action, int mods)
{
if (key == GLFW_KEY_ESCAPE && action == GLFW_PRESS)
{
glfwSetWindowShouldClose(window, GLFW_TRUE);
}
if (action == GLFW_PRESS || action == GLFW_RELEASE)
{
switch (key)
{
case GLFW_KEY_LEFT_ALT: input.is_camera_alt_control_key_down = action == GLFW_PRESS; break;
case GLFW_KEY_LEFT_CONTROL: input.is_camera_smooth_zoom_control_key = action == GLFW_PRESS; break;
case GLFW_KEY_W: input.direction_keys[0] = action == GLFW_PRESS; break;
case GLFW_KEY_S: input.direction_keys[1] = action == GLFW_PRESS; break;
case GLFW_KEY_D: input.direction_keys[2] = action == GLFW_PRESS; break;
case GLFW_KEY_A: input.direction_keys[3] = action == GLFW_PRESS; break;
case GLFW_KEY_E: input.direction_keys[4] = action == GLFW_PRESS; break;
case GLFW_KEY_Q: input.direction_keys[5] = action == GLFW_PRESS; break;
default: break;
}
}
}
int main()
{
//GLFW init
glfwInit();
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3);
GLFWwindow* window = glfwCreateWindow(SCREEN_WIDTH, SCREEN_HEIGHT, "rayfork [core] example - first person maze", NULL, NULL);
glfwSetKeyCallback(window, key_callback);
glfwMakeContextCurrent(window);
glfwSetInputMode(window, GLFW_CURSOR, GLFW_CURSOR_DISABLED);
glfwMakeContextCurrent(window);
gladLoadGL();
glfwSwapInterval(1);
//Rayfork and game init
//Initialise rayfork and load the default font
rf_context rf_ctx = {0};
rf_default_render_batch rf_mem = {0};
rf_init(&rf_ctx, &rf_mem, SCREEN_WIDTH, SCREEN_HEIGHT, RF_DEFAULT_OPENGL_PROCS);
//Load stuff
rf_image imMap = rf_load_image_from_file(ASSETS_PATH "cubicmap.png", RF_DEFAULT_ALLOCATOR, RF_DEFAULT_ALLOCATOR, RF_DEFAULT_IO); // Load cubicmap image (RAM)
rf_texture2d cubicmap = rf_load_texture_from_image(imMap); // Convert image to texture to display (VRAM)
rf_mesh mesh = rf_gen_mesh_cubicmap(imMap, (rf_vec3){1.0f, 1.0f, 1.0f }, RF_DEFAULT_ALLOCATOR, RF_DEFAULT_ALLOCATOR);
rf_model model = rf_load_model_from_mesh(mesh, RF_DEFAULT_ALLOCATOR);
rf_vec2 ball_position = {(float) SCREEN_WIDTH / 2, (float) SCREEN_HEIGHT / 2 };
rf_camera3d camera = { { 0.2f, 0.4f, 0.2f }, { 0.0f, 0.0f, 0.0f }, { 0.0f, 1.0f, 0.0f }, 45.0f, 0 };
// NOTE: By default each cube is mapped to one part of texture atlas
rf_texture2d texture = rf_load_texture_from_file(ASSETS_PATH "cubicmap_atlas.png", RF_DEFAULT_ALLOCATOR, RF_DEFAULT_IO); // Load map texture
model.materials[0].maps[RF_MAP_DIFFUSE].texture = texture; // Set map diffuse texture
rf_color* mapPixels = imMap.data;
rf_vec3 mapPosition = {-16.0f, 0.0f, -8.0f }; // Set model position
rf_vec3 playerPosition = camera.position;
rf_set_camera3d_mode(camera, RF_CAMERA_FIRST_PERSON);
while (!glfwWindowShouldClose(window))
{
// Update
{
double xpos, ypos;
glfwGetCursorPos(window, &xpos, &ypos);
input.mouse_position.x = (int) xpos;
input.mouse_position.y = (int) ypos;
}
rf_vec3 oldCamPos = camera.position; // Store old camera position
rf_update_camera3d(&camera, input); // Update camera
// Check player collision (we simplify to 2D collision detection)
rf_vec2 playerPos = {camera.position.x, camera.position.z };
float playerRadius = 0.1f; // Collision radius (player is modelled as a cilinder for collision)
int playerCellX = (int)(playerPos.x - mapPosition.x + 0.5f);
int playerCellY = (int)(playerPos.y - mapPosition.z + 0.5f);
// Out-of-limits security check
if (playerCellX < 0) playerCellX = 0;
else if (playerCellX >= cubicmap.width) playerCellX = cubicmap.width - 1;
if (playerCellY < 0) playerCellY = 0;
else if (playerCellY >= cubicmap.height) playerCellY = cubicmap.height - 1;
// Check map collisions using image data and player position
// TODO: Improvement: Just check player surrounding cells for collision
for (int y = 0; y < cubicmap.height; y++)
{
for (int x = 0; x < cubicmap.width; x++)
{
if ((mapPixels[y*cubicmap.width + x].r == 255) && // Collision: white pixel, only check R channel
(rf_check_collision_circle_rec(playerPos, playerRadius,(rf_rec){mapPosition.x - 0.5f + x * 1.0f, mapPosition.z - 0.5f + y * 1.0f, 1.0f, 1.0f })))
{
// Collision detected, reset camera position
camera.position = oldCamPos;
}
}
}
// Render
rf_begin();
rf_clear(RF_RAYWHITE);
rf_draw_texture(texture, 0, 0, RF_WHITE);
rf_begin_3d(camera);
rf_draw_model(model, mapPosition, 1.0f, RF_WHITE); // Draw maze map
//DrawCubeV(playerPosition, (Vector3){ 0.2f, 0.4f, 0.2f }, RED); // Draw player
rf_end_3d();
rf_draw_texture_ex(cubicmap, SCREEN_WIDTH - cubicmap.width * 4 - 20, 20 , cubicmap.width * 4, cubicmap.height * 4, 0, RF_WHITE);
rf_draw_rectangle_outline((rf_rec ) { SCREEN_WIDTH - cubicmap.width * 4 - 20, 20, cubicmap.width * 4 }, cubicmap.height * 4, RF_GREEN);
// Draw player position radar
rf_draw_rectangle(SCREEN_WIDTH - cubicmap.width * 4 - 20 + playerCellX * 4, 20 + playerCellY * 4, 4, 4, RF_RED);
rf_end();
glfwSwapBuffers(window);
glfwPollEvents();
}
}
|
1e13ed2f0bcf16e51914bcf4cc1a02250bb9faef
|
e910318d01528d82040507a49eeeb8dade45b31f
|
/ports/stm32/usbhost/Core/Inc/usbh_def.h
|
cf24d69f3702cfa224f2d52aac80a08a7dac9656
|
[
"MIT"
] |
permissive
|
pfalcon/pycopy
|
e844480a5e5cd463530328889daed2ba87552b8a
|
3ac90ae9c3c6bbebfba9cada2d37025e35c62796
|
refs/heads/pfalcon
| 2023-08-30T09:39:52.290147
| 2022-09-08T16:42:38
| 2022-09-08T16:42:38
| 15,507,576
| 753
| 71
|
MIT
| 2021-05-08T04:59:21
| 2013-12-29T11:38:47
|
C
|
UTF-8
|
C
| false
| false
| 16,666
|
h
|
usbh_def.h
|
/**
******************************************************************************
* @file usbh_def.h
* @author MCD Application Team
* @version V3.0.0
* @date 18-February-2014
* @brief Definitions used in the USB host library
******************************************************************************
* @attention
*
* <h2><center>© COPYRIGHT 2014 STMicroelectronics</center></h2>
*
* Licensed under MCD-ST Liberty SW License Agreement V2, (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.st.com/software_license_agreement_liberty_v2
*
* 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.
*
******************************************************************************
*/
/** @addtogroup USBH_LIB
* @{
*/
/** @addtogroup USBH_LIB_CORE
* @{
*/
/** @defgroup USBH_DEF
* @brief This file is includes USB descriptors
* @{
*/
#ifndef USBH_DEF_H
#define USBH_DEF_H
#include "usbh_conf.h"
#ifndef NULL
#define NULL ((void *)0)
#endif
#ifndef FALSE
#define FALSE 0
#endif
#ifndef TRUE
#define TRUE 1
#endif
#define ValBit(VAR,POS) (VAR & (1 << POS))
#define SetBit(VAR,POS) (VAR |= (1 << POS))
#define ClrBit(VAR,POS) (VAR &= ((1 << POS)^255))
#define LE16(addr) (((uint16_t)(*((uint8_t *)(addr))))\
+ (((uint16_t)(*(((uint8_t *)(addr)) + 1))) << 8))
#define LE16S(addr) (uint16_t)(LE16((addr)))
#define LE32(addr) ((((uint32_t)(*(((uint8_t *)(addr)) + 0))) + \
(((uint32_t)(*(((uint8_t *)(addr)) + 1))) << 8) + \
(((uint32_t)(*(((uint8_t *)(addr)) + 2))) << 16) + \
(((uint32_t)(*(((uint8_t *)(addr)) + 3))) << 24)))
#define LE64(addr) ((((uint64_t)(*(((uint8_t *)(addr)) + 0))) + \
(((uint64_t)(*(((uint8_t *)(addr)) + 1))) << 8) +\
(((uint64_t)(*(((uint8_t *)(addr)) + 2))) << 16) +\
(((uint64_t)(*(((uint8_t *)(addr)) + 3))) << 24) +\
(((uint64_t)(*(((uint8_t *)(addr)) + 4))) << 32) +\
(((uint64_t)(*(((uint8_t *)(addr)) + 5))) << 40) +\
(((uint64_t)(*(((uint8_t *)(addr)) + 6))) << 48) +\
(((uint64_t)(*(((uint8_t *)(addr)) + 7))) << 56)))
#define LE24(addr) ((((uint32_t)(*(((uint8_t *)(addr)) + 0))) + \
(((uint32_t)(*(((uint8_t *)(addr)) + 1))) << 8) + \
(((uint32_t)(*(((uint8_t *)(addr)) + 2))) << 16)))
#define LE32S(addr) (int32_t)(LE32((addr)))
#define USB_LEN_DESC_HDR 0x02
#define USB_LEN_DEV_DESC 0x12
#define USB_LEN_CFG_DESC 0x09
#define USB_LEN_IF_DESC 0x09
#define USB_LEN_EP_DESC 0x07
#define USB_LEN_OTG_DESC 0x03
#define USB_LEN_SETUP_PKT 0x08
/* bmRequestType :D7 Data Phase Transfer Direction */
#define USB_REQ_DIR_MASK 0x80
#define USB_H2D 0x00
#define USB_D2H 0x80
/* bmRequestType D6..5 Type */
#define USB_REQ_TYPE_STANDARD 0x00
#define USB_REQ_TYPE_CLASS 0x20
#define USB_REQ_TYPE_VENDOR 0x40
#define USB_REQ_TYPE_RESERVED 0x60
/* bmRequestType D4..0 Recipient */
#define USB_REQ_RECIPIENT_DEVICE 0x00
#define USB_REQ_RECIPIENT_INTERFACE 0x01
#define USB_REQ_RECIPIENT_ENDPOINT 0x02
#define USB_REQ_RECIPIENT_OTHER 0x03
/* Table 9-4. Standard Request Codes */
/* bRequest , Value */
#define USB_REQ_GET_STATUS 0x00
#define USB_REQ_CLEAR_FEATURE 0x01
#define USB_REQ_SET_FEATURE 0x03
#define USB_REQ_SET_ADDRESS 0x05
#define USB_REQ_GET_DESCRIPTOR 0x06
#define USB_REQ_SET_DESCRIPTOR 0x07
#define USB_REQ_GET_CONFIGURATION 0x08
#define USB_REQ_SET_CONFIGURATION 0x09
#define USB_REQ_GET_INTERFACE 0x0A
#define USB_REQ_SET_INTERFACE 0x0B
#define USB_REQ_SYNCH_FRAME 0x0C
/* Table 9-5. Descriptor Types of USB Specifications */
#define USB_DESC_TYPE_DEVICE 1
#define USB_DESC_TYPE_CONFIGURATION 2
#define USB_DESC_TYPE_STRING 3
#define USB_DESC_TYPE_INTERFACE 4
#define USB_DESC_TYPE_ENDPOINT 5
#define USB_DESC_TYPE_DEVICE_QUALIFIER 6
#define USB_DESC_TYPE_OTHER_SPEED_CONFIGURATION 7
#define USB_DESC_TYPE_INTERFACE_POWER 8
#define USB_DESC_TYPE_HID 0x21
#define USB_DESC_TYPE_HID_REPORT 0x22
#define USB_DEVICE_DESC_SIZE 18
#define USB_CONFIGURATION_DESC_SIZE 9
#define USB_HID_DESC_SIZE 9
#define USB_INTERFACE_DESC_SIZE 9
#define USB_ENDPOINT_DESC_SIZE 7
/* Descriptor Type and Descriptor Index */
/* Use the following values when calling the function USBH_GetDescriptor */
#define USB_DESC_DEVICE ((USB_DESC_TYPE_DEVICE << 8) & 0xFF00)
#define USB_DESC_CONFIGURATION ((USB_DESC_TYPE_CONFIGURATION << 8) & 0xFF00)
#define USB_DESC_STRING ((USB_DESC_TYPE_STRING << 8) & 0xFF00)
#define USB_DESC_INTERFACE ((USB_DESC_TYPE_INTERFACE << 8) & 0xFF00)
#define USB_DESC_ENDPOINT ((USB_DESC_TYPE_INTERFACE << 8) & 0xFF00)
#define USB_DESC_DEVICE_QUALIFIER ((USB_DESC_TYPE_DEVICE_QUALIFIER << 8) & 0xFF00)
#define USB_DESC_OTHER_SPEED_CONFIGURATION ((USB_DESC_TYPE_OTHER_SPEED_CONFIGURATION << 8) & 0xFF00)
#define USB_DESC_INTERFACE_POWER ((USB_DESC_TYPE_INTERFACE_POWER << 8) & 0xFF00)
#define USB_DESC_HID_REPORT ((USB_DESC_TYPE_HID_REPORT << 8) & 0xFF00)
#define USB_DESC_HID ((USB_DESC_TYPE_HID << 8) & 0xFF00)
#define USB_EP_TYPE_CTRL 0x00
#define USB_EP_TYPE_ISOC 0x01
#define USB_EP_TYPE_BULK 0x02
#define USB_EP_TYPE_INTR 0x03
#define USB_EP_DIR_OUT 0x00
#define USB_EP_DIR_IN 0x80
#define USB_EP_DIR_MSK 0x80
#define USBH_MAX_PIPES_NBR 15
#define USBH_DEVICE_ADDRESS_DEFAULT 0
#define USBH_MAX_ERROR_COUNT 2
#define USBH_DEVICE_ADDRESS 1
/**
* @}
*/
#define USBH_CONFIGURATION_DESCRIPTOR_SIZE (USB_CONFIGURATION_DESC_SIZE \
+ USB_INTERFACE_DESC_SIZE\
+ (USBH_MAX_NUM_ENDPOINTS * USB_ENDPOINT_DESC_SIZE))
#define CONFIG_DESC_wTOTAL_LENGTH (ConfigurationDescriptorData.ConfigDescfield.\
ConfigurationDescriptor.wTotalLength)
typedef union
{
uint16_t w;
struct BW
{
uint8_t msb;
uint8_t lsb;
}
bw;
}
uint16_t_uint8_t;
typedef union _USB_Setup
{
uint32_t d8[2];
struct _SetupPkt_Struc
{
uint8_t bmRequestType;
uint8_t bRequest;
uint16_t_uint8_t wValue;
uint16_t_uint8_t wIndex;
uint16_t_uint8_t wLength;
} b;
}
USB_Setup_TypeDef;
typedef struct _DescHeader
{
uint8_t bLength;
uint8_t bDescriptorType;
}
USBH_DescHeader_t;
typedef struct _DeviceDescriptor
{
uint8_t bLength;
uint8_t bDescriptorType;
uint16_t bcdUSB; /* USB Specification Number which device complies too */
uint8_t bDeviceClass;
uint8_t bDeviceSubClass;
uint8_t bDeviceProtocol;
/* If equal to Zero, each interface specifies its own class
code if equal to 0xFF, the class code is vendor specified.
Otherwise field is valid Class Code.*/
uint8_t bMaxPacketSize;
uint16_t idVendor; /* Vendor ID (Assigned by USB Org) */
uint16_t idProduct; /* Product ID (Assigned by Manufacturer) */
uint16_t bcdDevice; /* Device Release Number */
uint8_t iManufacturer; /* Index of Manufacturer String Descriptor */
uint8_t iProduct; /* Index of Product String Descriptor */
uint8_t iSerialNumber; /* Index of Serial Number String Descriptor */
uint8_t bNumConfigurations; /* Number of Possible Configurations */
}
USBH_DevDescTypeDef;
typedef struct _EndpointDescriptor
{
uint8_t bLength;
uint8_t bDescriptorType;
uint8_t bEndpointAddress; /* indicates what endpoint this descriptor is describing */
uint8_t bmAttributes; /* specifies the transfer type. */
uint16_t wMaxPacketSize; /* Maximum Packet Size this endpoint is capable of sending or receiving */
uint8_t bInterval; /* is used to specify the polling interval of certain transfers. */
}
USBH_EpDescTypeDef;
typedef struct _InterfaceDescriptor
{
uint8_t bLength;
uint8_t bDescriptorType;
uint8_t bInterfaceNumber;
uint8_t bAlternateSetting; /* Value used to select alternative setting */
uint8_t bNumEndpoints; /* Number of Endpoints used for this interface */
uint8_t bInterfaceClass; /* Class Code (Assigned by USB Org) */
uint8_t bInterfaceSubClass; /* Subclass Code (Assigned by USB Org) */
uint8_t bInterfaceProtocol; /* Protocol Code */
uint8_t iInterface; /* Index of String Descriptor Describing this interface */
USBH_EpDescTypeDef Ep_Desc[USBH_MAX_NUM_ENDPOINTS];
}
USBH_InterfaceDescTypeDef;
typedef struct _ConfigurationDescriptor
{
uint8_t bLength;
uint8_t bDescriptorType;
uint16_t wTotalLength; /* Total Length of Data Returned */
uint8_t bNumInterfaces; /* Number of Interfaces */
uint8_t bConfigurationValue; /* Value to use as an argument to select this configuration*/
uint8_t iConfiguration; /*Index of String Descriptor Describing this configuration */
uint8_t bmAttributes; /* D7 Bus Powered , D6 Self Powered, D5 Remote Wakeup , D4..0 Reserved (0)*/
uint8_t bMaxPower; /*Maximum Power Consumption */
USBH_InterfaceDescTypeDef Itf_Desc[USBH_MAX_NUM_INTERFACES];
}
USBH_CfgDescTypeDef;
/* Following USB Host status */
typedef enum
{
USBH_OK = 0,
USBH_BUSY,
USBH_FAIL,
USBH_NOT_SUPPORTED,
USBH_UNRECOVERED_ERROR,
USBH_ERROR_SPEED_UNKNOWN,
}USBH_StatusTypeDef;
/** @defgroup USBH_CORE_Exported_Types
* @{
*/
typedef enum
{
USBH_SPEED_HIGH = 0,
USBH_SPEED_FULL = 1,
USBH_SPEED_LOW = 2,
}USBH_SpeedTypeDef;
/* Following states are used for gState */
typedef enum
{
HOST_IDLE =0,
HOST_DEV_WAIT_FOR_ATTACHMENT,
HOST_DEV_ATTACHED,
HOST_DEV_DISCONNECTED,
HOST_DETECT_DEVICE_SPEED,
HOST_ENUMERATION,
HOST_CLASS_REQUEST,
HOST_INPUT,
HOST_SET_CONFIGURATION,
HOST_CHECK_CLASS,
HOST_CLASS,
HOST_SUSPENDED,
HOST_ABORT_STATE,
}HOST_StateTypeDef;
/* Following states are used for EnumerationState */
typedef enum
{
ENUM_IDLE = 0,
ENUM_GET_FULL_DEV_DESC,
ENUM_SET_ADDR,
ENUM_GET_CFG_DESC,
ENUM_GET_FULL_CFG_DESC,
ENUM_GET_MFC_STRING_DESC,
ENUM_GET_PRODUCT_STRING_DESC,
ENUM_GET_SERIALNUM_STRING_DESC,
} ENUM_StateTypeDef;
/* Following states are used for CtrlXferStateMachine */
typedef enum
{
CTRL_IDLE =0,
CTRL_SETUP,
CTRL_SETUP_WAIT,
CTRL_DATA_IN,
CTRL_DATA_IN_WAIT,
CTRL_DATA_OUT,
CTRL_DATA_OUT_WAIT,
CTRL_STATUS_IN,
CTRL_STATUS_IN_WAIT,
CTRL_STATUS_OUT,
CTRL_STATUS_OUT_WAIT,
CTRL_ERROR,
CTRL_STALLED,
CTRL_COMPLETE
}CTRL_StateTypeDef;
/* Following states are used for RequestState */
typedef enum
{
CMD_IDLE =0,
CMD_SEND,
CMD_WAIT
} CMD_StateTypeDef;
typedef enum {
USBH_URB_IDLE = 0,
USBH_URB_DONE,
USBH_URB_NOTREADY,
USBH_URB_NYET,
USBH_URB_ERROR,
USBH_URB_STALL
}USBH_URBStateTypeDef;
typedef enum
{
USBH_PORT_EVENT = 1,
USBH_URB_EVENT,
USBH_CONTROL_EVENT,
USBH_CLASS_EVENT,
USBH_STATE_CHANGED_EVENT,
}
USBH_OSEventTypeDef;
/* Control request structure */
typedef struct
{
uint8_t pipe_in;
uint8_t pipe_out;
uint8_t pipe_size;
uint8_t *buff;
uint16_t length;
uint16_t timer;
USB_Setup_TypeDef setup;
CTRL_StateTypeDef state;
uint8_t errorcount;
} USBH_CtrlTypeDef;
/* Attached device structure */
typedef struct
{
#if (USBH_KEEP_CFG_DESCRIPTOR == 1)
uint8_t CfgDesc_Raw[USBH_MAX_SIZE_CONFIGURATION];
#endif
uint8_t Data[USBH_MAX_DATA_BUFFER];
uint8_t address;
uint8_t speed;
__IO uint8_t is_connected;
uint8_t current_interface;
USBH_DevDescTypeDef DevDesc;
USBH_CfgDescTypeDef CfgDesc;
}USBH_DeviceTypeDef;
struct _USBH_HandleTypeDef;
/* USB Host Class structure */
typedef struct
{
const char *Name;
uint8_t ClassCode;
USBH_StatusTypeDef (*Init) (struct _USBH_HandleTypeDef *phost);
USBH_StatusTypeDef (*DeInit) (struct _USBH_HandleTypeDef *phost);
USBH_StatusTypeDef (*Requests) (struct _USBH_HandleTypeDef *phost);
USBH_StatusTypeDef (*BgndProcess) (struct _USBH_HandleTypeDef *phost);
USBH_StatusTypeDef (*SOFProcess) (struct _USBH_HandleTypeDef *phost);
void* pData;
} USBH_ClassTypeDef;
/* USB Host handle structure */
typedef struct _USBH_HandleTypeDef
{
__IO HOST_StateTypeDef gState; /* Host State Machine Value */
ENUM_StateTypeDef EnumState; /* Enumeration state Machine */
CMD_StateTypeDef RequestState;
USBH_CtrlTypeDef Control;
USBH_DeviceTypeDef device;
USBH_ClassTypeDef* pClass[USBH_MAX_NUM_SUPPORTED_CLASS];
USBH_ClassTypeDef* pActiveClass;
uint32_t ClassNumber;
uint32_t Pipes[15];
__IO uint32_t Timer;
uint8_t id;
void* pData;
void (* pUser )(struct _USBH_HandleTypeDef *pHandle, uint8_t id);
#if (USBH_USE_OS == 1)
osMessageQId os_event;
osThreadId thread;
#endif
} USBH_HandleTypeDef;
#if defined ( __GNUC__ )
#ifndef __weak
#define __weak __attribute__((weak))
#endif /* __weak */
#ifndef __packed
#define __packed __attribute__((__packed__))
#endif /* __packed */
#endif /* __GNUC__ */
#endif
/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
|
87cd65d33fe81783bc8e27e5db94aa8303ce7f15
|
67801a1568b81ea5e45ed534301cd35949066e6d
|
/src/registers/memory/dma.h
|
a65116940d98bcb52587af338be2b81cf1f4075b
|
[
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
fossasia/pslab-firmware
|
dcb8e570d162c0ef24cdedf43483c706bc736259
|
c93ac629442315c1430120b7ab3c0026d03e3503
|
refs/heads/main
| 2023-07-22T18:22:30.827478
| 2023-07-05T05:32:15
| 2023-07-05T05:38:34
| 86,472,725
| 2,212
| 89
|
Apache-2.0
| 2023-09-14T20:36:23
| 2017-03-28T14:53:27
|
C
|
UTF-8
|
C
| false
| false
| 25,833
|
h
|
dma.h
|
#ifndef DMA_H
#define DMA_H
#include <xc.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
#ifdef __cplusplus // Provide C++ Compatibility
extern "C" {
#endif
/**
Section: Data Types
*/
/** DMA Modes
@Summary
Defines the current DMA mode in use
@Description
This routine defines the current mode that is used to handle during
interrupt events
Remarks:
None
*/
typedef enum {
DMA_MODES_ONE_CHANNEL,
DMA_MODES_TWO_CHANNEL,
DMA_MODES_THREE_CHANNEL,
DMA_MODES_FOUR_CHANNEL
} DMA_MODES;
/** DMA Channel Definition
@Summary
Defines the channels available for DMA
@Description
This routine defines the channels that are available for the module to use.
Remarks:
None
*/
typedef enum {
DMA_CHANNEL_0 = 0,
DMA_CHANNEL_1 = 1,
DMA_CHANNEL_2 = 2,
DMA_CHANNEL_3 = 3
} DMA_CHANNEL;
/** DMA Operating Modes Definition
@Summary
Defines the operating modes for DMA modules
@Description
This routine defines the order of block transfers from/to DMA buffer
Remarks:
None
*/
typedef enum {
DMA_OPERATING_MODE_CONTINUOUS = 0b00,
DMA_OPERATING_MODE_ONE_SHOT = 0b01,
DMA_OPERATING_MODE_CONTINUOUS_PING_PONG = 0b10,
DMA_OPERATING_MODE_ONE_SHOT_PINT_PONG = 0b11
} DMA_OPERATING_MODE;
/** DMA Peripheral IRQ Number
@Summary
Defines the DMA Peripheral IRQ number.
@Description
This routine defines the DMA Peripheral IRQ number.
Remarks:
None
*/
typedef enum {
DMA_PERIPHERAL_IRQ_INT0 = 0x00,
DMA_PERIPHERAL_IRQ_IC1 = 0x01,
DMA_PERIPHERAL_IRQ_IC2 = 0x05,
DMA_PERIPHERAL_IRQ_IC3 = 0x25,
DMA_PERIPHERAL_IRQ_IC4 = 0x26,
DMA_PERIPHERAL_IRQ_OC1 = 0x02,
DMA_PERIPHERAL_IRQ_OC2 = 0x06,
DMA_PERIPHERAL_IRQ_OC3 = 0x19,
DMA_PERIPHERAL_IRQ_OC4 = 0x1A,
DMA_PERIPHERAL_IRQ_TMR2 = 0x07,
DMA_PERIPHERAL_IRQ_TMR3 = 0x08,
DMA_PERIPHERAL_IRQ_TMR4 = 0x1B,
DMA_PERIPHERAL_IRQ_TMR5 = 0x1C,
DMA_PERIPHERAL_IRQ_SPI1 = 0x0A,
DMA_PERIPHERAL_IRQ_SPI2 = 0x21,
DMA_PERIPHERAL_IRQ_UART1_TX = 0x0C,
DMA_PERIPHERAL_IRQ_UART1_RX = 0x0B,
DMA_PERIPHERAL_IRQ_UART2_TX = 0x1F,
DMA_PERIPHERAL_IRQ_UART2_RX = 0x1E,
DMA_PERIPHERAL_IRQ_ADC1 = 0x0D
} DMA_PERIPHERAL_IRQ_NUMBER;
/**
Section: Interface Routines
*/
/**
@Summary
This function initializes DMA instance : 1
@Description
This routine initializes the DMA driver instance for : 1
index, making it ready for clients to open and use it. It also initializes any
internal data structures.
This routine must be called before any other DMA routine is called.
@Preconditions
None.
@Param
None.
@Returns
None.
@Comment
@Example
<code>
unsigned short int srcArray[100];
unsigned short int dstArray[100];
int i;
int count;
for (i=0; i<100; i++)
{
srcArray[i] = i+1;
dstArray[i] = 0;
}
DMA_Initialize();
DMA_SoftwareTriggerEnable(CHANNEL1);
count = DMA_TransferCountGet;
while(count > 0)
{
while(
DMA_SoftwareTriggerEnable(CHANNEL1);
}
</code>
*/
void DMA_Initialize(void);
void DMA_InitializeChannel0(void);
void DMA_InitializeChannel1(void);
void DMA_InitializeChannel2(void);
void DMA_InitializeChannel3(void);
/**
@Summary
Clears the interrupt request flag.
@Description
This routine is used to clear the interrupt request flag. This routine sets the value of the DMAIF bit to 0.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_FlagInterruptClear(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
IFS0bits.DMA0IF = 0;
break;
case DMA_CHANNEL_1:
IFS0bits.DMA1IF = 0;
break;
case DMA_CHANNEL_2:
IFS1bits.DMA2IF = 0;
break;
case DMA_CHANNEL_3:
IFS2bits.DMA3IF = 0;
break;
default:break;
}
}
/**
@Summary
Enables the interrupt for a DMA channel
@Description
This routine is used to enable an interrupt for a DMA channel. This routine
sets the value of the DMAIE bit to 1.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_InterruptEnable(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
IEC0bits.DMA0IE = 1;
break;
case DMA_CHANNEL_1:
IEC0bits.DMA1IE = 1;
break;
case DMA_CHANNEL_2:
IEC1bits.DMA2IE = 1;
break;
case DMA_CHANNEL_3:
IEC2bits.DMA3IE = 1;
break;
default:break;
}
}
/**
@Summary
Disables the interrupt for a DMA channel
@Description
This routine is used to disable an interrupt for a DMA channel. This routine
sets the value of the DMAIE bit to 0.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_InterruptDisable(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
IEC0bits.DMA0IE = 0;
break;
case DMA_CHANNEL_1:
IEC0bits.DMA1IE = 0;
break;
case DMA_CHANNEL_2:
IEC1bits.DMA2IE = 0;
break;
case DMA_CHANNEL_3:
IEC2bits.DMA3IE = 0;
break;
default:break;
}
}
/**
@Summary
Enables the channel in the DMA
@Description
This routine is used to enable a channel in the DMA. This routine
sets the value of the CHEN bit to 1.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_ChannelEnable(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0CONbits.CHEN = 1;
break;
case DMA_CHANNEL_1:
DMA1CONbits.CHEN = 1;
break;
case DMA_CHANNEL_2:
DMA2CONbits.CHEN = 1;
break;
case DMA_CHANNEL_3:
DMA3CONbits.CHEN = 1;
break;
default: break;
}
}
/**
@Summary
Disables the channel in the DMA
@Description
This routine is used to disable a channel in the DMA. This routine
sets the value of the CHEN bit to 0.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_ChannelDisable(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0CONbits.CHEN = 0;
break;
case DMA_CHANNEL_1:
DMA1CONbits.CHEN = 0;
break;
case DMA_CHANNEL_2:
DMA2CONbits.CHEN = 0;
break;
case DMA_CHANNEL_3:
DMA3CONbits.CHEN = 0;
break;
default: break;
}
}
/**
@Summary
Enables one-shot mode.
@Description
This routine is used to enable one-shot mode on a channel in the DMA. In
one-shot mode, the channel is automatically disabled after finishing
moving the data block.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
Pass in the required channel from the DMA_CHANNEL list.
@Example
DMA_SetOneShotMode(DMA_CHANNEL_0); // Set one-shot mode on DMA0.
*/
inline static void DMA_SetOneShotMode(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0CONbits.MODE |= 0b01;
break;
case DMA_CHANNEL_1:
DMA1CONbits.MODE |= 0b01;
break;
case DMA_CHANNEL_2:
DMA2CONbits.MODE |= 0b01;
break;
case DMA_CHANNEL_3:
DMA3CONbits.MODE |= 0b01;
break;
default: break;
}
}
/**
@Summary
Sets the transfer count of the DMA
@Description
This routine is used to set the DMA transfer count. This routine sets the
value of the DMACNT register.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_TransferCountSet(DMA_CHANNEL channel, uint16_t transferCount) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0CNT = transferCount;
break;
case DMA_CHANNEL_1:
DMA1CNT = transferCount;
break;
case DMA_CHANNEL_2:
DMA2CNT = transferCount;
break;
case DMA_CHANNEL_3:
DMA3CNT = transferCount;
break;
default: break;
}
}
/**
@Summary
Returns the transfer count of the DMA
@Description
This routine is used to determine the DMA transfer count. This routine
returns the value of the DMACNT register.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
Returns the transfer count of the DMA
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static uint16_t DMA_TransferCountGet(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
return (DMA0CNT);
case DMA_CHANNEL_1:
return (DMA1CNT);
case DMA_CHANNEL_2:
return (DMA2CNT);
case DMA_CHANNEL_3:
return (DMA3CNT);
default: return 0;
}
}
/**
@Summary
Initiates a transfer on the requested DMA channel.
@Description
This routine is used to initiate a transfer on the requested DMA channel. When a transfer on the requested channel is initiated the routine
returns the value of the FORCE bit. It returns 0 otherwise.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
Returns true if the transfer on the requested channel is initiated
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_SoftwareTriggerEnable(DMA_CHANNEL channel) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0REQbits.FORCE = 1;
break;
case DMA_CHANNEL_1:
DMA1REQbits.FORCE = 1;
break;
case DMA_CHANNEL_2:
DMA2REQbits.FORCE = 1;
break;
case DMA_CHANNEL_3:
DMA3REQbits.FORCE = 1;
break;
default: break;
}
}
/**
@Summary
Sets the address for register A in the DMA
@Description
This routine is used to set the address in register A for a DMA channel.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_StartAddressASet(DMA_CHANNEL channel, uint16_t address) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0STAL = address;
DMA0STAH = 0;
break;
case DMA_CHANNEL_1:
DMA1STAL = address;
DMA1STAH = 0;
break;
case DMA_CHANNEL_2:
DMA2STAL = address;
DMA2STAH = 0;
break;
case DMA_CHANNEL_3:
DMA3STAL = address;
DMA3STAH = 0;
break;
default: break;
}
}
/**
@Summary
Sets high and low addresss for register A in the DMA
@Description
This routine is used to set both the high and low address in register A
for a DMA channel.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
channel: DMA channel
address_low: Low address location
address_high: high address location
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_StartAddressAFullSet(DMA_CHANNEL channel, uint16_t address_low, uint16_t address_high) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0STAL = address_low;
DMA0STAH = address_high;
break;
case DMA_CHANNEL_1:
DMA1STAL = address_low;
DMA1STAH = address_high;
break;
case DMA_CHANNEL_2:
DMA2STAL = address_low;
DMA2STAH = address_high;
break;
case DMA_CHANNEL_3:
DMA3STAL = address_low;
DMA3STAH = address_high;
break;
default: break;
}
}
/**
@Summary
Sets the address for register B in the DMA
@Description
This routine is used to set the address in register B for a DMA channel.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_StartAddressBSet(DMA_CHANNEL channel, uint16_t address) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0STBL = address;
DMA0STBH = 0;
break;
case DMA_CHANNEL_1:
DMA1STBL = address;
DMA1STBH = 0;
break;
case DMA_CHANNEL_2:
DMA2STBL = address;
DMA2STBH = 0;
break;
case DMA_CHANNEL_3:
DMA3STBL = address;
DMA3STBH = 0;
break;
default: break;
}
}
/**
@Summary
Gets the address for register A in the DMA
@Description
This routine is used to get the address in register A for a DMA channel.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static uint16_t DMA_StartAddressAGet(DMA_CHANNEL channel) {
uint16_t address;
switch (channel) {
case DMA_CHANNEL_0:
address = DMA0STAL;
break;
case DMA_CHANNEL_1:
address = DMA1STAL;
break;
case DMA_CHANNEL_2:
address = DMA2STAL;
break;
case DMA_CHANNEL_3:
address = DMA3STAL;
break;
default:
address = 0;
break;
}
return address;
}
/**
@Summary
Gets the address for register B in the DMA
@Description
This routine is used to get the address in register B for a DMA channel.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static uint16_t DMA_StartAddressBGet(DMA_CHANNEL channel) {
uint16_t address;
switch (channel) {
case DMA_CHANNEL_0:
address = DMA0STBL;
break;
case DMA_CHANNEL_1:
address = DMA1STBL;
break;
case DMA_CHANNEL_2:
address = DMA2STBL;
break;
case DMA_CHANNEL_3:
address = DMA3STBL;
break;
default:
address = 0;
break;
}
return address;
}
/**
@Summary
Sets the peripheral address in the DMA
@Description
This routine is used to set the peripheral address for a DMA channel.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_PeripheralAddressSet(DMA_CHANNEL channel, uint16_t address) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0PAD = address;
break;
case DMA_CHANNEL_1:
DMA1PAD = address;
break;
case DMA_CHANNEL_2:
DMA2PAD = address;
break;
case DMA_CHANNEL_3:
DMA3PAD = address;
break;
default: break;
}
}
/**
@Summary
Returns true when there is a Peripheral Write Collision Event
@Description
This routine is used to determine if there is a Peripheral Write Collision Event. This routine
returns the value of the PWCOL bit in DMAPWC register. When there is a Peripheral Write Collision Event, the routine
returns 1. It returns 0 otherwise.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
Returns true if there is a Peripheral Write Collision Event
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static bool DMA_IsPeripheralWriteCollision(uint16_t dmaChannel) {
return DMAPWC & (1 << dmaChannel);
}
/**
@Summary
Returns true when there is a Request Collision Event
@Description
This routine is used to determine if there is a Request Collision Event. This routine
returns the value of the RQCOL bit in DMARQC register. When there is a Request Collision Event, the routine
returns 1. It returns 0 otherwise.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
Returns true if there is a Request Collision Event
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static bool DMA_IsRequestCollision(uint16_t dmaChannel) {
return DMARQC & (1 << dmaChannel);
}
/**
@Summary
Sets the requested DMA Channel IRQ Select register with the requested peripheral IRQ number.
@Description
This routine is used to set the requested DMA Channel IRQ Select register with the requested peripheral IRQ number.
@Preconditions
DMA_Initializer() function should have been
called before calling this function.
@Returns
None
@Param
None
@Example
Refer to DMA_Initializer(); for an example
*/
inline static void DMA_PeripheralIrqNumberSet(DMA_CHANNEL channel, DMA_PERIPHERAL_IRQ_NUMBER irqNumber) {
switch (channel) {
case DMA_CHANNEL_0:
DMA0REQbits.IRQSEL = irqNumber;
break;
case DMA_CHANNEL_1:
DMA1REQbits.IRQSEL = irqNumber;
break;
case DMA_CHANNEL_2:
DMA2REQbits.IRQSEL = irqNumber;
break;
case DMA_CHANNEL_3:
DMA3REQbits.IRQSEL = irqNumber;
break;
default: break;
}
}
/**
@Summary
Set channel mode for DMA1 interrupts when using logic analyzer
@Description
This routine is a setter method to prevent using global variables in ISR
@Param
LOGICANALYZER_DMA_MODES
@Returns
None
*/
void DMA_SetLogicAnalyzerChannelMode(DMA_MODES mode);
/**
@Summary
Prepares DMA0 channel to connect with IC1 module
@Description
This routine prepares pads and sources to capture timer values in IC1
upon a signal requesting the DMA module to start a transfer
@Preconditions
DMA0 channel should be turned off prior to calling this routine and the
channel could be turned on after this routine is complete
@Param
count: number of transfers
address: pointer to the buffer location to store data
trigger: signal source to generate a data transfer action
@Returns
None
*/
void DMA_PrepareChannel0(uint16_t count, volatile uint16_t* low_address,
DMA_PERIPHERAL_IRQ_NUMBER trigger);
/**
@Summary
Prepares DMA1 channel to connect with IC2 module
@Description
This routine prepares pads and sources to capture timer values in IC2
upon a signal requesting the DMA module to start a transfer
@Preconditions
DMA0 channel should be turned off prior to calling this routine and the
channel could be turned on after this routine is complete
@Param
count: number of transfers
address: pointer to the buffer location to store data
trigger: signal source to generate a data transfer action
@Returns
None
*/
void DMA_PrepareChannel1(uint16_t count, volatile uint16_t* low_address,
DMA_PERIPHERAL_IRQ_NUMBER trigger);
/**
@Summary
Prepares DMA2 channel to connect with IC3 module
@Description
This routine prepares pads and sources to capture timer values in IC3
upon a signal requesting the DMA module to start a transfer
@Preconditions
DMA0 channel should be turned off prior to calling this routine and the
channel could be turned on after this routine is complete
@Param
count: number of transfers
address: pointer to the buffer location to store data
trigger: signal source to generate a data transfer action
@Returns
None
*/
void DMA_PrepareChannel2(uint16_t count, volatile uint16_t* low_address,
DMA_PERIPHERAL_IRQ_NUMBER trigger);
/**
@Summary
Prepares DMA3 channel to connect with IC4 module
@Description
This routine prepares pads and sources to capture timer values in IC4
upon a signal requesting the DMA module to start a transfer
@Preconditions
DMA0 channel should be turned off prior to calling this routine and the
channel could be turned on after this routine is complete
@Param
count: number of transfers
address: pointer to the buffer location to store data
trigger: signal source to generate a data transfer action
@Returns
None
*/
void DMA_PrepareChannel3(uint16_t count, volatile uint16_t* low_address,
DMA_PERIPHERAL_IRQ_NUMBER trigger);
// Enable all four channels in one go
void DMA_EnableAllChannels(void);
// Disable all four channels in one go
void DMA_DisableAllChannels(void);
// Getters and Setters
void SetDMA_MODE(DMA_MODES mode);
DMA_MODES GetDMA_MODE(void);
#ifdef __cplusplus // Provide C++ Compatibility
}
#endif
#endif // DMA_H
|
b643f60f0a4dd180648936bbdabb11210d17c473
|
e2bd18a0b6a1d92755573befb52553f90c21d177
|
/cores/arduino/stm8/STM8_StdPeriph_Driver/stm8xx_rst.c
|
7eaf0fd0caf161826df45c643dcb4a50b43f0370
|
[
"BSD-3-Clause"
] |
permissive
|
stm32duino/Arduino_Core_STM8
|
2b86bf16943a0ae4f984df79e8a8d7890feae5bf
|
cc4d30f28145a4778dfe228856e6ea48b00390b5
|
refs/heads/main
| 2023-09-02T11:14:06.407352
| 2023-03-31T07:08:07
| 2023-03-31T07:08:07
| 124,064,982
| 143
| 52
|
BSD-3-Clause
| 2021-12-08T09:57:52
| 2018-03-06T10:56:31
|
C
|
UTF-8
|
C
| false
| false
| 101
|
c
|
stm8xx_rst.c
|
#if defined (STM8Sxx)
#include "stm8s_rst.c"
#elif defined (STM8Lxx)
#include "stm8l15x_rst.c"
#endif
|
d8cc55ef2d1f40c43c567aecdc013852cd419a51
|
fce81b804cae23f525a5ad4370b684bf0dc531a5
|
/numpy/core/src/common/npy_partition.h
|
85a0727c58d4f04e1dc1d8de75f0e2a17697137c
|
[
"Zlib",
"BSD-3-Clause",
"MIT",
"Apache-2.0"
] |
permissive
|
numpy/numpy
|
ba2abcc1d2d46affbb6aabe5aed6407b4b57507e
|
dc2ff125493777a1084044e6cd6857a42ee323d4
|
refs/heads/main
| 2023-09-05T10:10:52.767363
| 2023-09-04T18:03:29
| 2023-09-04T18:03:29
| 908,607
| 25,725
| 11,968
|
BSD-3-Clause
| 2023-09-14T21:26:09
| 2010-09-13T23:02:39
|
Python
|
UTF-8
|
C
| false
| false
| 537
|
h
|
npy_partition.h
|
#ifndef NUMPY_CORE_SRC_COMMON_PARTITION_H_
#define NUMPY_CORE_SRC_COMMON_PARTITION_H_
#include "npy_sort.h"
/* Python include is for future object sorts */
#include <Python.h>
#include <numpy/ndarraytypes.h>
#include <numpy/npy_common.h>
#define NPY_MAX_PIVOT_STACK 50
#ifdef __cplusplus
extern "C" {
#endif
NPY_NO_EXPORT PyArray_PartitionFunc *
get_partition_func(int type, NPY_SELECTKIND which);
NPY_NO_EXPORT PyArray_ArgPartitionFunc *
get_argpartition_func(int type, NPY_SELECTKIND which);
#ifdef __cplusplus
}
#endif
#endif
|
54c8fbb658b5773eb5231f5b6ee5e1ddb7059ae0
|
057a475216e9beed41983481aafcaf109bbf58da
|
/base/glibc-compatibility/musl/clock_nanosleep.c
|
7c7a9f78288056d89ebed8d9e5b4857d43697ff0
|
[
"Apache-2.0",
"LicenseRef-scancode-public-domain",
"BSD-2-Clause",
"LicenseRef-scancode-other-permissive",
"LicenseRef-scancode-mit-nagy",
"LicenseRef-scancode-musl-exception",
"MIT",
"BSD-3-Clause"
] |
permissive
|
ClickHouse/ClickHouse
|
fece5204263a5b4d693854b6039699265f1bb27f
|
6649328db809d51a694c358571539bc5820464be
|
refs/heads/master
| 2023-08-31T18:48:36.615225
| 2023-08-31T17:51:24
| 2023-08-31T17:51:24
| 60,246,359
| 23,878
| 5,449
|
Apache-2.0
| 2023-09-14T20:10:52
| 2016-06-02T08:28:18
|
C++
|
UTF-8
|
C
| false
| false
| 1,009
|
c
|
clock_nanosleep.c
|
#include <errno.h>
#include <pthread.h>
#include <time.h>
#include "syscall.h"
int clock_nanosleep(clockid_t clk, int flags, const struct timespec * req, struct timespec * rem)
{
if (clk == CLOCK_THREAD_CPUTIME_ID)
return EINVAL;
int old_cancel_type;
int status;
/// We cannot port __syscall_cp because musl has very limited cancellation point implementation.
/// For example, c++ destructors won't get called and exception unwinding isn't implemented.
/// Instead, we use normal __syscall here and turn on the asynchrous cancel mode to allow
/// cancel. This works because nanosleep doesn't contain any resource allocations or
/// deallocations.
pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, &old_cancel_type);
if (clk == CLOCK_REALTIME && !flags)
status = -__syscall(SYS_nanosleep, req, rem);
else
status = -__syscall(SYS_clock_nanosleep, clk, flags, req, rem);
pthread_setcanceltype(old_cancel_type, NULL);
return status;
}
|
466e19700e898a1190f9ceb37c5635510ecbe153
|
19102a3c11268052348cf669e23bbfe2780bb067
|
/MinecraftC/Level/Generator/Noise/Noise.c
|
712707b9c584e61d9a124ee6379abb9950c00ca0
|
[
"MIT"
] |
permissive
|
johnpayne-dev/MinecraftC
|
4f6578fd12c0ff8b70e8b9d2c11c4934a822203c
|
43928d42e1f32bd76a994f0bb22c0153a7271b3f
|
refs/heads/main
| 2023-08-04T00:51:16.467779
| 2022-07-31T18:45:33
| 2022-07-31T18:45:33
| 338,597,768
| 303
| 31
|
MIT
| 2022-07-31T18:45:34
| 2021-02-13T14:55:07
|
C
|
UTF-8
|
C
| false
| false
| 600
|
c
|
Noise.c
|
#include "Noise.h"
#include "OctaveNoise.h"
#include "CombinedNoise.h"
#include "PerlinNoise.h"
#include <stdlib.h>
void NoiseCreate(Noise * noise) {
*noise = (Noise){ 0 };
}
float NoiseCompute(Noise * noise, float x, float y) {
if (noise->type == NoiseTypeOctave) { return OctaveNoiseCompute(noise, x, y); }
if (noise->type == NoiseTypePerlin) { return PerlinNoiseCompute(noise, x, y); }
if (noise->type == NoiseTypeCombined) { return CombinedNoiseCompute(noise, x, y); }
return 0.0;
}
void NoiseDestroy(Noise * noise) {
if (noise->type == NoiseTypeOctave) { OctaveNoiseDestroy(noise); }
}
|
43d5c1dfb98f61b6792e5f4b86336e7c5d2a5470
|
035660e8cc10571ebbd0d4393fef063bb7eb98f6
|
/src/overlays/actors/ovl_Bg_Dblue_Movebg/z_bg_dblue_movebg.h
|
6e81c24c1ebc90414dc665825c8d8a66c43023e2
|
[] |
no_license
|
zeldaret/mm
|
f163a5e7c4314105777369fa7671ce9c2a99922a
|
4ae00e909e74044f05155683b49d2561f91de7ba
|
refs/heads/master
| 2023-08-06T07:22:04.912966
| 2023-08-04T20:36:03
| 2023-08-04T20:36:03
| 247,875,852
| 915
| 328
| null | 2023-09-14T11:48:59
| 2020-03-17T04:03:07
|
C
|
UTF-8
|
C
| false
| false
| 1,744
|
h
|
z_bg_dblue_movebg.h
|
#ifndef Z_BG_DBLUE_MOVEBG_H
#define Z_BG_DBLUE_MOVEBG_H
#include "global.h"
struct BgDblueMovebg;
typedef void (*BgDblueMovebgActionFunc)(struct BgDblueMovebg*, PlayState*);
#define BGDBLUEMOVEBG_GET_F(thisx) ((thisx)->params & 0xF)
#define BGDBLUEMOVEBG_GET_FF0(thisx) (((thisx)->params >> 4) & 0xFF)
#define BGDBLUEMOVEBG_GET_F000(thisx) (((thisx)->params >> 0xC) & 0xF)
#define BGDBLUEMOVEBG_F_8 8
typedef struct BgDblueMovebg {
/* 0x000 */ DynaPolyActor dyna;
/* 0x15C */ BgDblueMovebgActionFunc actionFunc;
/* 0x160 */ s32 unk_160;
/* 0x164 */ Gfx* opaDList;
/* 0x168 */ Gfx* xluDList;
/* 0x16C */ AnimatedMaterial* texAnim;
/* 0x170 */ s8 unk_170;
/* 0x171 */ s8 unk_171;
/* 0x172 */ u16 unk_172;
/* 0x174 */ u16 unk_174;
/* 0x178 */ s32 unk_178;
/* 0x17C */ UNK_TYPE1 unk17C[2];
/* 0x17E */ s16 unk_17E;
/* 0x180 */ s16 unk_180;
/* 0x184 */ f32 unk_184;
/* 0x188 */ s16 unk_188;
/* 0x18A */ s16 unk_18A;
/* 0x18C */ s16 unk_18C;
/* 0x18E */ s16 unk_18E;
/* 0x190 */ Vec3f unk_190;
/* 0x19C */ Vec3f unk_19C;
/* 0x1A8 */ Vec3f unk_1A8;
/* 0x1B4 */ UNK_TYPE1 unk1B4[2];
/* 0x1B6 */ s16 csIdList[2];
/* 0x1BC */ s32 unk_1BC;
/* 0x1C0 */ s32 unk_1C0;
/* 0x1C4 */ s32 unk_1C4;
/* 0x1C8 */ s32 unk_1C8;
/* 0x1CC */ s16 unk_1CC;
/* 0x1CE */ s16 unk_1CE;
/* 0x1D0 */ s16 unk_1D0;
/* 0x1D2 */ s16 csId;
/* 0x1D4 */ f32 unk_1D4;
/* 0x1D8 */ s16 unk_1D8[2][8];
/* 0x1F8 */ f32 unk_1F8[2][8];
/* 0x238 */ Vec3f unk_238[2][8];
/* 0x2F8 */ Actor* unk_2F8[2];
/* 0x300 */ u8 unk_300[2][8];
/* 0x310 */ UNK_TYPE1 unk310[0x60];
} BgDblueMovebg; // size = 0x370
#endif // Z_BG_DBLUE_MOVEBG_H
|
0746a32422220a16797e0493b08a0856128a3605
|
3a30cfb29aac91e5c75d4dbcefddfd1f34d5f18c
|
/c-tests/gcc/950503-1.c
|
22f4651d52c7990b370f95332a098aeeb40f22ff
|
[
"MIT",
"MPL-1.0",
"LicenseRef-scancode-warranty-disclaimer",
"Apache-2.0",
"LGPL-2.0-only",
"GPL-3.0-only",
"GPL-2.0-only"
] |
permissive
|
vnmakarov/mir
|
a1725bc9c828e8580df6b7ae94e04175db8abe93
|
928e28fb3acaa50d051a906e76a55cc48a556574
|
refs/heads/master
| 2023-09-02T11:10:37.434581
| 2023-08-25T19:25:40
| 2023-08-25T19:25:40
| 178,932,492
| 2,005
| 156
|
MIT
| 2023-08-01T20:29:59
| 2019-04-01T19:24:56
|
C
|
UTF-8
|
C
| false
| false
| 237
|
c
|
950503-1.c
|
extern void exit (int);
main ()
{
int tmp;
unsigned long long utmp1, utmp2;
tmp = 16;
utmp1 = (~((unsigned long long) 0)) >> tmp;
utmp2 = (~((unsigned long long) 0)) >> 16;
if (utmp1 != utmp2)
abort ();
exit (0);
}
|
c65be8254d1c43afb2c88f82ebdb26b378fddbdb
|
b4c2b8dc89417e966a67a433267ebb9c156dbff4
|
/src/vehicles/sounds/PostAutoHorn.h
|
15128644eff891f123704968b4010ba8f9e45279
|
[] |
no_license
|
TheDIYGuy999/Rc_Engine_Sound_ESP32
|
92134030dbc047627310d54ccf1fd34fb3cad791
|
eeeb47964861b66f8e1db34bffe35657846d8b20
|
refs/heads/master
| 2023-08-31T00:17:03.698027
| 2023-05-04T19:46:51
| 2023-05-04T19:46:51
| 225,658,413
| 230
| 105
| null | 2023-08-26T14:38:39
| 2019-12-03T15:51:13
|
C
|
UTF-8
|
C
| false
| false
| 313,902
|
h
|
PostAutoHorn.h
|
const unsigned int sirenSampleRate = 22050;
const unsigned int sirenSampleCount = 70672;
const signed char sirenSamples[] = {
0, -2, -5, -12, -19, -23, -14, -22, -26, -11, -5, -19, -30, -26, -20, 4,
14, 7, 24, 16, -1, -5, 0, 13, 10, 26, 53, 43, 5, 8, 11, 4,
19, 30, 20, 10, 8, 9, 4, 11, -2, -3, 4, -15, -14, -1, -15, -14,
-14, -12, -6, -14, -18, -24, -28, -18, -13, -23, -7, -3, -26, -31, -23, -15,
9, 10, 5, 11, -1, -17, -5, 6, -2, 3, 22, 45, 40, 15, 18, 20,
21, 32, 29, 23, 10, 8, 14, 8, 3, -2, -3, -5, -6, -3, -4, -7,
-10, -13, -12, -5, -8, -15, -26, -35, -32, -34, -38, -24, -26, -38, -30, -22,
-9, 3, 13, 23, 16, 6, -1, 9, 15, 8, 9, 19, 36, 33, 15, 18,
16, 16, 32, 33, 18, 13, 16, 17, 11, 1, -1, -2, -9, -9, -14, -29,
-32, -31, -37, -28, -25, -23, -8, 1, -8, -20, -24, -20, -9, -17, -29, -15,
-18, -9, 9, 21, 27, 7, -7, -3, 9, 19, 17, 17, 28, 36, 34, 29,
24, 19, 15, 19, 18, -16, -26, -21, -19, -15, -13, -3, 8, 11, 17, 19,
7, -8, -14, -23, -23, -15, -14, -12, -1, -2, -18, -27, -15, -4, -10, -26,
-25, -11, 8, 20, 33, 39, 24, -12, 4, 18, -2, -17, -27, -37, -27, -16,
-2, 11, 22, 39, 44, 47, 34, 14, 7, -4, -7, 4, 9, -2, 3, 9,
4, 3, -4, -14, -14, -12, -7, -7, -2, 15, 12, 3, -7, -8, 2, -1,
-28, -49, -62, -71, -59, -31, -21, -9, -12, 5, 49, 38, 38, 31, 13, 4,
7, 20, 20, 22, 29, 27, 14, 8, 4, 5, 1, 5, 20, 16, 6, 14,
28, 27, 32, 20, -3, -9, 1, -11, -59, -95, -94, -87, -75, -63, -36, -1,
11, 9, 15, 7, 10, 18, 16, 20, 16, 1, 1, 17, 14, 4, 10, 11,
5, 9, 28, 29, 29, 41, 44, 38, 35, 31, 22, 17, 4, 21, 27, -53,
-93, -93, -95, -75, -37, -20, -2, 5, 23, 15, 1, 20, 18, -8, -17, -8,
-9, -22, -28, -27, -26, -5, 12, 20, 25, 27, 17, 17, 31, 42, 34, 28,
34, 10, 7, 16, 37, 77, -40, -106, -93, -93, -77, -32, -6, 35, 42, 40,
44, 37, 45, 26, 11, -1, -4, -11, -47, -43, -24, -16, -2, -2, 3, 9,
1, -14, 2, 8, 7, -1, 2, 37, 24, 28, 21, 29, 69, -63, -95, -84,
-95, -81, -61, -23, 36, 60, 56, 69, 61, 64, 43, 8, -4, 1, 2, -44,
-36, 17, 42, 27, -4, 12, 19, 2, -13, -6, -1, -2, -2, 7, 26, 15,
21, 2, 20, 65, -17, -100, -94, -104, -79, -66, -24, 53, 43, 30, 75, 73,
63, 40, -4, -27, -12, 3, -40, -8, 32, 35, 31, 17, 28, 26, 13, 11,
-5, -3, 33, 43, 34, 52, 34, 15, 1, 15, 62, -24, -105, -90, -101, -82,
-87, -98, 37, 22, 12, 72, 66, 60, 35, -19, -49, -10, 27, -50, -13, 29,
22, 16, 5, 24, 36, 16, -10, -17, 5, 30, 41, 54, 68, 48, 18, 1,
28, 64, -24, -102, -97, -96, -57, -81, -98, 12, 14, 14, 72, 65, 67, 28,
-44, -78, -13, 14, -63, -22, 8, -15, -17, -10, 12, 37, 29, -3, -22, 5,
25, 32, 44, 69, 48, 15, 15, 35, 71, -20, -106, -92, -94, -46, -76, -100,
19, 42, 29, 70, 67, 68, 74, -34, -70, -15, -8, -70, -24, 16, -21, -40,
-26, 2, 15, -1, -17, -21, -1, 1, 25, 38, 60, 50, 14, 10, 31, 73,
0, -96, -97, -88, -60, -94, -99, 21, 71, 35, 65, 74, 76, 66, -24, -52,
3, 11, -62, -61, 28, -6, -19, 4, 28, 33, -3, -33, -31, 2, -1, 35,
32, 58, 59, -6, -16, 20, 67, 4, -100, -98, -88, -83, -98, -87, 23, 71,
54, 75, 66, 65, 75, 18, -77, -4, 10, -68, -71, -1, -12, -8, 18, 40,
48, 5, -18, -16, 7, 21, 48, 44, 63, 55, 3, -13, -12, 75, 20, -98,
-104, -92, -83, -99, -89, 23, 65, 39, 80, 66, 54, 62, 8, -76, -3, 6,
-69, -69, 4, -19, -7, 37, 30, 23, 16, -17, -12, 3, 8, 43, 58, 60,
60, 12, 2, 3, 69, 36, -83, -100, -93, -96, -90, -93, 19, 63, 20, 77,
64, 39, 67, 22, -85, -24, -14, -78, -85, -18, -5, -10, 32, 15, 11, 17,
-15, -19, 1, 18, 47, 65, 65, 68, 2, -18, 9, 41, 47, -74, -105, -87,
-99, -90, -86, 24, 80, 41, 61, 73, 38, 66, 38, -75, -55, -13, -82, -97,
-41, -13, -10, 38, 21, -2, 2, -6, -35, -14, 7, 38, 63, 56, 64, 1,
-12, 13, 30, 70, -43, -104, -89, -95, -90, -97, 6, 78, 48, 54, 74, 24,
62, 53, -57, -60, 3, -64, -93, -30, 4, -8, 57, 18, -6, 15, -1, -38,
-14, -4, 23, 65, 58, 70, 3, -20, 17, 32, 76, -34, -102, -85, -97, -92,
-94, -18, 74, 41, 34, 75, 23, 61, 60, -54, -76, -12, -59, -101, -30, 35,
8, 35, 29, -8, 14, 8, -23, 13, 12, 24, 68, 56, 64, 7, -14, 36,
23, 52, -9, -102, -91, -98, -93, -91, -40, 69, 47, 29, 72, 27, 38, 73,
-28, -86, -32, -48, -100, -42, 25, 9, 40, 23, -13, 7, 5, -17, -15, 11,
24, 68, 56, 50, 31, -2, 46, 37, 49, 71, -81, -96, -96, -85, -87, -108,
57, 44, 10, 63, 26, 28, 73, -9, -86, -58, -24, -96, -58, 13, -2, 32,
57, -16, 12, 0, -31, -21, 16, 25, 65, 58, 51, 62, -20, 39, 38, 28,
74, -9, -95, -94, -95, -85, -103, 64, 65, 16, 69, 47, 7, 86, 9, -83,
-75, -44, -81, -61, 14, -9, 20, 57, -32, -15, -4, -13, -15, 6, 17, 59,
62, 38, 58, 9, 31, 41, 7, 68, 26, -98, -96, -96, -80, -100, -30, 73,
25, 67, 66, 18, 59, 26, -75, -86, -40, -58, -55, 31, -1, 10, 70, 9,
-38, -24, -6, -5, -7, 14, 63, 61, 13, 50, 26, 17, 49, 13, 61, 32,
-81, -94, -95, -74, -89, -47, 75, 18, 44, 82, 42, 59, 38, -74, -97, -45,
-54, -84, 54, 29, 2, 61, 27, -42, -22, 13, 6, 7, 20, 46, 73, 15,
37, 30, -26, 52, 12, 46, 39, -81, -93, -97, -90, -88, -59, 57, 25, 26,
86, 47, 48, 80, -65, -102, -44, -35, -82, 25, 35, 13, 60, 32, -39, -33,
4, 9, 16, 21, 15, 84, 12, 21, 51, -15, 50, 23, 46, 57, -63, -101,
-90, -88, -100, -93, 34, 73, 3, 63, 50, 48, 80, -49, -104, -53, -22, -62,
-42, 36, 18, 49, 32, -39, -48, 26, 34, 20, 20, 3, 83, 25, 16, 62,
-20, 0, 20, 35, 69, -49, -104, -89, -100, -102, -93, 28, 75, -8, 63, 63,
44, 81, 35, -97, -82, -39, -56, -54, 30, 6, 41, 41, -43, -61, 27, 50,
28, 18, -3, 45, 32, 3, 58, -7, 4, 40, 38, 74, -33, -98, -90, -99,
-88, -102, 6, 80, -8, 58, 73, 41, 76, 41, -92, -81, -30, -50, -68, 20,
24, 29, 44, -25, -56, -15, 34, 14, 13, 2, 33, 41, -1, 53, 3, -17,
54, 45, 81, -10, -93, -90, -105, -77, -101, -6, 99, 14, 36, 73, 39, 69,
53, -51, -77, -28, -49, -74, 10, 53, 21, 62, -6, -75, -24, 62, 23, 15,
21, 28, 64, -6, 32, 14, -21, 39, 22, 70, 14, -99, -94, -95, -82, -96,
-27, 84, 32, 1, 77, 40, 67, 74, -29, -95, -28, -36, -70, -7, 47, 7,
55, 5, -74, -33, 50, 22, 16, 31, 22, 66, 25, 7, 29, -17, 23, 37,
69, 20, -84, -94, -96, -90, -100, -41, 67, 23, -17, 86, 48, 57, 82, -6,
-91, -43, -40, -80, -13, 58, 9, 55, 17, -75, -54, 43, 41, 25, 44, 24,
58, 28, 11, 36, -22, 22, 36, 41, 38, -81, -98, -96, -92, -105, -54, 69,
32, -16, 65, 52, 58, 83, 8, -85, -88, -26, -66, -37, 43, 12, 46, 35,
-68, -68, 31, 59, 25, 54, 37, 70, 49, -22, 26, -17, 12, 33, 44, 47,
-78, -96, -97, -99, -78, -81, 51, 50, -28, 47, 81, 44, 90, 32, -75, -85,
-24, -77, -54, 50, 27, 10, 46, -59, -60, 21, 45, 27, 43, 19, 57, 60,
-12, 38, -17, -9, 35, 40, 78, -51, -94, -92, -105, -84, -97, 38, 69, -18,
41, 87, 41, 86, 32, -64, -83, -34, -66, -72, 31, 25, -7, 55, -33, -64,
-2, 48, 33, 35, 30, 56, 74, 9, 27, -7, -12, 39, 39, 78, -46, -107,
-93, -108, -86, -99, 15, 86, -5, 14, 77, 49, 84, 54, -52, -93, -26, -54,
-66, 36, 36, -1, 51, -26, -77, -22, 45, 45, 43, 31, 40, 76, 19, 16,
1, -21, 33, 36, 55, 21, -106, -86, -89, -83, -95, -66, 86, -2, 4, 77,
41, 71, 64, -34, -94, -30, -10, -78, 30, 43, 6, 47, 24, -69, -38, 40,
57, 49, 53, 43, 69, 21, 11, 24, -33, 20, 32, 65, 46, -73, -99, -92,
-77, -87, -61, 88, 2, 0, 70, 29, 33, 84, -8, -94, -50, -18, -80, 15,
43, 4, 40, 37, -76, -44, 38, 56, 44, 49, 39, 70, 38, 16, 24, -18,
11, 22, 63, 57, -69, -93, -89, -92, -93, -85, 40, 14, -14, 79, 43, 23,
81, -15, -88, -51, -13, -60, 6, 44, 3, 30, 47, -32, -43, 33, 54, 43,
42, 39, 75, 32, 8, 36, -17, 16, 30, 51, 55, -60, -113, -80, -75, -87,
-85, 41, 29, -25, 77, 68, 10, 64, 3, -91, -62, -31, -75, -46, 45, 1,
15, 49, -22, -64, 30, 59, 39, 56, 47, 68, 42, 2, 32, -1, -19, 21,
51, 73, -39, -117, -81, -82, -93, -93, 19, 91, -14, 58, 70, 21, 67, 65,
-83, -58, -24, -67, -47, 44, 3, 21, 62, 1, -63, 3, 39, 35, 47, 42,
53, 60, -2, 21, 3, -26, 31, 47, 74, -19, -110, -88, -89, -84, -92, -2,
94, 12, 53, 72, 21, 60, 60, -80, -69, -20, -63, -60, 31, 3, 26, 63,
2, -59, -34, 48, 32, 42, 50, 44, 59, 7, 35, 21, -26, 9, 19, 75,
5, -110, -90, -87, -84, -90, -24, 92, 32, 48, 75, 8, 49, 75, -20, -75,
-26, -42, -53, 11, 10, 24, 61, 6, -60, -47, 42, 42, 42, 57, 53, 74,
13, 19, 24, -26, 2, 18, 64, 37, -95, -111, -88, -89, -93, -45, 79, 35,
-24, 78, 21, 44, 83, 1, -87, -37, -36, -55, -4, 21, 20, 49, 12, -49,
-50, 20, 50, 36, 60, 60, 74, 26, 15, 17, -21, 5, 14, 53, 57, -68,
-119, -100, -92, -97, -56, 71, 46, -14, 85, 35, 38, 75, 15, -76, -47, -43,
-63, -21, 4, 1, 49, 22, -50, -64, 5, 45, 35, 56, 62, 77, 55, 16,
21, -18, 1, 17, 15, 64, -43, -111, -100, -90, -98, -80, 52, 59, -15, 48,
34, 35, 77, 27, -66, -74, -39, -57, -15, 14, 3, 55, 36, -42, -68, 3,
62, 23, 38, 52, 66, 58, 12, 17, -19, -13, 17, 7, 74, -1, -93, -94,
-88, -82, -94, 30, 69, -10, 41, 42, 35, 78, 34, -53, -72, -41, -58, -32,
7, 4, 24, 52, -28, -63, -1, 49, 34, 45, 41, 61, 67, 6, 28, -1,
-22, 27, 12, 32, 23, -82, -93, -97, -91, -99, -12, 68, 1, 26, 80, 36,
77, 59, -43, -93, -54, -48, -28, 9, 5, 24, 61, -24, -67, -4, 53, 41,
37, 35, 55, 73, 10, -1, 21, -17, 17, 8, 18, 51, -66, -100, -97, -92,
-91, -36, 59, 12, 7, 68, 44, 65, 70, -27, -93, -60, -57, -41, 5, 8,
14, 61, -12, -75, -26, 46, 46, 36, 46, 42, 70, 23, -14, 21, -17, 20,
14, -5, 69, -42, -103, -103, -98, -84, -93, 38, 21, -3, 61, 69, 71, 74,
1, -85, -70, -40, -47, -4, -2, -2, 48, 39, -71, -39, 41, 49, 25, 46,
31, 66, 42, -18, 17, -9, 13, 24, -11, 54, 0, -99, -111, -100, -87, -103,
-1, 25, -4, 40, 70, 67, 71, 24, -73, -84, -39, -50, -12, 4, 4, 51,
52, -67, -42, 37, 58, 33, 39, 30, 55, 43, -21, 10, -8, 7, 35, -17,
24, 63, -80, -98, -97, -88, -96, -72, 13, -5, 42, 79, 68, 71, 33, -57,
-89, -53, -51, -14, -9, -6, 40, 50, -17, -61, 21, 67, 44, 49, 31, 49,
60, -10, -5, 13, -9, 46, 0, 0, 72, 9, -100, -106, -95, -87, -85, 5,
-7, 19, 73, 72, 75, 57, -24, -84, -63, -59, -44, -4, -8, 37, 48, -6,
-67, 0, 64, 41, 47, 51, 24, 69, 6, -17, 14, -19, 49, 21, -8, 64,
41, -95, -106, -97, -87, -96, -46, -7, 8, 70, 86, 74, 66, -4, -84, -75,
-62, -52, -8, -16, 38, 65, 15, -51, -7, 58, 38, 39, 57, 19, 68, 22,
-18, 17, -26, 37, 44, -23, 31, 68, -38, -109, -90, -87, -101, -71, -9, 3,
56, 80, 78, 75, 28, -65, -82, -56, -52, -22, -6, 30, 44, 26, -39, -53,
51, 53, 25, 49, 31, 58, 36, -10, 23, -7, -5, 56, -27, 18, 82, -9,
-95, -97, -95, -93, -98, -56, 4, 50, 74, 75, 69, 62, -38, -94, -64, -47,
-32, -7, 23, 38, 36, -15, -77, 48, 64, 34, 56, 33, 9, 52, -15, -17,
-5, -10, 60, -7, -8, 70, 33, -71, -100, -80, -85, -101, -68, -26, 36, 74,
72, 70, 70, -3, -87, -84, -48, -28, -5, 16, 20, 35, -3, -85, -34, 77,
33, 49, 55, 8, 49, 9, -17, 9, -3, 38, 22, -19, 53, 61, -39, -96,
-97, -93, -96, -93, -50, 36, 69, 76, 76, 71, 57, -67, -108, -52, -35, -35,
27, 11, 27, 31, -53, -55, 81, 52, 30, 59, 24, 6, 24, -22, -1, 3,
23, 38, -21, 32, 73, -17, -90, -86, -89, -91, -95, -61, -3, 59, 79, 78,
71, 63, -39, -114, -75, -31, -36, 8, 10, 15, 35, -42, -63, 29, 59, 26,
59, 30, -12, 47, -17, -2, 16, 5, 55, -18, -4, 80, 30, -74, -91, -80,
-80, -94, -79, -8, 43, 60, 80, 75, 60, 36, -92, -94, -27, -31, -16, 27,
8, 34, -21, -71, 0, 65, 29, 52, 45, -23, 13, -12, -14, 24, 4, 48,
63, -17, 56, 62, -50, -102, -80, -76, -88, -95, -31, 31, 61, 82, 73, 67,
52, -24, -103, -33, -19, -30, 24, 1, 20, 4, -72, -29, 69, 38, 40, 62,
-8, -7, 33, -38, 11, 1, 6, 60, -18, 23, 82, -6, -94, -87, -78, -79,
-95, -50, 21, 50, 77, 76, 64, 64, 17, -109, -64, -12, -31, 2, 28, 6,
19, -49, -48, 45, 43, 29, 57, 9, -31, 23, -30, 1, 24, 4, 66, 52,
-11, 72, 31, -83, -97, -85, -81, -93, -80, 1, 41, 70, 87, 64, 61, 39,
-55, -78, -17, -24, -10, 24, -7, 12, -28, -53, 28, 68, 26, 63, 40, -33,
6, 21, -19, 14, -18, 29, 69, -29, 42, 64, -42, -96, -82, -80, -91, -90,
-22, 27, 41, 83, 71, 69, 59, -22, -101, -35, -28, -33, 18, 9, 6, -1,
-45, -1, 64, 40, 40, 62, -19, -21, 22, -24, 26, -5, 9, 79, 15, 12,
73, -1, -86, -85, -77, -86, -101, -46, 24, 26, 78, 79, 64, 65, 10, -87,
-49, -9, -41, -5, 18, -16, 20, -17, -23, 47, 60, 20, 70, 8, -44, 18,
-20, 2, 2, -20, 64, 45, -8, 74, 36, -78, -97, -84, -80, -94, -69, 19,
34, 43, 84, 70, 72, 27, -70, -78, -22, -37, -19, 22, -7, 24, 6, -29,
24, 66, 28, 68, 38, -39, 17, 6, -5, 22, -36, 34, 65, -26, 52, 75,
-44, -102, -83, -88, -88, -93, -2, 46, 29, 86, 64, 66, 52, -41, -99, -27,
-34, -33, 18, -3, -11, 26, -30, -1, 53, 30, 49, 52, -26, -1, 20, -37,
35, -24, 3, 76, 6, -15, 91, 6, -96, -86, -81, -83, -100, -47, 34, 23,
52, 70, 65, 67, -6, -79, -73, -23, -29, -1, 5, -11, 31, -16, -14, 55,
55, 32, 64, -10, -25, 16, -29, -1, -13, -35, 60, 36, -21, 82, 50, -65,
-94, -87, -83, -103, -74, 34, 36, 39, 87, 57, 81, 32, -67, -87, -45, -44,
-24, -6, -15, 11, -2, -22, 37, 59, 35, 74, 23, -33, 3, -5, -8, 10,
-28, 46, 65, -7, 11, 77, -26, -98, -91, -79, -90, -101, 0, 44, 21, 71,
65, 73, 57, -26, -86, -70, -24, -33, -7, 0, -4, 17, -26, 6, 64, 42,
41, 49, -37, -27, 5, -18, 5, -28, 16, 81, 29, -1, 93, 23, -81, -94,
-86, -66, -110, -44, 44, 20, 49, 79, 66, 78, 14, -76, -96, -25, -41, -23,
5, -13, 16, -9, -14, 57, 57, 33, 75, -5, -48, 6, -1, -8, -15, -6,
68, 60, 6, 40, 62, -53, -99, -90, -69, -75, -79, 35, 34, 35, 84, 57,
82, 44, -48, -104, -70, -35, -45, 9, -6, -7, 38, -24, 26, 64, 33, 55,
24, -63, -15, 23, -13, -8, -21, 40, 74, 20, 19, 83, -6, -87, -90, -80,
-66, -108, -4, 48, 21, 70, 70, 76, 66, -18, -88, -86, -20, -49, -9, 10,
-17, 28, -12, 2, 60, 39, 41, 75, -49, -42, 23, 1, -7, -22, 16, 75,
38, 4, 60, 42, -69, -93, -82, -71, -97, -54, 42, 27, 57, 83, 72, 90,
13, -75, -99, -46, -50, -44, 7, -17, -1, 22, -20, 44, 56, 37, 71, -16,
-65, 0, 10, -9, -6, -3, 60, 61, 14, 28, 81, -32, -95, -83, -71, -83,
-94, 24, 47, 36, 86, 76, 84, 52, -46, -105, -66, -25, -51, 7, 0, -7,
34, -17, 18, 63, 49, 60, 59, -66, -33, 2, -19, -14, -20, 35, 73, 33,
12, 65, 5, -85, -91, -83, -74, -100, -29, 49, 32, 64, 86, 71, 65, -17,
-95, -91, -33, -59, -17, 17, -10, 20, 21, -7, 49, 58, 53, 73, 11, -55,
6, 3, -9, -16, 15, 70, 56, 11, 43, 83, -66, -96, -85, -81, -86, -73,
33, 43, 39, 84, 77, 69, 15, -67, -101, -51, -29, -48, 22, 4, 0, 33,
-13, 29, 62, 42, 66, 46, -73, -16, 3, -8, -9, -24, 53, 63, 14, 20,
82, -25, -90, -82, -83, -78, -101, -8, 45, 31, 72, 77, 63, 37, -42, -99,
-76, -21, -59, 3, 17, -10, 34, 17, 9, 69, 52, 54, 66, -29, -35, 6,
-4, 3, -14, 34, 70, 30, 1, 57, 66, -82, -90, -79, -76, -89, -83, 36,
38, 64, 84, 62, 60, -14, -86, -93, -35, -37, -24, 23, -24, 5, 26, -28,
55, 60, 44, 76, 11, -55, 4, -3, -2, -5, -11, 73, 52, -2, 31, 82,
4, -97, -81, -72, -80, -101, 12, 41, 48, 84, 71, 70, 17, -68, -100, -52,
-27, -55, 29, -2, -8, 39, -6, 32, 68, 38, 65, 46, -56, -17, -6, -13,
-5, -24, 55, 73, 16, 14, 75, 42, -93, -93, -76, -70, -100, -73, 36, 42,
72, 76, 67, 42, -40, -98, -82, -36, -50, 9, 18, -16, 32, 21, -18, 65,
42, 45, 66, -20, -36, 7, -8, 4, -11, -7, 84, 40, 4, 58, 70, -29,
-94, -82, -69, -86, -94, 24, 46, 62, 78, 70, 73, -12, -82, -94, -53, -44,
-51, 24, -7, 14, 40, -6, 59, 57, 33, 67, 13, -74, -1, -9, 0, 6,
-18, 41, 62, 6, 33, 79, 7, -94, -85, -75, -73, -98, -50, 52, 56, 73,
70, 69, 46, -67, -98, -70, -38, -47, 17, 13, 4, 40, 8, 4, 70, 35,
59, 49, -57, -52, -1, -11, 15, -7, 17, 77, 17, 11, 70, 43, -61, -89,
-76, -65, -92, -83, 15, 56, 69, 76, 71, 69, -47, -95, -82, -48, -52, -39,
19, -5, 26, 18, -12, 71, 45, 43, 72, -15, -71, 5, -11, 6, 4, 6,
66, 43, 2, 48, 71, -27, -98, -74, -61, -84, -99, -17, 58, 59, 69, 67,
78, 28, -87, -83, -51, -47, -48, 26, 6, 13, 35, -2, 21, 61, 27, 62,
24, -69, -36, -9, -6, 1, -8, 40, 64, 12, 18, 78, 22, -89, -82, -69,
-75, -97, -55, 31, 64, 72, 64, 71, 59, -64, -83, -60, -43, -47, -13, 5,
-5, 37, 9, -3, 59, 33, 48, 51, -40, -47, 6, -4, 8, -6, 23, 68,
24, 2, 58, 56, -57, -102, -80, -78, -91, -83, -1, 65, 74, 70, 63, 67,
8, -84, -72, -46, -47, -27, 18, -14, 34, 33, -9, 45, 44, 33, 64, -9,
-63, -5, -3, 10, -5, -3, 56, 66, -10, 35, 83, -19, -97, -81, -85, -83,
-91, -39, 42, 72, 72, 63, 69, 27, -82, -80, -62, -54, -41, 9, -12, 19,
51, -7, 22, 76, 17, 63, 28, -65, -21, 7, 9, 9, -9, 41, 77, 0,
9, 78, 16, -93, -94, -86, -83, -89, -59, 28, 73, 75, 72, 75, 52, -37,
-81, -60, -52, -54, -5, 24, -2, 49, 4, -5, 69, 9, 41, 61, -45, -48,
17, 8, 14, -15, 15, 73, 54, -5, 65, 58, -61, -97, -87, -80, -85, -82,
-5, 63, 74, 66, 65, 66, -7, -80, -66, -47, -52, -24, 31, 0, 48, 30,
-13, 57, 64, 19, 73, -13, -73, 0, 12, 11, -9, -3, 60, 67, -13, 38,
79, -27, -101, -85, -81, -85, -97, -40, 51, 73, 72, 66, 74, 30, -63, -70,
-46, -51, -41, 23, 18, 24, 44, -18, 23, 74, 18, 66, 36, -65, -24, 27,
12, 1, -11, 43, 77, 21, 11, 81, 12, -91, -90, -86, -84, -98, -76, 23,
74, 71, 70, 75, 58, -35, -85, -58, -59, -50, 4, 22, 8, 52, 4, -2,
68, 46, 46, 66, -38, -53, 21, 18, 4, -12, 25, 78, 43, -5, 75, 48,
-70, -95, -80, -82, -91, -91, -4, 73, 70, 71, 77, 74, -6, -88, -63, -60,
-63, -16, 32, 9, 42, 24, -14, 45, 59, 8, 74, 5, -64, 1, 29, 12,
-7, 6, 70, 61, -3, 52, 69, -33, -97, -91, -84, -86, -102, -32, 61, 70,
74, 72, 80, 30, -69, -87, -61, -60, -34, 17, 19, 10, 31, -14, 15, 61,
20, 56, 37, -53, -17, 30, 16, 0, -10, 50, 67, 12, 8, 77, 6, -88,
-96, -80, -81, -99, -55, 45, 72, 66, 74, 76, 49, -44, -91, -74, -63, -45,
5, 28, 8, 39, 1, -6, 62, 45, 8, 62, -31, -50, 22, 24, -1, -13,
25, 65, 33, -1, 71, 39, -73, -101, -78, -76, -96, -79, 18, 72, 62, 75,
73, 66, -11, -85, -72, -65, -55, -1, 30, 9, 19, 13, -18, 41, 61, 9,
60, 5, -60, 3, 33, 11, -11, 10, 61, 52, 10, 25, 61, -44, -107, -83,
-72, -92, -88, -9, 60, 66, 72, 65, 78, 24, -79, -83, -55, -70, -23, 28,
18, 10, 24, -15, 18, 70, 27, 19, 42, -51, -28, 31, 15, -6, -10, 44,
58, 13, 10, 69, -14, -100, -90, -71, -76, -94, -32, 50, 67, 69, 72, 73,
48, -54, -95, -59, -76, -44, 18, 26, 4, 23, -1, 0, 65, 47, 10, 60,
-28, -45, 24, 25, 2, -20, 30, 66, 24, 5, 56, 12, -86, -97, -78, -77,
-91, -59, 29, 66, 69, 69, 70, 66, -26, -95, -64, -60, -60, 3, 24, 2,
18, 4, -11, 52, 60, 10, 45, 0, -57, 7, 25, 4, -8, 9, 65, 42,
-2, 37, 43, -70, -103, -76, -75, -91, -70, 10, 61, 73, 72, 61, 72, 0,
-94, -78, -55, -73, -12, 29, 6, 9, 32, -19, 33, 70, 20, 29, 62, -47,
-14, 28, 9, -5, -9, 53, 54, 2, 23, 74, -48, -103, -84, -80, -85, -91,
-17, 49, 73, 77, 64, 77, 34, -75, -91, -54, -71, -30, 30, 19, 0, 34,
4, -1, 69, 30, 12, 64, -18, -27, 26, 24, 4, -20, 33, 61, 11, 10,
72, 37, -97, -91, -88, -87, -93, -40, 30, 64, 76, 69, 68, 58, -41, -93,
-59, -61, -73, 16, 29, -8, 25, 22, -23, 60, 45, 2, 52, 51, -32, 12,
34, 16, -18, -17, 62, 29, 4, 61, 62, -86, -96, -87, -85, -92, -81, 10,
55, 77, 68, 66, 72, -19, -91, -65, -59, -81, 4, 35, -7, 12, 32, -33,
42, 61, 3, 33, 61, -32, -5, 33, 24, -4, -20, 48, 45, 7, 41, 77,
-9, -103, -88, -82, -92, -89, -5, 41, 73, 75, 62, 77, 11, -81, -74, -50,
-78, -56, 44, 2, -2, 38, -24, 16, 67, 11, 20, 65, 13, -14, 24, 22,
6, -20, 3, 52, 13, 26, 75, 17, -101, -87, -77, -85, -89, -49, 26, 68,
82, 66, 73, 71, -67, -89, -55, -75, -76, 38, 13, -14, 41, -2, -47, 74,
31, 11, 68, 40, -28, 18, 25, 8, -17, -7, 51, 19, 18, 74, 39, -72,
-93, -78, -86, -92, -57, -7, 59, 80, 72, 72, 75, -39, -86, -55, -62, -81,
-14, 33, -14, 36, 23, -49, 16, 40, -1, 52, 53, -21, 8, 30, 18, -8,
-8, 42, 29, 11, 65, 60, -50, -100, -78, -87, -101, -72, -25, 42, 76, 73,
70, 78, 33, -86, -66, -53, -77, -37, 44, -12, 18, 37, -45, -9, 60, 0,
37, 71, 2, -20, 36, 27, -6, -18, 23, 29, 3, 47, 75, -21, -102, -81,
-84, -99, -75, -28, 11, 73, 73, 74, 80, 45, -75, -80, -58, -70, -55, 21,
6, 0, 36, -30, -36, 51, 10, 28, 76, 25, -19, 26, 29, -2, -18, 18,
44, 9, 38, 81, 6, -94, -96, -83, -100, -85, -42, -6, 63, 73, 66, 78,
63, -17, -74, -55, -56, -54, 5, 41, -6, 33, -12, -53, 30, 15, 7, 68,
44, -13, 1, 33, 5, -19, 8, 27, 20, 34, 74, 32, -72, -96, -79, -92,
-88, -53, -15, 33, 74, 69, 75, 72, 6, -67, -68, -70, -66, -17, 38, -9,
26, 14, -49, 9, 53, 7, 62, 60, -1, -4, 32, 13, -24, -7, 22, 16,
22, 69, 55, -58, -101, -75, -90, -92, -63, -27, 24, 80, 66, 70, 83, 26,
-57, -64, -69, -67, -26, 35, 20, 16, 28, -43, -16, 47, 0, 50, 68, 4,
-11, 18, 26, -10, -9, 20, 25, 23, 58, 72, -27, -108, -91, -82, -97, -76,
-37, 7, 62, 68, 59, 75, 48, -39, -77, -69, -61, -33, 22, 36, 5, 33,
-25, -37, 37, 32, 34, 78, 28, -12, 11, 36, 1, -16, 15, 23, 16, 48,
75, -4, -97, -97, -77, -88, -76, -43, -2, 55, 76, 59, 69, 56, -18, -74,
-79, -64, -37, 4, 32, 5, 26, -13, -49, 17, 37, 10, 75, 41, -6, 8,
33, 17, -15, 7, 25, 16, 20, 78, 23, -86, -104, -78, -82, -85, -52, -17,
42, 76, 61, 69, 67, 4, -62, -75, -64, -41, -4, 33, 11, 24, 1, -59,
-7, 38, 8, 68, 55, 0, 7, 34, 42, -14, -1, 19, 10, 17, 74, 44,
-64, -104, -77, -79, -92, -64, -30, 30, 76, 70, 71, 73, 21, -50, -75, -68,
-43, -12, 26, 18, 4, 12, -52, -22, 39, 15, 31, 64, 9, 4, 26, 41,
-11, -10, 18, 12, 18, 51, 61, -43, -105, -78, -73, -99, -72, -41, 9, 69,
76, 63, 74, 41, -33, -71, -75, -44, -21, 15, 24, 6, 27, -42, -37, 35,
25, 19, 69, 19, 0, 15, 38, 25, -15, 15, 12, 18, 45, 75, -19, -105,
-89, -70, -92, -81, -49, -5, 55, 79, 69, 71, 54, -15, -71, -87, -68, -28,
-2, 26, 12, 24, -20, -48, 18, 32, 11, 54, 39, 8, 16, 41, 39, -11,
11, 13, 10, 34, 68, 2, -96, -93, -71, -89, -97, -57, -14, 46, 78, 74,
73, 61, -2, -61, -88, -78, -26, -12, 24, 22, 21, 20, -50, -2, 30, 8,
43, 49, 7, 11, 43, 52, -4, 2, 14, 8, 28, 65, 68, -84, -100, -72,
-87, -101, -62, -28, 29, 74, 75, 65, 68, 16, -49, -80, -83, -42, -14, 14,
23, 22, 29, -51, -14, 33, 10, 25, 68, 15, 0, 36, 61, 15, -12, 14,
4, 21, 56, 69, -65, -105, -83, -84, -97, -84, -38, 18, 72, 75, 68, 74,
27, -36, -72, -80, -48, -20, 4, 22, 15, 30, -10, -33, 29, 19, 18, 63,
49, 1, 34, 59, 22, -8, 13, -4, 12, 50, 69, 1, -102, -86, -85, -93,
-82, -61, -2, 65, 78, 66, 73, 40, -23, -68, -88, -58, -28, -4, 29, 17,
30, 7, -50, 19, 26, 15, 58, 61, 3, 23, 59, 31, -11, 12, 0, 2,
45, 79, 24, -99, -85, -81, -94, -85, -64, -24, 54, 80, 65, 75, 72, -12,
-54, -83, -69, -27, -15, 23, 16, 24, 20, -43, 8, 23, 8, 50, 62, 22,
23, 55, 46, -8, -1, 7, -4, 37, 79, 42, -64, -95, -81, -91, -87, -60,
-49, 39, 86, 67, 68, 80, -1, -50, -73, -72, -33, -27, 21, 16, 10, 27,
-32, -37, 30, 5, 39, 67, 26, 16, 49, 60, 8, -8, 21, -9, 18, 73,
65, -38, -98, -77, -86, -96, -71, -49, 18, 79, 69, 64, 76, 42, -42, -66,
-70, -30, -22, -11, 21, 7, 28, -19, -44, 30, 9, 22, 63, 35, 1, 44,
63, 20, -12, 14, 11, 2, 56, 78, -15, -99, -76, -79, -97, -82, -51, -30,
69, 81, 68, 80, 57, -8, -58, -78, -41, -23, -23, 22, 3, 28, -7, -53,
2, 18, 18, 60, 48, 2, 44, 70, 26, -11, 18, 21, -6, 38, 82, 12,
-93, -93, -79, -97, -85, -56, -31, 55, 84, 71, 75, 61, 1, -45, -79, -57,
-21, -28, 9, 11, 28, 8, -50, -12, 21, 11, 47, 57, 12, 1, 70, 41,
-15, 7, 30, 1, 27, 77, 36, -74, -101, -76, -93, -85, -59, -37, 8, 83,
69, 70, 75, 13, -32, -66, -66, -23, -26, 1, 9, 15, 17, -41, -28, 27,
16, 31, 57, 28, 0, 38, 58, -5, -3, 32, 7, 10, 67, 54, -52, -107,
-84, -92, -91, -70, -45, 2, 65, 68, 67, 83, 29, -27, -54, -71, -33, -27,
-12, 13, 5, 21, -31, -36, 22, 27, 27, 56, 36, 3, 28, 70, 11, -14,
31, 24, -12, 51, 69, -18, -103, -94, -74, -92, -78, -51, -13, 49, 74, 64,
84, 45, -26, -36, -70, -48, -23, -12, 12, -2, 24, -11, -42, 7, 32, 21,
50, 40, -5, 14, 68, 25, -14, 19, 26, -8, 34, 76, 12, -89, -98, -75,
-91, -80, -51, -19, 38, 76, 62, 84, 53, -21, -32, -61, -55, -26, -15, 12,
-4, 20, 4, -49, -11, 34, 21, 47, 51, 5, 7, 55, 41, -4, 7, 29,
6, -2, 72, 35, -74, -103, -82, -86, -93, -61, -22, 24, 75, 62, 74, 73,
-5, -38, -33, -58, -28, -23, 3, 2, -14, 11, -44, -23, 35, 23, 41, 58,
8, -4, 50, 69, 1, 3, 37, 16, -11, 32, 58, -55, -105, -83, -87, -94,
-74, -28, 20, 61, 76, 69, 80, 17, -34, -28, -59, -36, -22, -2, 10, -13,
23, -33, -38, 26, 25, 14, 59, 14, -14, 38, 69, 34, 3, 36, 27, -9,
16, 71, -29, -100, -84, -84, -93, -85, -40, 16, 52, 73, 64, 76, 30, -30,
-20, -48, -42, -19, -9, 12, -13, 5, -22, -53, 11, 30, 8, 59, 32, -8,
27, 70, 48, -5, 27, 33, -6, -2, 65, -2, -99, -95, -87, -94, -90, -59,
5, 50, 71, 68, 81, 51, -21, -17, -32, -63, -17, -19, 3, -11, -5, -12,
-55, 0, 34, 11, 39, 39, -12, 13, 65, 60, 9, 18, 38, 6, -11, 50,
31, -83, -98, -85, -90, -88, -73, -14, 43, 73, 65, 59, 64, -14, -27, -25,
-63, -20, -21, 4, -1, -10, 20, -45, -14, 31, 14, 30, 59, -8, -2, 54,
65, 15, 8, 42, 22, -13, 28, 85, -65, -109, -84, -83, -88, -93, -26, 35,
71, 70, 60, 78, 1, -26, -16, -62, -46, -22, 1, 0, -23, 18, -8, -36,
25, 14, 15, 52, 2, -4, 51, 77, 31, -11, 35, 27, -13, 12, 80, -38,
-103, -89, -90, -90, -92, -41, 21, 69, 81, 59, 76, 28, -24, -18, -56, -52,
-25, -6, 9, -27, 8, 10, -42, 22, 23, 13, 50, 37, -10, 35, 72, 40,
-12, 30, 33, -11, 0, 75, 50, -98, -92, -86, -88, -90, -74, 9, 59, 85,
65, 68, 45, -23, -14, -38, -59, -24, -11, 8, -29, -9, 20, -41, 11, 32,
7, 42, 46, -18, 24, 69, 54, 0, 1, 40, -3, -9, 61, 67, -46, -103,
-91, -89, -88, -79, -11, 42, 78, 72, 66, 81, -8, -16, -23, -59, -34, -22,
0, -25, -21, 22, -22, -9, 33, 13, 32, 54, 3, 11, 65, 64, 11, -8,
28, 4, -14, 46, 78, -20, -104, -92, -91, -90, -82, -46, 30, 75, 80, 65,
78, 44, -20, -19, -56, -44, -24, -2, -25, -34, 20, -5, -43, 28, 17, 24,
54, 18, 2, 58, 71, 23, -6, 20, 14, -12, 28, 85, 11, -93, -90, -90,
-95, -88, -53, 20, 64, 81, 67, 75, 60, -18, -13, -44, -46, -24, -11, -18,
-44, 11, 8, -44, 20, 15, 14, 54, 30, -11, 43, 73, 37, -6, 13, 26,
-10, 14, 75, 36, -75, -95, -86, -91, -91, -59, -13, 54, 81, 67, 70, 73,
12, -15, -35, -53, -27, -13, -14, -49, -4, 21, -35, -16, 26, 9, 44, 40,
-7, 3, 67, 51, 2, 7, 27, -5, 2, 63, 60, -54, -109, -83, -90, -94,
-60, -16, 17, 77, 73, 63, 73, 29, -15, -21, -53, -34, -13, -3, -43, -18,
29, -24, -33, 24, 11, 32, 41, 1, -1, 63, 60, 11, 4, 26, 12, -3,
49, 74, -21, -102, -95, -87, -95, -75, -29, 11, 73, 76, 65, 75, 44, -11,
-21, -51, -39, -18, -7, -33, -36, 23, -5, -41, 11, 15, 23, 45, 14, -2,
36, 68, 16, -3, 27, 15, -14, 35, 76, 6, -89, -101, -83, -95, -82, -40,
-2, 48, 75, 64, 82, 55, -2, -10, -49, -44, -18, -13, -10, -46, 10, 12,
-42, -6, 36, 13, 37, 23, -6, 20, 68, 27, -5, 23, 24, -15, 20, 78,
29, -73, -100, -85, -95, -90, -47, -12, 28, 84, 67, 76, 64, 6, -3, -41,
-47, -15, -13, -8, -40, -3, 23, -38, -25, 33, 10, 26, 33, 2, 7, 56,
42, -5, 19, 32, -8, -19, 72, 55, -50, -98, -90, -91, -94, -62, -19, 20,
69, 69, 77, 74, 9, -4, -6, -56, -22, -13, -5, -37, -24, 33, -26, -49,
27, 37, 11, 42, 17, 2, 48, 72, 1, 10, 34, 5, -19, 49, 73, -22,
-96, -94, -88, -93, -75, -28, 16, 58, 68, 71, 78, 25, -4, 0, -47, -27,
-19, -5, -19, -59, 27, -2, -49, 10, 45, 2, 37, 26, -6, 32, 75, -1,
-5, 37, 17, -14, 3, 81, 11, -86, -96, -87, -91, -84, -36, 10, 48, 74,
63, 79, 40, -6, 4, -25, -36, -19, -7, -13, -60, 17, 11, -55, -7, 52,
9, 28, 34, -6, 24, 78, 47, -6, 38, 23, -10, -3, 73, 32, -75, -94,
-87, -94, -91, -48, 2, 36, 72, 68, 79, 56, 4, 6, -12, -38, -30, -15,
3, -52, -47, 28, -48, -28, 54, 27, 0, 36, -5, 13, 69, 58, -10, 27,
31, -4, -9, 34, 50, -56, -97, -87, -88, -93, -58, -4, 26, 64, 72, 74,
64, 11, 8, -3, -40, -27, -20, 0, -39, -55, 20, -37, -42, 46, 35, -5,
44, 0, -3, 59, 68, 9, 13, 37, 10, -10, 21, 70, -35, -99, -92, -91,
-91, -70, -13, 20, 58, 77, 60, 70, 23, 8, 2, -38, -23, -27, -9, -30,
-65, 2, -30, -53, 37, 45, -4, 31, 15, -7, 50, 78, 23, 2, 33, 14,
-11, 6, 69, -8, -99, -97, -90, -93, -93, -19, 18, 49, 82, 66, 73, 38,
11, 10, -35, -40, -24, -19, -20, -64, -24, 18, -60, 16, 55, 5, 17, 25,
-6, 36, 76, 31, -11, 29, 16, -2, 3, 60, 70, -86, -96, -93, -97, -94,
-36, 13, 39, 76, 70, 65, 51, 13, 17, -16, -43, -25, -15, -11, -62, -40,
21, -69, -9, 56, 8, 2, 35, -3, 22, 72, 49, -3, 15, 23, 9, 2,
40, 81, -69, -103, -96, -93, -94, -81, 6, 30, 67, 75, 66, 73, 18, 23,
-1, -43, -27, -24, -5, -49, -61, 7, -25, -32, 48, 27, 2, 31, 5, 14,
64, 55, -2, 10, 23, 5, 3, 22, 73, 14, -102, -92, -92, -94, -83, -2,
19, 58, 78, 65, 75, 20, 21, 11, -43, -35, -29, -8, -29, -75, -15, -5,
-50, 34, 41, 1, 23, 31, 1, 47, 60, 6, 0, 33, 13, 8, 15, 72,
40, -96, -92, -96, -91, -86, -43, 8, 47, 81, 63, 74, 58, 19, 21, -29,
-37, -29, -7, -13, -74, -33, 6, -51, 13, 50, 3, 10, 35, 6, 38, 63,
18, -1, 35, 16, 8, 9, 58, 57, -53, -97, -98, -94, -92, -56, -7, 38,
81, 71, 74, 65, 21, 22, -24, -40, -28, -30, -4, -63, -53, 2, -37, -44,
48, 8, 4, 41, 8, 31, 66, 27, -1, 27, 34, 5, 1, 44, 69, -25,
-93, -96, -91, -93, -70, -15, 21, 73, 74, 71, 65, 26, 27, -17, -44, -26,
-28, 2, -45, -59, 0, -22, -52, 45, 20, -4, 35, 18, -2, 60, 39, -1,
16, 32, 10, 3, 28, 74, 5, -85, -92, -90, -94, -78, -19, -1, 63, 77,
63, 72, 33, 34, 5, -47, -32, -26, -12, -36, -73, -12, -4, -56, -2, 35,
-7, 31, 26, -5, 57, 47, 2, 9, 32, 19, 5, 11, 69, 32, -74, -99,
-91, -96, -84, -26, -4, 53, 79, 61, 67, 41, 23, 17, -40, -34, -21, -18,
-9, -72, -25, 7, -48, -20, 50, -9, 21, 37, -8, 20, 55, 9, 5, 34,
24, 13, 1, 57, 56, -58, -103, -91, -97, -89, -38, -9, 10, 78, 63, 64,
44, 24, 43, -33, -38, -17, -23, -9, -74, -47, 8, -39, -41, 48, -1, 10,
43, -3, 18, 68, 22, 8, 37, 35, 16, -8, 37, 74, -33, -108, -93, -92,
-94, -56, -17, 5, 76, 65, 65, 58, 33, 44, -23, -43, -19, -25, -10, -40,
-62, 7, -30, -51, 35, 13, 4, 40, 2, 9, 62, 28, 4, 32, 38, 13,
4, 17, 74, -1, -97, -94, -87, -92, -65, -20, -4, 49, 69, 59, 61, 33,
42, 23, -47, -19, -24, -13, -25, -79, 3, -8, -58, 12, 55, 2, 33, 9,
2, 54, 57, 7, 25, 47, 20, 6, 9, 65, 26, -85, -103, -90, -93, -77,
-27, -3, 33, 76, 58, 62, 37, 37, 40, -46, -26, -10, -13, -25, -78, -18,
-6, -51, -9, 49, 19, 27, 16, -3, 44, 63, 9, 18, 47, 24, 8, -4,
54, 52, -66, -109, -91, -89, -89, -29, 3, 15, 70, 66, 60, 39, 32, 46,
-7, -32, -12, -15, -19, -72, -67, 1, -45, -21, 43, 34, 20, 24, 2, 29,
64, 42, 9, 43, 31, 10, -1, 37, 68, -38, -107, -93, -89, -98, -45, -3,
2, 58, 83, 56, 44, 31, 52, 9, -43, -12, -15, -13, -60, -80, 8, -33,
-34, 29, 39, 17, 18, -2, 18, 60, 51, 4, 41, 46, 19, 4, -6, 74,
-3, -97, -98, -89, -98, -59, -8, -8, 44, 83, 56, 49, 29, 54, 27, -50,
-10, -14, -16, -44, -85, -25, -16, -44, 15, 42, 18, 29, -2, 5, 57, 61,
14, 32, 51, 20, 5, -9, 40, 20, -84, -96, -88, -97, -68, -12, -12, 27,
81, 63, 60, 31, 43, 42, -37, -47, -13, -21, -43, -86, -42, -8, -47, -4,
42, 26, 25, 7, -2, 46, 67, 24, 5, 55, 26, 14, -5, 20, 50, -67,
-102, -83, -88, -103, -23, -9, 12, 76, 68, 61, 39, 39, 50, -22, -47, -8,
-21, -31, -78, -62, 4, -44, -30, 35, 35, 18, 11, -6, 32, 63, 32, 3,
50, 34, 21, -2, 2, 75, -40, -101, -89, -85, -100, -44, -11, -6, 63, 81,
60, 47, 37, 56, -3, -48, -17, -19, -20, -69, -79, -2, -28, -43, 24, 46,
20, 22, -5, 16, 67, 51, 0, 25, 40, 18, 7, -8, 57, -14, -95, -90,
-87, -97, -85, -16, -11, 49, 83, 67, 62, 36, 61, 12, -47, -22, -21, -15,
-58, -95, -18, 16, -52, 12, 50, 22, 17, 8, 8, 57, 61, 12, 18, 43,
23, 18, -12, 43, 64, -92, -93, -84, -93, -90, -44, -11, 40, 80, 68, 63,
36, 61, 26, -40, -26, -11, -17, -47, -95, -38, 20, -39, -7, 55, 28, 10,
10, 4, 48, 68, 24, 10, 48, 23, 23, -7, 22, 72, -26, -102, -87, -91,
-90, -56, -12, 31, 77, 72, 67, 47, 57, 41, -31, -38, -16, -16, -38, -93,
-58, 17, -22, -26, 48, 34, 13, 16, -1, 29, 68, 37, 0, 42, 31, 23,
0, 10, 73, 0, -103, -90, -92, -94, -62, -24, 14, 73, 75, 68, 56, 57,
53, -21, -39, -17, -21, -26, -82, -74, 4, -3, -53, 38, 45, 8, 13, 4,
16, 61, 53, 5, 30, 53, 23, 8, 3, 67, 24, -83, -93, -91, -94, -77,
-35, 6, 62, 75, 67, 58, 44, 62, -2, -39, -19, -16, -9, -74, -85, -9,
0, -50, 24, 52, 11, 6, 7, -4, 60, 63, 12, 23, 55, 33, 12, -8,
54, 44, -74, -93, -90, -98, -85, -39, -13, 48, 83, 72, 57, 44, 66, 17,
-37, -18, -14, -18, -56, -94, -28, 10, -43, -32, 53, 21, 5, 10, -1, 19,
70, 23, 7, 50, 43, 13, -10, 43, 60, -54, -103, -92, -93, -85, -48, -15,
38, 77, 67, 55, 44, 60, 30, -35, -25, -13, -21, -24, -93, -45, 10, -32,
-42, 55, 32, 2, 10, -2, 9, 69, 33, 7, 45, 50, 29, -4, 30, 74,
-21, -98, -92, -93, -94, -67, -22, 6, 72, 70, 55, 44, 57, 66, -19, -24,
-13, -21, -19, -90, -69, 3, -18, -51, 15, 47, 5, 8, -1, 2, 50, 42,
6, 36, 51, 28, -2, 13, 74, 7, -90, -97, -90, -96, -77, -27, 1, 44,
72, 59, 45, 53, 73, -9, -29, -16, -21, -19, -50, -83, -9, -6, -53, -3,
58, 10, 10, 0, -6, 41, 49, 3, 30, 58, 31, 21, 2, 67, 40, -75,
-101, -88, -93, -82, -33, -6, 34, 72, 57, 47, 45, 72, 40, -37, -18, -16,
-21, -43, -89, -23, 5, -45, -19, 54, 20, 12, 1, -8, 32, 66, 9, 18,
63, 35, 16, -6, 46, 58, -55, -103, -91, -95, -89, -45, -12, 22, 75, 61,
47, 46, 72, 57, -33, -21, -15, -17, -30, -84, -47, 7, -39, -42, 44, 53,
8, 1, -7, 24, 66, 26, 8, 65, 52, 17, 3, 30, 69, -31, -102, -92,
-90, -97, -57, -17, 8, 61, 72, 53, 39, 61, 69, -2, -34, -4, -13, -30,
-68, -91, -3, -20, -49, 19, 55, 7, 6, -10, 9, 59, 61, 4, 54, 59,
21, 9, -9, 72, 3, -94, -97, -87, -96, -65, -25, -6, 49, 83, 58, 38,
54, 78, 18, -45, -8, -11, -24, -58, -98, -8, -3, -59, -5, 63, 22, 7,
-2, 1, 53, 72, 23, 38, 66, 27, 11, -9, 65, 26, -80, -101, -92, -91,
-79, -37, -9, 38, 74, 73, 48, 42, 77, 39, -35, -12, -5, -22, -49, -93,
-65, 9, -45, -25, 52, 37, 4, -2, -3, 43, 68, 27, 28, 66, 32, 16,
-8, 11, 49, -63, -99, -87, -89, -83, -42, -15, 24, 72, 74, 50, 40, 69,
51, -25, -34, -7, -18, -36, -83, -76, 11, -34, -45, 40, 49, 0, 5, -5,
31, 72, 43, 8, 64, 41, 19, 0, 0, 63, -42, -104, -92, -92, -96, -49,
-23, 16, 67, 74, 68, 32, 59, 65, -6, -38, -8, -17, -32, -75, -90, -20,
-17, -52, 19, 53, 8, -4, -9, 20, 70, 54, 5, 64, 54, 19, 3, -5,
55, -9, -92, -95, -90, -98, -83, -30, 2, 63, 79, 70, 40, 51, 73, 10,
-40, -25, -14, -21, -67, -99, -35, 19, -57, -4, 54, 18, -5, -6, 12, 62,
68, 17, 26, 63, 22, 4, -12, 41, 57, -88, -98, -92, -98, -87, -37, -9,
53, 83, 73, 56, 45, 79, 27, -36, -28, -15, -15, -56, -101, -52, 23, -54,
-26, 54, 24, -7, -2, 9, 57, 71, 31, 20, 71, 25, 8, -9, 18, 67,
-74, -98, -87, -97, -91, -59, -11, 40, 80, 75, 57, 36, 76, 48, -27, -33,
-18, -13, -43, -99, -74, 17, 3, -50, 40, 36, -3, -3, -3, 49, 70, 36,
14, 58, 32, 8, -3, 4, 69, 12, -105, -88, -94, -95, -67, -23, 24, 76,
77, 59, 34, 74, 60, -15, -33, -23, -15, -33, -88, -87, 5, 22, -60, 33,
49, 0, -1, -7, 34, 67, 53, 18, 42, 66, 12, 4, -1, 59, 42, -102,
-96, -92, -95, -81, -46, 11, 64, 83, 68, 34, 37, 72, -1, -37, -26, -14,
-26, -80, -98, -15, 32, -52, 12, 57, 2, -3, -8, -3, 66, 55, 20, 39,
68, 12, 10, -2, 48, 62, -52, -91, -90, -99, -86, -56, -2, 51, 80, 73,
47, 30, 77, 21, -38, -34, -17, -9, -65, -102, -35, 36, -36, -14, 62, 15,
-4, -2, -9, 66, 64, 19, 27, 70, 39, 11, -2, 33, 76, -27, -98, -87,
-96, -93, -66, -26, 37, 76, 73, 54, 37, 61, 43, -31, -37, -18, -14, -54,
-98, -53, 28, -13, -66, 50, 26, -5, 1, -13, 24, 73, 29, 15, 65, 52,
9, 3, 20, 80, 9, -95, -88, -93, -100, -76, -31, 1, 76, 80, 59, 43,
55, 60, -14, -45, -23, -8, -18, -97, -74, 19, -3, -74, -7, 38, -4, 1,
-9, 10, 76, 41, 11, 58, 66, 12, 3, 2, 65, 36, -85, -104, -87, -101,
-80, -36, -12, 66, 86, 67, 48, 46, 74, 3, -54, -30, -5, -16, -59, -87,
2, 9, -66, -26, 46, 11, 4, -13, 2, 63, 50, 12, 45, 75, 22, 7,
1, 48, 59, -58, -111, -83, -96, -91, -45, -19, 16, 86, 69, 51, 40, 68,
24, -48, -40, -7, -12, -53, -94, -17, 17, -56, -46, 41, 12, 1, -6, -7,
46, 62, 19, 30, 72, 36, 3, 4, 38, 71, -30, -105, -90, -96, -97, -59,
-25, 7, 79, 74, 57, 39, 60, 72, -38, -46, -12, -11, -45, -91, -35, 21,
-38, -63, 21, 26, -1, -8, -7, 39, 74, 32, 29, 68, 44, 7, 13, 25,
73, -3, -100, -93, -92, -99, -69, -33, 3, 60, 74, 68, 47, 50, 75, 20,
-56, -20, -12, -42, -85, -54, 19, -24, -68, 1, 44, 1, -10, -12, 23, 68,
64, 21, 60, 56, 10, 16, 14, 68, 22, -91, -99, -87, -101, -76, -41, -10,
51, 80, 67, 54, 41, 74, 46, -66, -28, -6, -37, -77, -91, 13, -4, -62,
-17, 38, 6, -9, -13, 16, 58, 64, 21, 48, 63, 15, 11, 9, 61, 45,
-73, -103, -87, -96, -86, -51, -18, 35, 80, 72, 61, 42, 66, 59, -29, -42,
-5, -30, -67, -95, -8, 10, -59, -37, 31, 24, -3, -9, 10, 54, 73, 42,
40, 67, 15, 10, 18, 47, 74, -44, -106, -87, -95, -92, -63, -31, 23, 75,
77, 62, 41, 57, 68, -4, -51, -6, -17, -56, -91, -72, 22, -36, -53, 16,
35, 8, -16, 1, 45, 67, 49, 32, 64, 24, 7, 27, 8, 80, -7, -105,
-95, -89, -97, -69, -36, 11, 68, 81, 64, 48, 55, 72, 12, -62, -16, -16,
-52, -86, -86, -9, -13, -60, -2, 39, 12, -11, -5, 29, 67, 61, 24, 61,
37, 9, 30, 8, 49, 21, -94, -101, -91, -96, -76, -43, -4, 58, 84, 70,
52, 49, 78, 37, -55, -23, -9, -43, -78, -92, -29, 6, -57, -22, 38, 21,
-9, -9, 18, 61, 69, 28, 60, 51, 3, 29, 13, 26, 49, -75, -105, -92,
-98, -92, -49, -15, 44, 82, 74, 58, 42, 72, 57, -39, -62, -9, -32, -66,
-96, -50, 26, -51, -42, 31, 29, -6, -8, 9, 55, 73, 36, 30, 60, 7,
25, 23, 14, 76, -49, -107, -93, -97, -97, -54, -22, 26, 80, 80, 68, 45,
61, 67, -18, -67, -28, -23, -59, -93, -63, 16, -33, -53, 16, 33, -2, -8,
3, 41, 75, 50, 30, 66, 13, 19, 36, 5, 61, -17, -103, -95, -94, -103,
-86, -26, 9, 69, 84, 70, 59, 53, 77, 8, -65, -42, -14, -45, -89, -78,
3, 22, -60, -2, 40, 1, -17, -5, 29, 67, 58, 31, 58, 24, 10, 37,
9, 49, 66, -94, -99, -87, -100, -95, -31, -5, 54, 85, 71, 62, 43, 73,
25, -55, -48, -17, -31, -78, -91, -16, 26, -61, -24, 40, 14, -16, -4, 21,
63, 64, 30, 51, 62, 5, 39, 13, 28, 76, -76, -103, -87, -95, -97, -61,
-11, 42, 83, 73, 67, 43, 70, 48, -40, -56, -24, -20, -66, -94, -33, 28,
-18, -39, 29, 21, -13, -7, 3, 53, 66, 40, 48, 64, 6, 37, 18, 11,
76, 12, -100, -89, -92, -97, -72, -39, 24, 80, 74, 67, 43, 66, 66, -30,
-61, -31, -17, -52, -94, -53, 24, 3, -59, 19, 33, -10, -11, 5, 44, 68,
45, 41, 67, 28, 32, 25, -1, 69, 35, -80, -89, -93, -98, -77, -43, 9,
77, 77, 67, 55, 32, 79, 1, -64, -41, -15, -22, -94, -66, 14, 12, -50,
0, 31, -2, -13, -1, 19, 67, 46, 40, 69, 39, 27, 35, -7, 53, 60,
-61, -91, -91, -98, -84, -50, -25, 57, 77, 67, 61, 29, 82, 27, -57, -53,
-20, -11, -85, -78, 2, 27, -41, -55, 33, 7, -14, -2, 16, 60, 54, 39,
63, 50, 7, 43, -1, 33, 76, -36, -105, -86, -95, -91, -56, -26, 40, 79,
72, 68, 36, 53, 51, -44, -59, -27, -11, -47, -88, -18, 28, -28, -63, 22,
9, -9, -2, 8, 45, 60, 41, 63, 60, 8, 25, 11, 12, 73, -5, -98,
-91, -97, -94, -69, -36, 0, 74, 72, 70, 41, 37, 81, -21, -61, -37, -10,
-34, -95, -30, 27, -14, -65, -23, 12, -5, -2, 0, 36, 68, 39, 59, 66,
17, 19, 19, 0, 69, 28, -83, -98, -91, -93, -79, -41, -5, 44, 72, 71,
49, 32, 76, -3, -64, -45, -11, -25, -82, -49, 22, 7, -61, -41, 22, -1,
2, 2, 26, 68, 43, 58, 69, 26, 13, 42, -8, 56, 57, -67, -104, -89,
-96, -85, -51, -18, 31, 73, 70, 60, 31, 66, 65, -58, -53, -19, -18, -72,
-66, 16, 23, -50, -58, 6, -4, -2, 1, 10, 59, 60, 49, 73, 38, 11,
47, -5, 36, 79, -39, -105, -88, -97, -89, -61, -28, 17, 69, 70, 62, 34,
57, 73, -43, -54, -28, -16, -58, -95, 0, 37, -34, -73, -5, 17, -11, 3,
9, 43, 57, 49, 65, 48, 14, 34, 33, 19, 81, -6, -99, -91, -93, -92,
-65, -30, 7, 62, 74, 67, 39, 42, 79, 17, -64, -35, -17, -50, -91, -57,
34, -11, -70, -28, 17, -4, 1, 6, 38, 60, 51, 58, 60, 19, 18, 47,
1, 73, 31, -86, -96, -88, -94, -74, -37, -6, 50, 79, 72, 51, 34, 79,
44, -67, -43, -18, -41, -87, -76, 30, 6, -68, -45, 15, 4, -3, 6, 34,
54, 50, 65, 64, 26, 15, 52, 10, 52, 56, -66, -103, -91, -94, -79, -50,
-22, 36, 78, 71, 58, 29, 72, 61, -34, -52, -25, -27, -78, -90, -14, 20,
-60, -54, 12, 9, -1, 2, 24, 50, 49, 56, 67, 36, 10, 53, 24, -11,
77, -41, -108, -88, -90, -89, -52, -27, 16, 76, 75, 59, 21, 51, 76, -13,
-68, -28, -21, -64, -93, -34, 30, -44, -68, -2, 17, -2, 4, 16, 42, 53,
58, 60, 50, 15, 44, 44, -12, 82, -4, -102, -94, -87, -96, -64, -32, 6,
63, 74, 71, 25, 40, 83, 12, -62, -40, -19, -51, -92, -49, 28, -30, -73,
-15, 16, -3, 6, 15, 31, 52, 59, 57, 53, 12, 35, 58, -13, 29, 27,
-89, -98, -89, -95, -66, -38, -7, 58, 79, 70, 32, 30, 81, 35, -51, -64,
-24, -39, -86, -70, 15, -10, -77, -30, 19, -4, -1, 17, 21, 46, 60, 56,
60, 18, 24, 63, 1, 13, 55, -69, -98, -88, -96, -91, -46, -18, 43, 80,
72, 59, 19, 70, 55, -30, -65, -29, -20, -70, -84, -1, 47, -71, -49, 19,
4, -10, 11, 17, 39, 60, 58, 56, 29, 15, 61, 17, -6, 80, -43, -102,
-88, -89, -95, -74, -25, 25, 75, 74, 68, 19, 61, 72, -16, -66, -54, -22,
-63, -91, -21, 48, -11, -64, 10, 10, -9, 9, 14, 33, 56, 60, 56, 52,
13, 54, 34, -14, 65, 54, -100, -93, -86, -93, -83, -33, 13, 67, 74, 73,
40, 43, 80, 8, -64, -63, -27, -44, -91, -46, 43, 13, -77, -2, 13, -18,
-1, 13, 24, 47, 62, 62, 62, 15, 38, 48, -10, 43, 73, -87, -99, -86,
-93, -90, -55, 1, 61, 75, 71, 49, 30, 85, 33, -55, -67, -33, -34, -84,
-67, 22, 30, -59, -16, 18, -15, -2, 15, 17, 40, 58, 63, 59, 37, 32,
54, -4, 21, 82, -16, -100, -86, -93, -93, -61, -4, 53, 74, 69, 57, 14,
81, 54, -46, -68, -41, -23, -71, -80, -1, 39, -38, -38, 17, -5, -5, 16,
13, 37, 51, 64, 60, 40, 19, 55, 12, 4, 81, 19, -102, -91, -92, -96,
-75, -34, 39, 73, 70, 66, 19, 27, 76, -27, -74, -46, -22, -59, -83, -23,
37, -15, -69, 11, 5, -5, 13, 11, 23, 50, 57, 60, 54, 25, 42, 25,
-7, 68, 51, -70, -93, -88, -93, -81, -47, -4, 72, 70, 62, 27, 16, 85,
-5, -72, -51, -26, -30, -79, -48, 30, 4, -68, -3, 7, -7, 9, 11, 17,
50, 59, 60, 59, 40, 28, 37, -3, 49, 67, -49, -101, -89, -90, -88, -61,
-10, 66, 72, 64, 40, 14, 62, 21, -68, -60, -32, -30, -70, -65, 12, 22,
-55, -51, 14, -5, 4, 18, 18, 34, 60, 56, 60, 50, 25, 45, 5, 30,
77, -16, -99, -87, -90, -91, -68, -18, 36, 76, 71, 51, 17, 47, 48, -56,
-73, -36, -25, -42, -75, -11, 31, -38, -67, -5, -2, -11, 8, 18, 29, 55,
56, 57, 57, 29, 33, 16, 13, 76, 17, -88, -97, -85, -93, -79, -30, 25,
71, 74, 60, 15, 31, 82, -37, -77, -45, -18, -31, -73, -23, 39, -16, -72,
-19, 5, -13, 5, 18, 24, 43, 54, 53, 62, 34, 23, 40, 9, 64, 36,
-71, -99, -90, -95, -81, -42, 5, 60, 77, 67, 24, 21, 81, -20, -75, -50,
-25, -27, -63, -49, 30, 8, -71, -46, 8, -12, -1, 21, 27, 42, 59, 54,
63, 37, 20, 44, 4, 62, 63, -56, -101, -85, -94, -87, -54, -10, 45, 75,
70, 35, 11, 73, 57, -69, -55, -30, -22, -49, -76, 20, 32, -54, -62, -2,
-12, -10, 15, 28, 35, 50, 54, 62, 42, 14, 46, 32, 43, 75, -29, -102,
-94, -91, -92, -60, -17, 30, 73, 75, 44, 10, 60, 67, -28, -63, -37, -24,
-42, -73, 3, 46, -32, -71, -15, 1, -11, 7, 28, 39, 52, 58, 64, 56,
17, 38, 40, 31, 81, -8, -93, -89, -91, -95, -65, -28, 17, 63, 78, 50,
2, 47, 78, -12, -59, -36, -24, -37, -74, -61, 45, -21, -80, -27, 2, -10,
2, 25, 42, 48, 60, 61, 57, 23, 31, 42, 1, 78, 18, -88, -95, -92,
-99, -72, -33, 11, 61, 79, 65, 7, 30, 85, 10, -62, -39, -24, -32, -67,
-72, 43, 8, -76, -43, 0, -6, -5, 20, 47, 45, 52, 63, 63, 30, 27,
49, 6, 73, 47, -77, -104, -87, -99, -82, -41, 0, 53, 74, 79, 19, 12,
82, 35, -53, -44, -24, -26, -65, -81, -8, 33, -68, -58, -3, -5, -10, 8,
47, 48, 44, 62, 58, 34, 23, 45, 13, 11, 66, -47, -110, -92, -89, -100,
-43, -3, 39, 69, 79, 33, 2, 69, 59, -33, -59, -26, -19, -56, -89, -37,
54, -46, -76, -10, 5, -5, 2, 41, 53, 44, 59, 64, 38, 17, 37, 20,
0, 68, -18, -105, -95, -85, -97, -51, -17, 26, 70, 76, 65, -3, 54, 72,
-17, -57, -41, -15, -44, -82, -55, 36, -17, -79, -28, 2, -1, -7, 27, 50,
41, 55, 65, 45, 21, 33, 28, -1, 59, 11, -93, -99, -84, -98, -90, -23,
18, 69, 81, 72, 3, 41, 84, 0, -58, -47, -13, -31, -79, -73, 21, 54,
-86, -51, 5, 5, -15, 21, 55, 41, 49, 68, 62, 22, 33, 38, -4, 41,
78, -79, -105, -87, -94, -96, -36, 9, 61, 76, 76, 49, 22, 86, 29, -51,
-51, -26, -28, -73, -80, -5, 50, -72, -70, -8, 9, -13, -12, 56, 46, 47,
67, 64, 37, 25, 46, 1, 17, 85, -55, -104, -84, -90, -100, -70, -2, 50,
71, 71, 57, 8, 75, 54, -37, -54, -27, -25, -66, -82, -23, 47, -1, -73,
-23, 6, -8, -15, 29, 41, 47, 64, 57, 44, 19, 45, 13, 4, 84, 37,
-102, -88, -88, -100, -79, -35, 34, 70, 72, 64, 10, 61, 72, -22, -57, -34,
-16, -61, -87, -38, 40, 19, -75, -37, 8, 0, -25, 19, 52, 39, 67, 63,
46, 27, 39, 27, -10, 64, 65, -98, -95, -85, -93, -81, -43, 24, 70, 74,
68, 19, 6, 81, -3, -51, -37, -19, -55, -87, -54, 27, 38, -47, -55, 0,
6, -26, 2, 57, 38, 62, 66, 51, 31, 28, 36, -12, 40, 78, -34, -98,
-85, -91, -84, -54, -16, 61, 71, 73, 33, -2, 87, 19, -48, -39, -17, -28,
-83, -60, 15, 50, -24, -75, -9, 12, -17, -9, 48, 38, 56, 62, 51, 45,
17, 38, 0, 24, 83, -8, -98, -80, -91, -95, -68, -23, 50, 62, 77, 51,
-11, 46, 44, -46, -50, -23, -25, -63, -73, -6, 48, -5, -74, -21, 13, -11,
-19, 40, 56, 48, 66, 53, 51, 26, 27, 9, 6, 78, 18, -88, -85, -87,
-95, -77, -35, 16, 65, 73, 62, -5, 27, 65, -35, -49, -23, -17, -53, -79,
-19, 49, 14, -71, -60, 10, -6, -28, 26, 64, 44, 70, 57, 48, 32, 23,
19, 0, 73, 45, -70, -92, -83, -95, -85, -45, 4, 63, 71, 71, 6, 2,
84, -16, -52, -33, -19, -40, -81, -40, 39, 31, -58, -69, 3, 3, -23, 12,
64, 52, 65, 62, 53, 37, 21, 34, 0, 57, 66, -52, -103, -81, -91, -91,
-52, -2, 43, 75, 76, 18, -12, 73, 59, -52, -32, -21, -35, -68, -52, 21,
41, -41, -75, -28, 3, -16, -1, 55, 59, 48, 59, 52, 45, 26, 33, 4,
42, 75, -27, -102, -91, -85, -92, -62, -12, 32, 66, 76, 33, -12, 60, 74,
-54, -36, -20, -34, -61, -72, 2, 49, -22, -80, -36, -2, -17, -6, 42, 61,
52, 63, 57, 47, 29, 36, 25, 27, 76, -5, -96, -97, -89, -93, -66, -18,
25, 64, 83, 46, -13, 40, 86, -7, -46, -16, -26, -52, -70, -14, 52, -4,
-78, -46, -7, -14, -16, 29, 68, 57, 56, 58, 40, 25, 29, 30, 19, 73,
29, -78, -101, -82, -95, -76, -22, 13, 48, 79, 52, -12, 18, 90, 23, -56,
-21, -23, -50, -73, -67, 45, 21, -65, -57, -9, 5, -25, 7, 65, 58, 49,
61, 37, 31, 33, 33, 13, 66, 57, -58, -108, -85, -83, -82, -30, 2, 37,
74, 67, 2, 2, 85, 46, -48, -26, -21, -48, -64, -69, -17, 37, -53, -74,
-28, 5, -23, -11, 57, 65, 45, 64, 46, 33, 31, 37, 20, 17, 72, -31,
-102, -85, -79, -85, -38, -10, 20, 66, 77, 18, -10, 68, 66, -31, -47, -15,
-39, -58, -69, -35, 48, -32, -77, -38, 2, 2, -19, 42, 65, 45, 64, 45,
32, 31, 34, 25, 6, 80, -3, -98, -89, -78, -93, -45, -16, 13, 63, 75,
33, -12, 50, 84, -11, -55, -16, -32, -62, -77, -48, 30, -15, -69, -48, -4,
14, -32, 26, 72, 47, 59, 67, 38, 32, 34, 31, 2, 48, 20, -86, -95,
-80, -92, -55, -20, 2, 59, 77, 61, -5, 31, 85, 11, -49, -32, -31, -60,
-75, -54, 16, 3, -57, -57, -20, 19, -17, 5, 71, 49, 51, 68, 44, 34,
36, 40, 5, 34, 46, -70, -98, -80, -90, -86, -22, -9, 46, 82, 64, 26,
17, 77, 33, -39, -37, -26, -51, -69, -65, -5, 40, -56, -71, -30, 17, -7,
-35, 68, 54, 45, 66, 41, 40, 32, 37, 15, 20, 78, -51, -97, -81, -89,
-91, -50, -14, 31, 80, 73, 42, 15, 72, 57, -21, -47, -23, -46, -72, -72,
-27, 36, -38, -68, -37, 10, 7, -35, 56, 59, 37, 68, 50, 32, 36, 37,
23, 4, 68, -18, -100, -87, -84, -94, -64, -17, 19, 70, 76, 47, 2, 63,
67, -6, -43, -28, -35, -68, -71, -44, 23, 21, -66, -48, 2, 16, -33, -8,
68, 34, 61, 61, 27, 38, 39, 34, 4, 51, 68, -92, -92, -83, -100, -75,
-32, 13, 62, 77, 63, 10, 50, 79, 12, -38, -36, -17, -62, -75, -56, 11,
37, -37, -63, -4, 20, -29, -26, 68, 40, 51, 67, 36, 34, 41, 38, 8,
37, 72, -25, -98, -82, -99, -86, -41, 0, 56, 73, 67, 29, 4, 83, 34,
-31, -42, -17, -30, -77, -66, -5, 43, -20, -72, -14, 25, -14, -27, 40, 45,
50, 68, 39, 28, 44, 41, 4, 23, 79, 4, -105, -82, -92, -96, -53, -26,
43, 81, 72, 40, 7, 75, 54, -20, -50, -21, -22, -71, -75, -22, 44, -8,
-80, -28, 16, -9, -29, 27, 45, 46, 67, 43, 29, 44, 46, 18, 13, 72,
38, -78, -90, -88, -99, -66, -32, 31, 75, 77, 52, 11, 37, 64, -6, -47,
-28, -21, -61, -76, -41, 34, 16, -66, -40, 9, 1, -28, 14, 53, 37, 67,
55, 23, 36, 47, 27, 1, 56, 62, -55, -95, -84, -98, -77, -37, -4, 69,
75, 62, 22, 22, 73, 9, -38, -33, -20, -47, -80, -55, 21, 33, -46, -69,
1, 8, -24, 0, 42, 32, 66, 56, 23, 34, 47, 38, -1, 37, 75, -28,
-105, -78, -92, -87, -43, -16, 29, 77, 68, 34, 14, 68, 25, -35, -35, -20,
-39, -77, -63, 9, 37, -36, -74, -32, 11, -22, -10, 38, 33, 59, 67, 29,
33, 51, 54, 7, 23, 76, -5, -101, -81, -91, -93, -45, -15, 15, 79, 74,
46, 9, 51, 75, -30, -43, -24, -32, -72, -75, 0, 42, -23, -69, -40, 10,
-15, -21, 26, 35, 37, 72, 36, 31, 46, 51, 15, 8, 74, 27, -90, -99,
-82, -100, -59, -18, 1, 52, 73, 53, 13, 36, 77, -13, -42, -29, -17, -55,
-92, -14, 39, -10, -66, -49, -9, -6, -22, 17, 34, 32, 75, 41, 31, 44,
44, 43, -3, 61, 51, -68, -102, -77, -102, -70, -22, -12, 39, 74, 63, 27,
28, 77, 37, -39, -40, -23, -42, -89, -73, 35, 7, -57, -54, -17, 4, -23,
2, 32, 29, 63, 50, 32, 46, 42, 43, 8, 43, 69, -40, -107, -84, -99,
-82, -26, -18, 20, 71, 66, 38, 21, 69, 52, -12, -40, -27, -30, -79, -87,
24, 27, -45, -67, -26, 18, -22, -11, 33, 33, 53, 55, 36, 44, 37, 43,
15, 25, 80, -11, -102, -87, -76, -91, -33, -20, 2, 62, 63, 47, 19, 56,
65, 5, -36, -33, -26, -68, -92, -29, 33, -24, -64, -42, 10, -14, -23, 24,
31, 40, 65, 38, 43, 36, 45, 31, -12, 81, 20, -92, -92, -69, -100, -45,
-18, -16, 50, 77, 55, 20, 48, 75, 17, -25, -43, -24, -54, -99, -48, 36,
-11, -60, -54, 2, 20, -30, 21, 34, 30, 69, 61, 41, 36, 36, 39, -13,
61, 46, -74, -99, -65, -88, -62, -20, -27, 35, 78, 65, 28, 37, 80, 36,
-14, -47, -27, -35, -94, -70, 19, 6, -55, -66, -10, 27, -23, 4, 37, 22,
57, 71, 34, 32, 33, 45, -3, 2, 68, -49, -106, -71, -73, -98, -23, -21,
18, 79, 76, 33, 28, 74, 51, 0, -35, -41, -26, -84, -88, 2, 24, -40,
-72, -28, 27, -13, -12, 39, 24, 44, 77, 51, 30, 30, 44, 6, -15, 84,
-20, -108, -78, -67, -102, -30, -23, -3, 70, 81, 62, 23, 67, 72, 15, -26,
-47, -27, -74, -97, -22, 38, -28, -69, -38, 21, 6, -39, 33, 28, 29, 73,
62, 37, 36, 47, 22, -15, 52, 5, -100, -92, -69, -97, -77, -22, -19, 52,
81, 67, 21, 49, 80, 30, -18, -50, -22, -53, -100, -43, 33, 20, -66, -53,
11, 17, -38, 18, 33, 19, 62, 69, 40, 34, 48, 31, -16, 35, 71, -82,
-103, -69, -88, -91, -16, -27, 38, 83, 72, 49, 39, 80, 46, -8, -49, -45,
-42, -96, -64, 16, 27, -57, -63, -3, 27, -27, -21, 33, 14, 59, 73, 39,
31, 45, 42, -14, 16, 80, -60, -104, -76, -79, -92, -42, -34, 25, 84, 65,
50, 37, 70, 56, 7, -43, -55, -29, -87, -77, 9, 38, -15, -68, -16, 32,
-20, -38, 36, 8, 40, 78, 48, 28, 43, 53, -5, -6, 82, 31, -105, -75,
-72, -99, -54, -36, 0, 79, 76, 54, 33, 72, 65, 21, -30, -64, -26, -70,
-90, -13, 46, 3, -74, -27, 26, -10, -39, 15, 11, 31, 79, 60, 33, 34,
54, 8, -15, 65, 57, -107, -87, -57, -101, -70, -18, -21, 67, 79, 62, 35,
35, 76, 25, -20, -59, -36, -53, -98, -33, 44, 18, -53, -41, 18, -4, -42,
9, 25, 22, 73, 62, 38, 34, 49, 18, -21, 44, 71, -37, -101, -55, -91,
-83, -17, -41, 57, 83, 64, 44, 25, 81, 35, -14, -50, -38, -18, -97, -54,
35, 31, -40, -67, 9, 7, -42, 1, 31, 11, 72, 66, 41, 38, 43, 32,
-24, 28, 80, -9, -110, -53, -75, -101, -23, -30, 33, 87, 68, 51, 21, 58,
49, -11, -48, -42, -18, -85, -75, 18, 45, -28, -68, -1, 9, -36, -12, 28,
0, 60, 70, 38, 36, 42, 42, -12, 10, 77, 19, -94, -58, -58, -105, -37,
-18, -29, 83, 72, 58, 22, 41, 68, -1, -41, -40, -21, -44, -84, -5, 50,
-6, -69, -48, 17, -31, -27, 23, 3, 45, 72, 44, 36, 39, 48, -1, 2,
69, 41, -73, -102, -47, -104, -57, -15, -41, 74, 75, 54, 26, 30, 77, 14,
-34, -39, -25, -31, -76, -31, 49, 12, -61, -57, 20, -20, -36, 19, 7, 0,
79, 53, 35, 37, 46, 36, -13, 56, 61, -55, -105, -48, -94, -69, -15, -41,
13, 86, 61, 31, 25, 73, 60, -34, -37, -28, -33, -65, -52, 34, 31, -46,
-65, -7, -4, -37, 8, 16, -5, 72, 64, 40, 38, 38, 41, -16, 36, 75,
-33, -107, -56, -90, -79, -13, -39, -2, 81, 65, 38, 14, 65, 71, -31, -39,
-26, -32, -60, -80, 23, 44, -37, -67, -14, 5, -38, -1, 25, -3, 35, 71,
50, 38, 32, 39, 7, 23, 79, -3, -103, -71, -73, -93, -22, -31, -19, 67,
64, 45, 11, 50, 77, 6, -37, -24, -27, -51, -80, 5, 48, -21, -68, -30,
17, -34, -18, 27, 4, 26, 73, 55, 49, 32, 31, 14, 7, 74, 29, -89,
-85, -41, -99, -34, -26, -33, 53, 77, 50, 20, 41, 77, 22, -34, -20, -21,
-39, -68, -58, 48, 2, -71, -43, 12, -1, -27, 21, 12, 14, 67, 59, 49,
34, 25, 15, -17, 67, 55, -70, -100, -41, -74, -51, -19, -42, 32, 76, 55,
25, 34, 81, 31, -25, -25, -25, -27, -62, -69, 41, 21, -63, -64, 4, 9,
-40, 11, 19, 6, 55, 76, 53, 41, 26, 18, -10, 54, 70, -41, -106, -50,
-64, -74, -12, -45, 11, 84, 67, 30, 28, 84, 56, -21, -21, -26, -28, -51,
-76, -15, 33, -47, -72, -12, 16, -34, 0, 21, 1, 43, 77, 57, 48, 26,
21, -3, 1, 84, -11, -110, -64, -47, -104, -23, -40, -9, 77, 71, 38, 19,
69, 69, -11, -26, -26, -22, -36, -77, -33, 45, -26, -78, -32, 22, -22, -17,
27, -4, 23, 79, 67, 52, 30, 23, 4, -11, 58, 18, -100, -83, -42, -93,
-31, -35, -28, 68, 78, 55, 19, 57, 81, 1, -30, -19, -19, -29, -73, -45,
36, -9, -73, -45, 19, -8, -50, 29, 0, 5, 70, 68, 55, 34, 21, 12,
-17, 36, 45, -85, -100, -44, -84, -85, -28, -37, 51, 79, 57, 26, 40, 86,
23, -32, -23, -20, -22, -65, -57, 21, 37, -68, -60, 13, 4, -51, 21, 8,
-4, 58, 74, 62, 46, 26, 19, -15, 19, 80, -58, -106, -53, -72, -97, -25,
-42, 34, 83, 56, 46, 33, 84, 41, -32, -30, -19, -13, -60, -67, 7, 40,
-57, -70, -1, 12, -43, -16, 19, -15, 46, 78, 60, 68, 25, 21, -10, 3,
73, -33, -107, -68, -61, -101, -47, -43, 8, 85, 65, 45, 25, 79, 58, -17,
-30, -19, -3, -47, -74, -14, 39, -3, -80, -21, 19, -33, -33, 32, -16, 24,
82, 66, 65, 27, 20, 4, -5, 64, 53, -103, -79, -58, -100, -60, -28, -14,
75, 71, 45, 26, 70, 67, -5, -33, -26, -3, -31, -76, -33, 35, 12, -64,
-32, 24, -28, -47, 26, -13, 7, 74, 70, 65, 53, 14, 8, -7, 50, 68,
-91, -90, -59, -97, -72, -28, -29, 66, 79, 51, 30, 37, 75, 3, -37, -30,
-5, -23, -70, -46, 21, 24, -44, -50, 23, -7, -53, 13, 22, -2, 66, 67,
69, 66, 16, 12, -10, 34, 76, -16, -100, -61, -87, -83, -35, -50, 53, 83,
53, 36, 34, 82, 22, -36, -35, -7, 7, -61, -56, 8, 30, -26, -75, 7,
9, -52, -8, 31, -16, 55, 71, 61, 71, 35, 10, -12, 20, 79, 6, -104,
-57, -75, -96, -40, -44, 29, 88, 59, 33, 28, 66, 41, -26, -46, -10, 13,
-25, -61, -6, 34, -16, -69, -5, 11, -48, -27, 34, -7, 36, 76, 62, 65,
43, 18, -17, 4, 76, 30, -91, -66, -62, -92, -50, -43, -33, 82, 69, 34,
17, 55, 80, -19, -49, -14, 14, -15, -66, -19, 36, -2, -66, -53, 15, -29,
-35, 21, 6, 24, 73, 64, 63, 53, 21, -14, -11, 64, 54, -72, -103, -53,
-90, -58, -42, -45, 77, 73, 41, 20, 43, 84, 0, -51, -24, 15, 1, -53,
-37, 32, 9, -63, -63, 12, -20, -38, 12, 10, -11, 71, 69, 64, 60, 27,
10, -19, 46, 73, -41, -109, -56, -89, -71, -37, -51, 18, 79, 50, 26, 28,
73, 60, -48, -41, 13, 17, -37, -55, 25, 28, -49, -66, -12, -14, -44, -1,
12, -16, 29, 78, 66, 63, 34, 14, -17, 29, 81, -14, -110, -80, -87, -85,
-40, -48, -1, 80, 57, 27, 22, 67, 70, -38, -45, 3, 21, -23, -76, 7,
37, -37, -65, -14, 10, -41, -8, 15, -12, 20, 76, 61, 70, 42, 10, -4,
15, 84, 15, -98, -91, -66, -90, -47, -45, -15, 71, 63, 30, 10, 57, 82,
6, -45, -3, 20, -7, -62, -20, 42, -15, -73, -30, 14, -35, -24, 16, -6,
4, 69, 60, 69, 50, 16, 4, -2, 76, 42, -83, -98, -64, -99, -57, -44,
-30, 56, 85, 39, 10, 45, 85, 19, -46, -7, 19, 5, -46, -67, 38, 8,
-70, -47, 9, -7, -32, 12, -3, -11, 60, 65, 65, 58, 24, 11, -18, 61,
63, -60, -107, -67, -83, -72, -42, -38, 36, 83, 49, 9, 29, 86, 36, -41,
-17, 19, 12, -38, -64, -11, 21, -51, -53, 0, -2, -39, 11, 9, -23, 42,
87, 64, 54, 19, 15, -14, -2, 76, -39, -105, -62, -72, -81, -32, -38, 19,
84, 67, 13, 17, 80, 54, -25, -39, 2, 22, -21, -73, -31, 33, -35, -57,
-8, 4, -33, 1, 13, -15, 33, 82, 68, 60, 22, 19, 0, -16, 84, -8,
-106, -77, -63, -101, -41, -39, 1, 78, 72, 20, 9, 70, 72, -10, -39, -5,
22, -7, -72, -45, 37, -27, -60, -14, 8, -28, -8, 20, -14, 14, 77, 73,
62, 24, 18, 9, -23, 47, 16, -98, -82, -57, -100, -44, -31, -16, 64, 83,
52, 3, 53, 75, 1, -37, -28, 12, 7, -59, -61, 28, -11, -62, -28, 2,
-20, -35, 20, -5, 7, 68, 73, 71, 31, 14, 16, -23, 24, 42, -84, -95,
-58, -92, -84, -30, -25, 45, 79, 62, 19, 36, 83, 18, -36, -28, 8, 20,
-44, -75, 10, 46, -63, -40, 1, -13, -33, -2, 5, 2, 55, 76, 78, 34,
9, 21, -19, 3, 77, -58, -108, -63, -78, -93, -36, -29, 29, 82, 66, 20,
20, 82, 36, -36, -37, -11, 27, -24, -78, -11, 59, -9, -53, 4, -11, -42,
-12, 0, -5, 45, 71, 72, 69, 15, 29, -7, -11, 74, -28, -111, -75, -70,
-98, -48, -27, 13, 76, 71, 31, -8, 73, 53, -27, -41, -12, 29, -10, -70,
-29, 51, 8, -64, -4, -3, -45, -24, 11, -7, 33, 69, 73, 69, 22, 30,
-2, -22, 62, 54, -106, -86, -68, -100, -68, -25, 3, 67, 76, 49, 3, 60,
69, -13, -43, -19, 15, 7, -65, -49, 39, 21, -63, -20, 6, -36, -33, 6,
-7, 25, 65, 73, 70, 38, 36, 6, -34, 48, 75, -47, -93, -62, -93, -84,
-30, -8, 53, 79, 56, 12, 10, 78, 4, -46, -26, 2, 26, -51, -64, 24,
38, -49, -33, 12, -29, -41, 6, 3, 17, 64, 72, 72, 43, 22, 19, -38,
23, 87, -14, -102, -65, -87, -93, -36, -21, 38, 82, 60, 16, 4, 61, 29,
-46, -38, 0, 22, -43, -69, 9, 44, -32, -70, 14, -21, -50, 2, 9, 6,
59, 71, 73, 52, 21, 31, -25, 0, 82, 17, -98, -71, -79, -101, -46, -18,
22, 86, 70, 20, 1, 50, 48, -40, -46, -5, 23, 4, -73, -6, 49, -14,
-73, 1, -12, -51, -8, 14, -16, 53, 72, 66, 57, 28, 37, -11, -13, 75,
45, -77, -78, -68, -98, -61, -19, -12, 75, 76, 29, -4, 35, 81, -30, -52,
-11, 17, 13, -68, -24, 50, 6, -66, -41, -7, -49, -20, 15, -14, 7, 74,
67, 58, 30, 30, 1, -23, 62, 65, -56, -104, -75, -97, -75, -29, -16, 31,
80, 42, 2, 20, 76, -9, -55, -23, 9, 16, -33, -43, 44, 27, -55, -45,
6, -47, -31, 12, -8, 3, 71, 69, 67, 39, 19, 33, -22, 36, 80, -28,
-108, -87, -94, -89, -37, -19, 15, 85, 53, 8, 8, 72, 60, -57, -29, 4,
15, -18, -60, 29, 47, -41, -59, -2, -40, -43, 11, 2, -8, 47, 73, 68,
46, 18, 34, -14, 12, 84, 6, -100, -90, -86, -94, -44, -21, -2, 64, 59,
13, 0, 55, 71, -55, -39, 0, 12, -9, -60, 11, 50, -20, -63, -18, -4,
-46, 5, 11, -13, 30, 74, 70, 54, 19, 29, 28, -6, 76, 39, -83, -98,
-76, -98, -56, -21, -10, 51, 72, 27, 1, 44, 82, 2, -48, -8, 4, -2,
-49, -53, 55, -5, -68, -29, -3, -49, -9, 18, -9, 14, 66, 72, 58, 22,
24, 39, -6, 58, 57, -66, -107, -78, -101, -73, -30, -16, 33, 78, 40, 5,
34, 84, 24, -51, -16, 0, 9, -30, -59, 53, 14, -62, -44, -7, -29, -27,
20, -4, 3, 61, 70, 64, 29, 15, 48, 6, 35, 75, -43, -109, -76, -84,
-80, -32, -20, 21, 75, 51, 8, 13, 78, 46, -50, -17, 0, -2, -24, -56,
-2, 27, -47, -53, -13, -20, -38, 16, 4, -1, 54, 68, 74, 39, 5, 47,
21, -17, 74, -19, -105, -87, -80, -94, -40, -17, 9, 68, 76, 13, 6, 75,
68, -39, -47, 1, -16, -17, -48, -24, 36, -33, -53, -21, -15, -44, 12, 9,
-14, 44, 69, 62, 55, 1, 36, 39, -21, 71, 4, -99, -88, -74, -103, -43,
-16, 3, 65, 76, 39, 9, 58, 74, -17, -61, 1, -9, -6, -37, -36, 46,
-23, -57, -26, -19, -45, -26, 20, -16, 31, 74, 63, 62, 6, 26, 54, -14,
18, 27, -90, -97, -78, -102, -81, -19, -7, 54, 83, 49, 2, 50, 78, 3,
-57, -26, -5, -10, -35, -47, 30, 36, -52, -32, -16, -41, -42, 24, -14, 20,
73, 63, 75, 16, 13, 53, -6, 2, 50, -71, -105, -75, -92, -91, -20, -13,
38, 82, 58, 10, 35, 79, 23, -50, -39, -7, -8, -22, -51, 13, 54, -54,
-38, -15, -40, -48, 13, -10, 0, 67, 64, 65, 29, 11, 52, 10, -5, 71,
-45, -107, -78, -84, -97, -48, -13, 24, 81, 69, 15, 29, 81, 35, -42, -41,
-16, -17, -11, -51, -11, 58, -12, -42, -19, -35, -40, 6, 3, -7, 61, 72,
60, 55, 3, 46, 22, -20, 57, 47, -106, -86, -80, -99, -62, -8, 12, 63,
78, 29, -8, 77, 54, -31, -47, -12, -14, -7, -42, -26, 58, 9, -47, -17,
-25, -44, -13, 25, -18, 39, 71, 60, 56, 16, 41, 38, -18, 40, 66, -99,
-96, -73, -94, -73, -13, 8, 53, 84, 36, -16, 27, 65, -16, -53, -19, -13,
-7, -30, -42, 47, 29, -55, -22, -26, -44, -24, 22, -12, 24, 67, 65, 59,
23, 32, 42, -13, 26, 74, -28, -103, -71, -91, -85, -21, 1, 43, 80, 45,
-6, 16, 75, 8, -48, -29, -16, -22, -20, -53, 29, 50, -49, -22, -22, -45,
-31, 19, 12, 13, 62, 61, 65, 32, 0, 51, 1, 10, 78, 5, -106, -74,
-86, -95, -33, 5, 25, 78, 62, 0, 0, 62, 34, -45, -43, -6, -19, -20,
-49, 8, 60, -27, -59, -14, -38, -44, 9, 20, -13, 59, 63, 64, 39, -2,
47, 6, 1, 72, 22, -90, -74, -83, -99, -36, 6, 3, 72, 69, 11, -6,
51, 51, -39, -55, -9, -22, -21, -45, -12, 65, -3, -60, -27, -32, -50, -1,
27, -12, 52, 66, 67, 45, -5, 27, 14, -19, 63, 49, -76, -105, -72, -100,
-52, 7, -2, 65, 81, 24, -9, 41, 81, -19, -55, -18, -17, -21, -36, -28,
63, 16, -65, -31, -25, -52, -17, 22, -10, 11, 67, 62, 55, 6, 12, 28,
-25, 43, 69, -49, -109, -65, -95, -72, 4, 4, 15, 82, 38, -15, 24, 81,
-6, -48, -24, -16, -19, -15, -44, 52, 37, -65, -40, 0, -51, -22, 30, -5,
-3, 70, 61, 58, 10, 2, 48, -22, 27, 79, -23, -107, -74, -90, -86, -7,
1, 4, 83, 49, -8, 9, 75, 55, -57, -41, -7, -20, -22, -43, 35, 56,
-48, -58, -6, -44, -42, 27, 12, -12, 51, 65, 70, 22, -10, 46, 24, 6,
77, 1, -105, -84, -81, -104, -16, 10, -11, 59, 64, -3, 1, 69, 67, -15,
-44, -7, -13, -18, -34, 13, 64, -30, -72, -18, -13, -54, 12, 20, -15, 42,
70, 73, 39, -12, 39, 41, -18, 70, 32, -90, -98, -56, -108, -41, 12, -10,
41, 74, 14, -8, 51, 72, -2, -46, -19, -18, -13, -27, -43, 68, -3, -80,
-31, -2, -60, 0, 30, -18, 24, 68, 71, 46, -17, 29, 56, -24, 56, 52,
-71, -105, -61, -103, -61, 10, -1, 29, 85, 28, -11, 39, 78, 17, -42, -31,
-19, -10, -23, -46, 62, 27, -72, -49, 4, -41, -18, 38, -17, 6, 74, 64,
57, -5, 13, 59, -10, 41, 70, -42, -109, -71, -70, -81, 2, 0, 11, 81,
78, -13, 26, 81, 30, -41, -36, -20, -15, -19, -39, 9, 44, -60, -57, 3,
-30, -62, 39, -6, -1, 70, 64, 64, 0, -2, 61, 1, -22, 80, -19, -104,
-81, -72, -105, -14, 4, 6, 68, 82, -4, 14, 77, 45, -33, -51, -21, -18,
-17, -40, -11, 65, -45, -68, -4, -14, -60, 32, 6, -11, 58, 67, 65, 10,
-11, 52, 19, -25, 84, -2, -102, -89, -74, -107, -33, 8, 6, 56, 85, 43,
-1, 64, 62, -20, -54, -21, -15, -12, -31, -25, 57, -22, -75, -8, -4, -60,
-19, 18, -14, 46, 72, 68, 25, -25, 37, 38, -28, 42, 29, -92, -97, -69,
-98, -88, 6, 2, 39, 79, 56, -9, 47, 77, -1, -55, -37, -20, -17, -22,
-32, 38, 59, -80, -23, 9, -56, -39, 30, -16, 28, 75, 66, 52, -20, 29,
44, -23, 27, 89, -79, -105, -69, -91, -95, 3, 4, 29, 73, 60, 5, 31,
80, 21, -44, -42, -23, -20, -25, -35, 25, 69, -77, -34, 20, -47, -50, 30,
-10, 17, 71, 68, 60, 13, 7, 51, -7, 4, 88, -45, -110, -77, -81, -105,
-43, 0, 16, 72, 72, 12, -11, 78, 39, -35, -52, -26, -25, -28, -35, 10,
74, -8, -54, 22, -29, -61, 20, -3, 4, 66, 67, 61, 27, -2, 52, 8,
-7, 80, 46, -105, -81, -72, -105, -56, -1, 3, 69, 81, 20, -13, 76, 51,
-20, -46, -37, -23, -21, -36, -7, 71, 19, -68, 15, -10, -70, -2, 34, -7,
57, 70, 65, 36, -17, 46, 17, -17, 66, 67, -94, -84, -64, -97, -67, 4,
-3, 54, 85, 31, -14, 34, 66, -11, -45, -39, -34, -18, -36, -28, 63, 46,
-73, 5, 9, -68, -15, 44, -8, 46, 73, 67, 46, -14, 38, 30, -23, 49,
80, -40, -91, -65, -96, -81, -9, 4, 42, 81, 46, -8, 17, 80, 4, -51,
-35, -31, -31, -26, -43, 40, 65, -54, -66, 24, -60, -38, 42, 2, 31, 73,
69, 62, 4, -13, 43, -12, 25, 83, -7, -98, -70, -81, -88, -22, 9, 27,
83, 62, -8, -2, 82, 14, -54, -33, -33, -35, -11, -52, 19, 79, -33, -81,
33, -47, -53, 40, 13, -9, 74, 63, 61, 20, -19, 42, -2, 6, 85, 25,
-90, -77, -77, -98, -35, 15, 0, 77, 75, 7, -13, 59, 38, -43, -37, -33,
-38, -7, -52, -1, 80, -4, -80, 3, -30, -65, 28, 21, -20, 71, 70, 65,
29, -19, 18, 4, -10, 76, 48, -70, -94, -78, -98, -46, 9, -1, 67, 78,
24, -12, 38, 84, -36, -47, -32, -44, -13, -21, -24, 73, 26, -75, -21, -9,
-65, 11, 31, -20, 30, 71, 60, 43, -12, 2, 41, -8, 60, 68, -48, -101,
-66, -102, -70, 9, 3, 21, 85, 39, -9, 24, 82, 26, -51, -39, -47, -17,
-12, -36, 60, 53, -57, -43, 24, -59, -16, 34, -9, 15, 75, 64, 50, -7,
-12, 41, -10, 43, 82, -23, -101, -75, -94, -88, -5, 4, 9, 87, 56, -7,
0, 77, 46, -52, -39, -47, -25, -7, -48, 41, 70, -39, -58, 17, -51, -32,
32, -5, 5, 69, 64, 61, 6, -24, 29, 19, 26, 88, 5, -94, -86, -83,
-97, -21, 7, 1, 64, 66, 8, -5, 64, 66, -21, -41, -50, -32, -5, -44,
18, 78, -11, -67, 2, 7, -46, 27, 9, -5, 61, 72, 65, 17, -26, 19,
26, 14, 83, 31, -85, -96, -67, -103, -36, 12, -3, 49, 91, 11, -11, 57,
72, -7, -42, -54, -41, -11, -40, -44, 74, 16, -60, -14, 9, -49, 14, 12,
-14, 48, 73, 68, 31, -27, 6, 33, -4, 73, 59, -64, -104, -64, -85, -52,
15, 1, 35, 92, 20, -22, 45, 83, 4, -39, -50, -45, -9, -30, -55, 26,
33, -58, -25, 16, -40, 8, 23, -17, 31, 71, 67, 42, -23, -5, 35, -2,
58, 72, -40, -106, -73, -76, -73, 2, 1, 21, 80, 70, -20, 25, 88, 28,
-34, -48, -52, -12, -15, -61, -2, 54, -51, -42, 23, -24, -43, 31, -19, 16,
69, 62, 57, -15, -21, 36, 9, 2, 86, -10, -104, -86, -70, -98, -10, 7,
12, 69, 79, -14, 9, 86, 46, -27, -34, -57, -30, -7, -53, -30, 65, -23,
-52, 9, -7, -45, 28, -13, 3, 65, 58, 67, 4, -34, 23, 25, -5, 57,
20, -95, -100, -71, -98, -21, 13, 4, 62, 88, 24, -6, 78, 66, -19, -40,
-41, -41, -12, -39, -44, 44, 5, -57, -7, 7, -42, -2, -2, -13, 56, 63,
67, 57, -35, 8, 34, -2, 40, 49, -76, -105, -67, -90, -81, 16, 2, 48,
90, 39, -18, 61, 83, 3, -39, -41, -41, -15, -32, -53, 20, 63, -56, -30,
15, -34, -20, 10, -24, 42, 66, 60, 63, -32, -6, 35, 4, 27, 86, -55,
-108, -70, -86, -96, 11, 0, 33, 90, 55, -12, 39, 92, 24, -40, -40, -52,
-24, -24, -59, 0, 73, -42, -40, 14, -25, -27, 32, -22, 29, 69, 58, 66,
9, -18, 36, 9, 16, 79, -31, -106, -76, -74, -98, -27, 1, 19, 88, 66,
-7, -9, 91, 40, -33, -38, -50, -33, -15, -58, -21, 69, 25, -49, 10, -13,
-37, 25, 12, 9, 67, 58, 66, 26, -33, 33, 15, 4, 73, 49, -103, -83,
-67, -105, -46, 18, 0, 72, 78, 11, -17, 84, 59, -22, -37, -41, -54, -13,
-53, -45, 56, 43, -50, 7, 0, -44, 12, 24, -5, 59, 61, 67, 44, -39,
28, 30, -5, 58, 68, -45, -94, -61, -98, -59, 20, -5, 51, 84, 30, -23,
29, 74, -13, -37, -35, -61, -14, -41, -62, 39, 64, -34, -8, 11, -39, -4,
32, -11, 47, 63, 70, 58, -33, 11, 38, -4, 44, 77, -19, -101, -60, -92,
-80, 14, 5, 34, 84, 43, -17, 14, 85, 3, -32, -28, -55, -39, -37, -70,
19, 72, -16, -48, 17, -33, -22, 27, -10, 31, 62, 68, 70, -19, -44, 51,
3, 31, 82, 10, -92, -64, -81, -96, -5, 16, 14, 79, 59, -9, -7, 74,
17, -37, -20, -52, -59, -12, -74, -8, 83, 7, -61, 29, -20, -39, 27, 3,
-13, 70, 59, 67, 1, -60, 17, 12, 12, 77, 37, -79, -71, -65, -101, -17,
27, -17, 74, 75, 2, -16, 64, 82, -41, -17, -35, -73, -18, -70, -39, 75,
30, -64, -10, 0, -45, 18, 16, -12, 45, 63, 70, 9, -56, 15, 20, 9,
73, 52, -60, -110, -61, -98, -41, 25, -11, 59, 77, 18, -21, 43, 93, -35,
-26, -20, -73, -34, -21, -60, 58, 53, -56, -31, 16, -48, 4, 22, -15, 42,
59, 70, 34, -54, -3, 55, 0, 61, 65, -38, -110, -57, -96, -65, 27, -2,
6, 83, 26, -21, 28, 93, 29, -30, -13, -68, -49, -14, -75, 33, 73, -39,
-50, 39, -45, -13, 35, -13, 26, 71, 66, 45, -44, -19, 51, -1, 49, 76,
-12, -102, -75, -86, -87, 20, 8, -15, 67, 39, -19, 17, 91, 50, -35, -15,
-61, -60, -19, -68, 12, 80, -21, -62, 36, 15, -39, 38, -3, 8, 73, 67,
56, -28, -32, 50, 24, 28, 81, 14, -94, -88, -47, -100, 5, 22, -24, 53,
56, -12, -1, 76, 70, -25, -14, -40, -71, -29, -52, -65, 79, 10, -72, 17,
43, -59, 26, 13, -4, 59, 72, 65, -18, -48, 36, 36, 9, 79, 46, -76,
-105, -51, -105, -24, 28, -19, 36, 89, 4, -14, 57, 85, -10, -20, -25, -72,
-37, -42, -78, 70, 34, -72, 1, 58, -50, 19, 26, -15, 48, 75, 67, 5,
-50, 15, 49, -1, 66, 70, -51, -113, -58, -76, -48, 31, -13, 18, 87, 16,
-12, 40, 89, 19, -41, -26, -67, -46, -39, -75, -1, 52, -58, -19, 64, -29,
0, 40, -9, 35, 70, 72, 21, -53, 1, 52, 4, 14, 75, -23, -104, -68,
-70, -67, 23, -9, 4, 83, 61, -3, 30, 82, 38, -33, -24, -70, -57, -29,
-74, -29, 75, -46, -52, 62, 0, -69, 48, 1, 12, 61, 77, 71, -49, -15,
52, 17, 4, 74, 5, -90, -82, -67, -101, 11, 1, -12, 69, 74, 15, 22,
80, 55, -25, -27, -63, -72, -34, -65, -51, 61, -16, -66, 46, 29, -70, 41,
13, 4, 56, 69, 75, -37, -39, 47, 33, -4, 52, 30, -81, -94, -63, -101,
-9, 13, -20, 53, 87, 30, 8, 68, 70, -11, -30, -22, -76, -45, -58, -65,
37, 14, -74, 18, 55, -56, -27, 28, -5, 43, 69, 70, 30, -42, 27, 48,
2, 33, 50, -64, -104, -64, -92, -83, 22, -16, 34, 94, 48, -1, 58, 80,
5, -36, -20, -72, -53, -48, -71, 13, 77, -68, -9, 62, -33, -45, 39, 1,
30, 66, 75, 39, -42, 17, 46, 7, 25, 71, -38, -99, -74, -87, -94, -9,
-18, 19, 88, 56, 10, 45, 87, 30, -34, -20, -43, -69, -42, -67, -15, 76,
8, -33, 61, -12, -58, 28, 5, 20, 63, 70, 44, -21, 3, 52, 22, 18,
67, 39, -105, -83, -77, -111, -30, -10, -1, 81, 69, 14, 13, 84, 44, -27,
-21, -34, -76, -37, -58, -36, 63, 33, -50, 50, 13, -59, 10, 33, 9, 50,
67, 57, -6, -15, 50, 34, 8, 59, 62, -97, -93, -72, -115, -51, 15, -18,
74, 81, 19, 1, 74, 64, -17, -28, -19, -73, -41, -51, -56, 53, 55, -57,
40, 29, -61, 0, 42, 3, 48, 68, 64, 6, -42, 38, 43, 4, 45, 77,
-24, -107, -67, -101, -73, 9, -20, 51, 84, 34, 2, 30, 79, -3, -35, -13,
-63, -83, -39, -70, 15, 68, -32, 9, 47, -43, -19, 43, 9, 38, 62, 73,
20, -44, -7, 48, 11, 33, 80, 2, -113, -70, -92, -90, -1, -9, 30, 90,
47, 7, 26, 81, 11, -35, -13, -54, -87, -34, -73, -9, 76, -13, -58, 57,
-31, -41, 39, 13, 3, 57, 74, 43, -30, -22, 56, 28, 17, 72, 32, -88,
-76, -83, -99, -12, -1, 5, 87, 58, 10, 14, 69, 28, -36, -14, -39, -89,
-48, -73, -40, 75, 18, -67, 58, -8, -54, 30, 28, -3, 55, 70, 55, -14,
-39, 26, 41, 0, 58, 59, -68, -86, -67, -102, -31, 12, -31, 77, 72, 16,
9, 63, 79, -29, -17, -30, -88, -60, -65, -66, 56, 45, -62, -3, 17, -51,
22, 39, -8, 30, 66, 56, 3, -41, 9, 54, -3, 38, 77, -33, -117, -58,
-99, -63, 12, -24, 11, 82, 27, 3, 49, 88, -23, -27, -16, -81, -77, -31,
-85, 26, 69, -48, -35, 62, -49, -5, 53, 0, 11, 69, 67, 22, -38, -7,
63, 1, 20, 79, -7, -109, -83, -96, -81, 1, -20, -4, 84, 33, 10, 38,
84, 44, -30, -15, -67, -83, -34, -71, -7, 71, -22, -56, 42, -32, -30, 54,
12, -1, 58, 68, 35, -23, -24, 53, 16, -1, 76, 22, -97, -90, -83, -94,
-12, -7, -19, 63, 48, 3, 20, 80, 62, -35, -13, -56, -92, -37, -55, -39,
72, 12, -66, 19, 45, -45, 43, 33, -7, 45, 69, 44, -14, -31, 39, 62,
-9, 63, 40, -80, -93, -62, -97, -26, 2, -26, 45, 62, 8, 15, 68, 74,
-1, -16, -45, -91, -45, -42, -91, 54, 36, -66, -11, 50, -48, 22, 43, -4,
32, 69, 56, 2, -39, 26, 71, 5, 52, 61, -58, -100, -65, -101, -44, -1,
-32, 29, 92, 10, 8, 57, 80, 19, -26, -29, -84, -55, -37, -95, 40, 54,
-58, -29, 53, -13, 3, 52, 1, 19, 72, 67, 17, -31, 7, 68, 19, 36,
71, -34, -101, -64, -79, -66, 1, -29, 9, 88, 52, 9, 45, 79, 40, -21,
-20, -70, -66, -34, -87, -53, 67, -42, -50, 49, 8, -15, 55, 9, 5, 63,
68, 33, -25, -12, 66, 33, -14, 72, -8, -101, -70, -58, -89, -2, -16, -13,
79, 71, 5, 36, 80, 53, -18, -22, -57, -71, -36, -79, -76, 71, -15, -63,
26, 28, -36, 44, 24, 7, 52, 71, 62, -20, -20, 59, 40, -22, 71, 13,
-98, -86, -50, -96, -16, -7, -25, 68, 85, 16, 25, 83, 67, -13, -19, -42,
-77, -35, -69, -93, 28, 3, -68, 14, 35, -34, 4, 27, 1, 47, 68, 61,
-9, -30, 43, 50, -16, 26, 35, -80, -96, -55, -86, -74, -8, -37, 48, 94,
30, 15, 74, 81, -5, -33, -11, -76, -44, -54, -100, -1, 71, -68, -4, 47,
-25, -7, 34, -7, 37, 68, 65, 38, -32, 30, 61, -6, 10, 74, -65, -106,
-53, -78, -90, 2, -43, 21, 98, 47, 4, 56, 92, 16, -41, -7, -70, -53,
-41, -99, -25, 71, -60, -23, 43, -16, -20, 43, -1, 25, 62, 70, 52, -33,
12, 60, 3, 0, 75, -41, -110, -57, -65, -103, -22, -33, -8, 90, 63, 2,
37, 92, 39, -37, -9, -26, -56, -32, -98, -56, 66, 11, -44, 42, 4, -27,
31, 5, 16, 60, 70, 59, 6, -4, 56, 14, -9, 70, 49, -106, -66, -54,
-105, -47, -18, -23, 75, 77, 12, 2, 79, 51, -27, -12, -16, -67, -27, -84,
-79, 46, 30, -58, 30, 15, -24, 21, 27, 15, 52, 67, 65, 24, -23, 45,
32, -15, 43, 70, -99, -86, -38, -96, -72, 13, -40, 52, 93, 19, -7, 47,
65, -21, -12, -3, -66, -22, -64, -100, 19, 56, -56, 10, 34, -16, 6, 32,
14, 36, 64, 70, 34, -15, 33, 41, -9, 31, 76, -21, -97, -46, -87, -87,
3, -43, 27, 97, 34, -12, 33, 78, -12, -19, 3, -61, -56, -49, -103, -9,
60, -29, -8, 33, -8, 0, 26, 15, 29, 54, 68, 48, 1, -4, 45, -1,
16, 77, 8, -103, -55, -71, -97, -15, -7, -1, 96, 56, -16, 13, 88, 1,
-32, 13, -43, -72, -28, -97, -43, 56, -2, -48, 33, 1, -4, 31, 21, 6,
51, 71, 50, 12, -5, 40, 10, -5, 68, 40, -83, -63, -58, -102, -37, 8,
-40, 82, 75, -9, 0, 76, 21, -31, 8, -28, -72, -27, -89, -69, 43, 19,
-49, -1, 12, -4, 24, 26, 10, 41, 69, 61, 24, -5, 16, 15, -16, 57,
60, -65, -103, -52, -97, -63, 9, -28, 53, 83, 3, -18, 62, 86, -35, 14,
-3, -74, -33, -31, -92, 23, 38, -49, -19, 19, -9, 19, 33, 13, 19, 71,
65, 37, 3, 4, 26, -22, 33, 78, -35, -106, -45, -87, -81, 1, -19, -19,
87, 15, -24, 45, 92, -26, 4, 9, -64, -42, -23, -102, 0, 52, -39, -38,
29, -5, 12, 31, 17, 17, 61, 64, 44, 16, -3, 30, -9, 11, 78, -8,
-109, -69, -75, -99, -7, -9, -40, 94, 32, -24, 34, 90, 33, -8, 9, -50,
-49, -23, -79, -36, 54, -12, -54, 16, -2, 7, 36, 25, 12, 39, 69, 48,
28, -2, 20, 33, 0, 69, 18, -100, -84, -60, -109, -21, 6, -54, 37, 53,
-29, 14, 91, 50, -20, 15, -40, -59, -24, -65, -63, 48, 5, -64, 9, 25,
-3, 40, 26, 8, 36, 70, 52, 33, -1, 10, 39, -10, 61, 50, -82, -104,
-40, -107, -47, 15, -47, 11, 100, -17, 2, 87, 66, -14, 20, -26, -62, -25,
-54, -109, 29, 18, -66, -7, 32, -7, 39, 27, 5, 31, 66, 61, 43, 5,
0, 39, 3, 45, 68, -56, -109, -46, -97, -68, 16, -37, -16, 93, -6, -18,
73, 82, -6, -7, -8, -60, -29, -37, -98, 5, 38, -57, -32, 37, -4, 27,
42, 7, 15, 67, 74, 45, 25, -3, 28, 18, 30, 74, -30, -113, -58, -51,
-90, 12, -21, -37, 82, 69, -28, 54, 91, 13, -13, -3, -57, -37, -25, -90,
-79, 56, -42, -54, 40, 9, -14, 54, 14, 2, 54, 73, 45, 28, -6, 19,
22, -8, 75, 3, -106, -72, -37, -99, -10, -6, -43, 61, 83, -35, 33, 93,
32, -14, 14, -46, -38, -21, -82, -95, 21, -27, -68, 24, 13, -13, 54, 22,
11, 53, 76, 62, 38, -2, 12, 25, -11, 37, 26, -101, -90, -35, -90, -31,
5, -49, 36, 95, -6, 11, 93, 46, -17, 13, -33, -41, -14, -63, -100, 2,
-4, -78, 15, 21, -27, 38, 22, -6, 46, 74, 56, 44, 2, 6, 33, -5,
21, 50, -84, -102, -33, -73, -97, 10, -40, 7, 93, 19, -5, 82, 60, -13,
1, 1, -43, -15, -47, -102, -32, 55, -77, -16, 41, -14, 14, 45, 0, 23,
69, 68, 54, 15, 6, 26, 0, 10, 75, -61, -108, -42, -63, -104, 6, -30,
-15, 87, 44, -40, 73, 76, -8, -5, 13, -37, -13, -29, -103, -56, 58, -75,
-39, 47, -8, 3, 60, -3, 18, 69, 69, 60, 41, 1, 25, 4, 0, 66,
-34, -111, -56, -53, -102, -43, -15, -27, 70, 68, -34, -7, 93, 6, -15, 16,
-27, -14, -24, -97, -73, 41, 7, -58, 37, -2, -5, 60, 24, 15, 59, 68,
74, 48, -2, 28, 11, -13, 55, 56, -111, -70, -44, -101, -61, -3, -36, 53,
81, -20, -26, 100, 27, -19, 22, -17, -40, -18, -88, -83, 28, 24, -74, 32,
14, -19, 50, 36, 3, 52, 70, 71, 52, 11, 18, 15, -14, 41, 67, -98,
-87, -41, -92, -83, 6, -34, 42, 89, -2, -32, 54, 48, -18, 12, -10, -41,
-12, -79, -96, 10, 46, -69, 19, 31, -24, 37, 47, -7, 45, 70, 72, 55,
17, 18, 20, -15, 22, 73, -22, -103, -44, -79, -99, -10, -8, 16, 91, 22,
-33, 36, 60, -16, 8, 0, -47, -15, -58, -101, -21, 47, -49, -65, 40, -18,
22, 55, 3, 34, 65, 69, 60, 22, 4, 24, -13, 7, 79, 8, -105, -45,
-66, -105, -26, 1, -5, 86, 44, -33, 15, 90, -9, -4, 14, -41, -19, -9,
-105, -42, 41, -32, -75, 41, -12, 14, 57, 7, 2, 63, 70, 61, 30, 10,
22, -8, -6, 69, 31, -92, -54, -55, -108, -47, 9, -31, 76, 59, -22, 6,
81, 6, -14, 15, -36, -24, 3, -106, -60, 38, -14, -85, 9, -6, 7, 64,
16, -2, 54, 70, 66, 36, 11, 21, 3, -10, 56, 45, -73, -100, -47, -101,
-65, 10, -25, 64, 77, -11, -6, 73, 68, -22, 14, -26, -39, 3, -54, -80,
20, 8, -84, -19, 7, -8, 52, 27, 1, 31, 64, 71, 45, 16, 22, 21,
-13, 52, 57, -61, -107, -43, -96, -80, 3, -20, -7, 87, 2, -20, 57, 77,
-6, 6, -10, -40, 1, -37, -91, 1, 17, -76, -39, 36, -10, 46, 33, -2,
28, 53, 67, 50, 14, 17, 31, -24, 32, 72, -31, -108, -57, -82, -96, -8,
-8, -19, 74, 23, -23, 40, 86, 14, -2, 4, -41, -6, -18, -96, -18, 22,
-68, -59, 29, -10, 40, 42, 4, 21, 47, 70, 58, 25, 14, 34, 5, 14,
78, -4, -109, -73, -68, -104, -20, -3, -28, 59, 41, -23, 22, 87, 34, -27,
5, -45, -11, -1, -88, -33, 23, -58, -76, 15, 10, 29, 45, 7, 14, 38,
59, 64, 32, 16, 32, 15, 1, 73, 23, -97, -89, -39, -107, -35, 8, -30,
39, 86, -9, 13, 80, 56, -21, 9, -38, -28, 6, -70, -95, 18, -37, -82,
2, 23, 4, 51, 15, 14, 35, 57, 67, 30, 15, 32, 15, -23, 61, 41,
-80, -103, -44, -74, -57, 17, -22, 12, 88, 2, -4, 68, 76, -13, -10, -26,
-44, 10, -53, -107, -25, -25, -86, -16, 21, -3, 54, 19, 12, 39, 48, 67,
45, 17, 30, 24, -19, 9, 59, -62, -110, -45, -59, -78, 12, -13, -2, 81,
45, -8, 57, 84, 0, -15, -12, -58, 4, -30, -105, -43, -14, -84, -33, 16,
-4, 33, 25, 12, 38, 47, 62, 56, 18, 27, 39, -18, -12, 70, -36, -116,
-63, -45, -106, -1, -5, -19, 70, 60, -17, 41, 91, 17, -20, 25, -60, -7,
-9, -96, -64, 14, -79, -56, 18, 2, 19, 31, 13, 31, 43, 61, 72, 22,
23, 45, -6, -24, 59, -13, -109, -71, -37, -100, -14, 6, -34, 58, 77, -7,
27, 89, 40, -26, 19, -15, -27, 1, -93, -87, 10, -73, -71, 16, 9, 14,
50, 17, 32, 43, 62, 79, 49, 19, 48, 11, -36, 36, 16, -100, -88, -34,
-80, -85, 23, -29, 33, 89, 10, -11, 82, 61, -23, 5, 1, -44, 11, -70,
-101, -3, -8, -85, 4, 12, 6, 40, 23, 24, 31, 56, 79, 55, 24, 46,
31, -30, 12, 73, -84, -99, -41, -70, -94, 20, -26, 8, 87, 25, -19, 78,
75, -20, -6, 15, -57, 14, -47, -109, -23, 4, -87, -11, 17, 2, 35, 29,
18, 35, 52, 73, 59, 21, 47, 43, -31, -9, 72, -67, -111, -45, -56, -105,
-19, -11, -14, 89, 46, -26, 26, 80, -4, -15, 17, -49, -1, -27, -110, -50,
9, -64, -26, 18, 5, 35, 33, 15, 39, 49, 69, 66, 29, 35, 55, -14,
-29, 62, 32, -117, -62, -48, -108, -41, 28, -32, 74, 61, -19, 10, 87, 20,
-23, 18, -30, -48, -7, -93, -70, 4, -46, -83, 11, 6, 30, 34, 9, 36,
46, 62, 72, 42, 13, 56, 7, -33, 46, 53, -72, -76, -39, -103, -65, 31,
-38, 56, 81, -6, 0, 69, 41, -28, 11, -12, -59, 5, -78, -86, 0, -32,
-88, 3, 10, 22, 39, 18, 18, 48, 63, 69, 53, 19, 48, 25, -39, 21,
67, -45, -90, -42, -93, -85, 20, -8, 26, 92, 11, -13, 54, 57, -26, -5,
0, -59, -12, -56, -94, -15, -16, -83, -49, 13, 18, 43, 23, 14, 45, 62,
72, 53, 28, 29, 38, -33, -2, 76, -12, -110, -47, -83, -101, 1, 7, -4,
91, 36, -19, 40, 88, -13, -13, 8, -56, -27, 8, -100, -32, -2, -72, -66,
13, 16, 36, 24, 10, 31, 51, 74, 58, 30, 31, 52, -14, -15, 73, 19,
-99, -52, -68, -109, -18, 17, -45, 89, 50, -17, 26, 78, 49, -25, 12, -42,
-51, 13, -92, -55, 9, -58, -79, -4, 5, 26, 33, 10, 28, 44, 68, 69,
36, 29, 53, -1, -25, 56, 36, -87, -99, -62, -109, -46, 21, -36, 10, 70,
-9, 11, 77, 69, -28, 14, -21, -59, 5, -32, -73, 7, -45, -94, -20, 2,
13, 41, 20, 17, 43, 66, 71, 47, 25, 45, 50, -32, 37, 56, -66, -111,
-51, -102, -74, 22, -19, -17, 83, 8, -4, 57, 82, 0, 1, -9, -66, -11,
-14, -89, -3, -16, -91, -40, 22, 8, 40, 31, 20, 39, 53, 73, 50, 25,
39, 55, -34, 18, 73, -37, -115, -68, -90, -90, 16, 2, -33, 71, 23, -11,
48, 89, 17, -8, 8, -67, -28, 2, -83, -21, -4, -81, -57, 13, 5, 32,
31, 21, 37, 44, 75, 56, 29, 39, 56, 11, 1, 78, -5, -108, -78, -57,
-107, -3, 19, -41, 45, 43, -15, 27, 86, 38, -37, 14, -57, -44, 9, -67,
-81, 8, -67, -69, 6, 7, 28, 34, 22, 35, 40, 63, 61, 28, 32, 54,
23, -31, 70, 19, -95, -92, -54, -108, -35, 28, -29, 22, 86, -9, 13, 81,
59, -33, 18, -46, -64, 13, -44, -94, 11, -48, -81, -6, 11, 3, 39, 19,
32, 44, 55, 70, 36, 29, 52, 37, -23, 54, 43, -75, -98, -59, -81, -58,
29, -20, -8, 87, -2, -2, 72, 72, -26, -19, -21, -77, 2, -21, -100, -33,
-29, -90, -22, 17, -1, 44, 24, 23, 43, 52, 75, 43, 27, 52, 46, -14,
-3, 59, -60, -103, -62, -74, -76, 21, -3, -25, 78, 60, -9, 60, 79, -12,
-31, 27, -80, -12, 4, -97, -54, -8, -88, -40, 20, 0, 16, 31, 19, 39,
53, 73, 66, 33, 49, 48, 4, -11, 65, -37, -104, -70, -68, -99, 5, 16,
-31, 59, 77, -10, 43, 86, 7, -47, 21, -71, -35, 14, -82, -73, 12, -83,
-52, 17, -1, 6, 37, 18, 35, 53, 68, 67, 35, 42, 51, 18, -16, 48,
-14, -105, -77, -59, -98, -12, 32, -34, 30, 86, 2, 22, 90, 28, -51, 18,
-3, -52, 25, -62, -88, 11, -71, -70, 10, 0, 1, 32, 14, 34, 49, 64,
71, 46, 41, 55, 31, -11, 38, 6, -97, -88, -62, -90, -81, 31, -25, 12,
90, 19, -22, 85, 53, -45, -6, 15, -70, 13, -38, -93, -1, -3, -80, 7,
12, -10, 30, 31, 27, 45, 61, 71, 46, 39, 50, 40, -6, 19, 64, -82,
-100, -58, -78, -97, -1, -7, -9, 87, 38, -25, 76, 65, -28, -20, 13, -59,
1, -27, -95, -19, 7, -80, -11, 18, -14, 22, 34, 27, 50, 56, 72, 56,
41, 50, 42, 3, 8, 62, -4, -105, -68, -74, -102, -28, 6, -21, 71, 55,
-25, 20, 79, -15, -30, 14, -49, -47, -14, -94, -31, 13, -70, -25, 21, -12,
12, 37, 13, 48, 52, 70, 64, 38, 57, 47, 6, -4, 61, 22, -109, -74,
-68, -103, -50, 30, -25, 55, 71, -11, 3, 92, 9, -38, 17, -36, -61, 2,
-92, -50, 19, -56, -89, 26, -7, -6, 36, 17, 42, 46, 64, 76, 46, 44,
54, 23, -11, 47, 45, -74, -80, -63, -99, -65, 28, -28, 39, 81, -3, -8,
70, 29, -48, 12, -12, -79, 5, -72, -72, 20, -31, -97, 24, 3, -22, 32,
26, 17, 50, 60, 75, 55, 48, 54, 38, -5, 33, 63, -52, -89, -64, -99,
-85, 7, 4, 19, 86, 11, -12, 59, 87, -34, -7, 5, -70, -13, -51, -87,
8, -13, -102, -44, 14, -29, 23, 30, 12, 45, 57, 77, 63, 48, 48, 47,
-7, 11, 72, -23, -109, -61, -84, -96, -8, 17, -28, 93, 31, -17, 45, 87,
-29, -32, 9, -68, -37, 16, -100, -10, 10, -90, -65, 29, -27, 5, 34, 12,
32, 59, 77, 62, 51, 51, 53, 5, -3, 66, 3, -100, -67, -72, -103, -33,
26, -25, 79, 52, -18, 29, 91, 45, -41, 13, -49, -55, 18, -95, -30, 21,
-72, -78, 18, -19, -9, 30, 12, 27, 48, 72, 62, 43, 50, 48, 15, -10,
56, 25, -91, -95, -71, -101, -50, 29, -15, 13, 69, -20, 12, 89, 65, -45,
13, -28, -65, 10, -43, -49, 23, -58, -89, 2, 14, -22, 24, 16, 26, 50,
77, 71, 44, 56, 54, 44, -10, 47, 43, -77, -101, -75, -100, -70, 18, -2,
-1, 79, -9, 1, 73, 77, -14, -2, -13, -70, -2, -24, -96, 21, -37, -94,
-14, 20, -27, 18, 18, 21, 45, 55, 73, 45, 47, 54, 51, 12, 32, 61,
-55, -107, -76, -96, -86, 5, 10, -15, 74, 6, -7, 62, 86, 7, -15, 1,
-71, -16, -5, -96, 11, -14, -102, -38, 27, -26, 12, 23, 17, 45, 52, 73,
54, 47, 53, 55, 25, 20, 65, -33, -108, -81, -78, -96, -6, 21, -24, 60,
19, -18, 48, 85, 30, -41, 5, -62, -33, 1, -87, -55, 1, -88, -56, 23,
-12, -3, 23, 13, 37, 50, 65, 62, 41, 52, 60, 29, -5, 67, -6, -103,
-92, -72, -108, -38, 30, -21, 33, 86, -24, 36, 84, 44, -29, -4, -51, -47,
9, -73, -75, 9, -72, -69, 13, 1, -31, 25, 11, 24, 52, 66, 71, 51,
50, 55, 48, -5, 61, 24, -96, -101, -66, -95, -62, 32, -19, 8, 94, 9,
21, 83, 57, -19, -12, -37, -55, 10, -53, -86, 4, -57, -77, 7, 8, -30,
10, 10, 24, 47, 55, 75, 49, 42, 58, 57, 1, 11, 42, -78, -109, -73,
-80, -79, 23, -6, -9, 89, 22, 1, 75, 68, -7, -20, 7, -59, 4, -31,
-92, -14, -33, -87, -13, 20, -34, -7, 15, 12, 47, 53, 72, 71, 41, 53,
67, 17, -1, 58, -57, -106, -79, -75, -102, 5, 8, -24, 79, 45, -35, 65,
77, 9, -30, 10, -62, -10, -15, -95, -34, 17, -89, -29, 33, -27, -22, 33,
3, 38, 57, 66, 66, 48, 44, 66, 35, -11, 60, -30, -106, -86, -75, -102,
-73, 22, -35, 55, 67, -32, 54, 81, 27, -31, 4, -18, -25, -1, -85, -55,
22, -43, -50, 30, -18, -32, 26, 1, 30, 57, 68, 71, 56, 44, 63, 46,
-10, 47, 57, -97, -91, -75, -94, -89, 31, -31, 27, 84, -19, -6, 80, 42,
-22, -6, -3, -53, 3, -63, -73, 14, -19, -69, 18, -7, -37, 20, 12, 24,
56, 60, 73, 59, 43, 61, 54, -4, 32, 67, -86, -93, -77, -87, -97, -7,
-16, 1, 86, 1, -20, 83, 58, -9, -11, 9, -48, -2, -42, -88, -4, 2,
-84, 8, 5, -47, 11, 21, 9, 54, 60, 74, 64, 48, 60, 61, 8, 18,
73, -16, -100, -81, -85, -106, -31, -7, -20, 83, 24, -32, 47, 69, 1, -22,
12, -33, -41, -23, -92, -26, 19, -72, -5, 20, -43, 3, 30, -9, 47, 58,
68, 66, 50, 50, 60, 22, 8, 67, 7, -108, -85, -76, -107, -58, 29, -34,
72, 54, -38, 29, 88, 16, -25, 13, -14, -52, -12, -83, -54, 14, -58, -75,
21, -38, -11, 32, -2, 15, 58, 67, 68, 52, 51, 61, 36, 10, 62, 29,
-81, -92, -83, -96, -75, 19, -11, 48, 79, -33, 2, 88, 35, -32, 4, 5,
-52, -23, -70, -67, 10, -36, -79, 21, -29, -22, 28, 3, 8, 55, 66, 69,
52, 53, 58, 46, 13, 59, 49, -68, -90, -88, -98, -87, 0, -1, 22, 92,
-15, -17, 76, 85, -27, -11, 18, -42, -35, -53, -76, 2, -13, -85, -16, -16,
-36, 30, 14, 4, 42, 66, 72, 49, 45, 54, 49, 12, 44, 63, -48, -104,
-82, -96, -92, -16, 8, -26, 91, 9, -23, 57, 86, -13, -29, 25, -25, -47,
-17, -86, -15, 4, -75, -39, 15, -42, 15, 20, 0, 37, 59, 78, 57, 37,
59, 65, 15, 36, 71, -24, -105, -89, -94, -104, -35, 16, -26, 87, 36, -26,
35, 79, 50, -44, 19, -7, -60, -16, -59, -39, 26, -56, -57, 21, -41, 1,
30, 0, 26, 53, 74, 65, 42, 53, 66, 50, 24, 77, 3, -104, -91, -90,
-106, -53, 14, -22, 20, 54, -23, 21, 74, 67, -45, 4, 12, -61, -28, -39,
-62, 24, -36, -72, 3, -6, -13, 27, 8, 20, 47, 72, 70, 42, 50, 66,
61, 20, 69, 33, -87, -101, -78, -103, -68, 10, -15, 4, 67, -23, 8, 67,
69, 0, -8, 15, -53, -32, -28, -95, 18, -14, -77, -6, 3, -22, 27, 9,
6, 41, 64, 72, 54, 52, 59, 73, 34, 56, 56, -64, -103, -88, -102, -87,
-7, -7, -12, 80, -7, -2, 57, 77, 16, -44, 26, -45, -47, -18, -90, 3,
2, -78, -18, 10, -39, 28, 14, 3, 34, 55, 78, 59, 49, 58, 77, 46,
44, 67, -45, -103, -87, -88, -101, -21, 9, -29, 62, 63, -17, 56, 81, 35,
-41, 25, -27, -63, -15, -70, -74, 25, -73, -48, 15, -37, -24, 27, 4, 26,
52, 73, 62, 49, 58, 73, 55, 21, 75, -20, -98, -91, -89, -102, -46, 14,
-26, 41, 81, -25, 44, 78, 49, -31, -17, -10, -69, -17, -57, -91, 36, -56,
-63, 16, -24, -33, 32, 5, 24, 48, 63, 73, 47, 52, 61, 60, 24, 71,
10, -88, -95, -94, -95, -64, 7, -23, 22, 92, -6, 34, 75, 58, -12, -28,
10, -67, -27, -40, -100, -5, -39, -79, 6, -14, -44, 20, 9, 19, 52, 58,
70, 53, 49, 59, 66, 32, 44, 27, -81, -93, -93, -99, -93, -2, -17, 4,
93, 13, 13, 73, 65, 1, -39, 23, -58, -42, -27, -97, -26, 30, -81, -8,
-1, -46, 6, 13, 9, 48, 59, 68, 66, 45, 55, 72, 39, 31, 79, -68,
-98, -86, -97, -98, -12, -2, -16, 84, 43, -37, 68, 74, 16, -41, 14, 2,
-52, -23, -91, -45, 32, -74, -24, 1, -46, -5, 34, -2, 40, 61, 65, 66,
41, 48, 72, 50, 22, 70, -43, -106, -90, -95, -100, -64, 3, -20, 69, 61,
-34, 57, 80, 31, -40, 6, 15, -63, -26, -85, -60, 34, -31, -40, 3, -43,
-15, 29, -1, 31, 61, 67, 65, 51, 42, 70, 54, 16, 67, 40, -105, -93,
-88, -103, -85, 9, -28, 48, 78, -23, 4, 83, 53, -32, -10, 28, -51, -24,
-75, -75, 31, -8, -58, 1, -31, -19, 28, 5, 27, 56, 69, 72, 47, 35,
68, 57, 11, 55, 61, -98, -100, -84, -98, -98, -16, -24, 26, 87, -1, -9,
63, 64, -13, -16, 27, -38, -28, -64, -92, 15, 10, -77, -6, -24, -26, 23,
7, 2, 53, 64, 76, 56, 32, 58, 73, 11, 34, 77, -33, -105, -87, -93,
-106, -28, 5, 5, 93, 11, -18, 51, 73, -1, -18, 34, -25, -53, -50, -98,
-4, 25, -63, -17, -20, -27, 18, 12, 0, 46, 62, 82, 60, 25, 35, 78,
13, 19, 78, -16, -100, -94, -92, -101, -43, 9, -12, 96, 31, -25, 46, 80,
19, -22, 27, -10, -56, -41, -96, -21, 33, -49, -58, -19, -35, 10, 21, -2,
23, 61, 79, 68, 30, 30, 87, 30, 9, 75, 8, -92, -94, -89, -100, -61,
10, -34, 82, 52, -32, 30, 75, 38, -26, 17, 4, -61, -27, -93, -36, 41,
-32, -64, -18, -37, -3, 24, -3, 16, 58, 74, 73, 30, 25, 68, 38, 8,
68, 27, -82, -97, -88, -97, -73, 4, -19, 58, 73, -26, 13, 70, 70, -10,
8, 15, -62, -34, -43, -63, 37, -18, -70, -26, -37, -14, 28, 6, 2, 49,
73, 76, 40, 20, 63, 80, 0, 63, 51, -70, -99, -88, -95, -87, -8, -12,
-22, 89, -22, -2, 73, 73, 5, -3, 25, -49, -50, -28, -84, 26, 2, -78,
-38, -18, -23, 21, 11, 3, 42, 69, 81, 49, 21, 54, 78, 3, 50, 67,
-53, -103, -90, -92, -99, -24, -1, -39, 95, -6, -26, 65, 81, 48, 2, 28,
-36, -57, -21, -87, 4, 23, -73, -49, -10, -33, 17, 19, 0, 40, 62, 78,
59, 22, 45, 76, 43, 35, 78, -22, -104, -90, -93, -100, -38, 4, -35, 47,
14, -38, 49, 82, 59, 10, 22, -20, -68, -26, -68, -23, 39, -58, -64, -9,
-27, 9, 21, 8, 34, 58, 67, 63, 27, 35, 70, 52, 29, 76, -4, -99,
-94, -87, -105, -55, 4, -34, 27, 85, -45, 36, 88, 61, 14, 22, -13, -66,
-25, -54, -91, 48, -36, -81, -17, -21, -20, 21, 9, 27, 55, 72, 61, 40,
34, 59, 65, 17, 76, 19, -90, -98, -89, -99, -73, -2, -30, 5, 95, -46,
16, 88, 66, 24, 14, 1, -66, -33, -35, -96, 40, -11, -83, -26, -19, -25,
17, 7, 30, 55, 68, 78, 47, 29, 45, 64, 22, 66, 42, -77, -102, -90,
-91, -83, -17, -18, -13, 82, 27, -6, 78, 72, 34, 14, 15, -62, -50, -23,
-96, -37, 14, -77, -35, -12, -23, 7, 7, 27, 51, 66, 78, 46, 34, 40,
55, 31, 31, 58, -59, -102, -90, -95, -97, -32, -17, -23, 70, 43, -25, 70,
79, 39, 14, 27, -50, -53, -18, -86, -54, 53, -71, -48, -5, -27, -2, 3,
18, 49, 66, 78, 60, 40, 40, 51, 40, 29, 77, -36, -107, -92, -89, -104,
-37, -11, -33, 61, 60, -45, 55, 81, 50, 19, 27, -1, -65, -21, -73, -74,
39, -57, -64, -6, -30, -14, 18, 12, 49, 69, 75, 67, 35, 36, 52, 40,
21, 73, -22, -104, -95, -91, -101, -89, -3, -36, 39, 80, -33, 44, 85, 58,
28, 24, 10, -70, -27, -58, -87, 25, 19, -76, -7, -20, -21, 17, 7, 41,
70, 71, 63, 46, 31, 41, 41, 20, 64, 59, -99, -96, -86, -96, -95, -6,
-33, 20, 84, -14, -22, 81, 63, 28, 17, 15, -48, -33, -42, -92, 2, 37,
-82, -14, -6, -20, 16, 9, 39, 72, 69, 69, 51, 35, 39, 42, 20, 49,
71, -88, -103, -85, -97, -104, -32, -37, -4, 94, 9, -32, 52, 71, 36, 18,
24, -45, -39, -29, -97, -25, 42, -56, -33, -4, -25, 4, 11, 15, 72, 68,
67, 54, 41, 35, 43, 31, 40, 75, -13, -105, -88, -94, -108, -48, 0, -27,
85, 30, -35, 40, 74, 45, 15, 28, -32, -76, -19, -87, -37, 43, -41, -41,
-3, -24, 2, 7, 7, 73, 66, 69, 58, 42, 36, 38, 34, 30, 75, 9,
-104, -87, -90, -106, -64, 3, -45, 72, 56, -42, 28, 81, 51, 20, 26, -16,
-74, -14, -81, -59, 41, -27, -86, -6, -30, -7, 8, -1, 50, 69, 70, 66,
44, 36, 37, 38, 29, 74, 33, -80, -92, -91, -105, -82, -4, -32, 45, 76,
-29, 6, 76, 61, 27, 25, -3, -72, -39, -67, -77, 30, -2, -83, -28, -29,
-15, 10, -2, 43, 70, 71, 74, 43, 30, 30, 33, 24, 69, 49, -66, -103,
-89, -103, -93, -7, -15, 24, 89, -16, -7, 68, 75, 30, 19, 12, -64, -53,
-19, -88, 15, 14, -80, -44, -22, -23, 7, 0, 33, 73, 67, 73, 51, 29,
28, 42, 18, 63, 64, -51, -98, -84, -95, -103, -25, 0, -44, 90, 1, -23,
64, 78, 35, 14, 20, -50, -63, -17, -92, 0, 31, -73, -63, -7, -25, 4,
4, 26, 67, 72, 71, 53, 39, 20, 32, 25, 46, 75, -30, -100, -88, -92,
-103, -42, 6, -40, 83, 21, -29, 52, 76, 61, 11, 19, -32, -69, -17, -64,
-22, 42, -55, -69, -14, -27, -2, 1, 20, 66, 72, 75, 60, 38, 19, 22,
38, 32, 76, -2, -97, -90, -93, -103, -52, 0, -42, 20, 39, -38, 35, 74,
68, 37, 16, -18, -65, -21, -58, -38, 43, -42, -73, -16, -20, -8, 4, 17,
61, 74, 73, 60, 41, 29, 15, 34, 26, 73, 27, -92, -98, -79, -104, -63,
-3, -41, 1, 87, -32, 26, 73, 72, 49, 5, -12, -63, -32, -45, -96, 46,
-25, -87, -22, -15, -24, 3, 13, 58, 76, 69, 68, 46, 29, 18, 29, 22,
69, 36, -77, -100, -85, -98, -75, -5, -33, -21, 82, -32, 12, 71, 74, 56,
5, 5, -58, -42, -30, -92, 40, -1, -88, -40, -6, -22, 2, 15, 50, 80,
70, 67, 45, 24, 14, 27, 21, 65, 57, -64, -104, -82, -83, -91, -11, -24,
-44, 74, 29, -9, 73, 79, 63, 5, 12, -45, -51, -28, -91, -29, 18, -84,
-52, -6, -16, -9, 12, 49, 82, 69, 69, 49, 21, 16, 27, 24, 30, 74,
-37, -106, -90, -82, -104, -27, -14, -62, 56, 58, -28, 68, 80, 70, 15, 2,
-29, -57, -22, -78, -54, 50, -70, -69, -10, -12, -16, 8, 46, 79, 76, 72,
69, 29, 19, 23, 22, 24, 74, -17, -102, -96, -85, -102, -47, -9, -63, 31,
75, -35, 54, 82, 77, 22, -1, 19, -62, -29, -65, -68, 33, -56, -77, -19,
-6, -18, -14, 53, 81, 76, 71, 71, 34, 17, 18, 25, 18, 59, 9, -97,
-100, -85, -98, -96, -3, -60, 4, 89, -21, 39, 78, 77, 33, -10, 23, -64,
-35, -52, -87, 20, 22, -86, -24, 2, -17, -16, 50, 80, 77, 70, 67, 52,
21, 11, 30, 23, 51, 74, -84, -98, -87, -98, -102, -5, -51, -22, 91, -1,
-31, 80, 71, 41, -3, 22, -18, -40, -42, -93, -2, 37, -87, -35, 4, -21,
-23, 20, 70, 74, 70, 70, 57, 36, 10, 27, 24, 42, 81, -66, -100, -85,
-95, -102, -47, -32, -33, 81, 27, -38, 51, 75, 44, -9, 16, -4, -50, -38,
-97, -22, 48, -48, -52, 8, -12, -27, 17, 54, 79, 74, 64, 65, 44, 4,
23, 23, 34, 78, 12, -100, -91, -89, -95, -62, -7, -41, 62, 49, -40, 31,
84, 60, -2, 9, 14, -57, -34, -90, -47, 52, -24, -70, -1, -9, -28, 6,
47, 75, 71, 68, 62, 44, 16, 18, 26, 29, 83, 35, -105, -86, -92, -103,
-72, -9, -48, 44, 70, -33, 10, 83, 67, 10, 9, 23, -51, -30, -78, -69,
49, 0, -99, -2, -5, -34, -4, 44, 69, 71, 72, 67, 46, 20, 11, 22,
25, 74, 54, -68, -94, -87, -102, -85, -13, -27, 23, 82, -27, -7, 73, 68,
16, -2, 30, -43, -57, -58, -80, 34, 20, -89, -54, 1, -32, -10, 44, 73,
68, 70, 75, 52, 15, 2, 22, 14, 65, 70, -49, -101, -88, -94, -90, -24,
-15, 0, 86, -11, -23, 68, 83, 26, 1, 34, -34, -65, -21, -92, 12, 39,
-81, -70, 0, -34, -15, 37, 74, 76, 69, 73, 58, 27, -2, 16, 20, 51,
82, -25, -102, -83, -86, -99, -34, 4, -54, 81, 12, -31, 57, 80, 37, -8,
26, -19, -74, -19, -93, -22, 57, -55, -89, 1, -29, -17, 34, 64, 78, 66,
73, 63, 26, -2, 12, 13, 32, 79, -4, -99, -94, -80, -100, -50, 10, -50,
76, 38, -41, 43, 83, 68, -10, 22, 5, -70, -28, -48, -42, 54, -39, -101,
-11, -23, -36, 25, 64, 74, 72, 76, 73, 33, -1, 6, 20, 32, 79, 16,
-88, -98, -81, -109, -68, 15, -45, -11, 53, -46, 27, 79, 72, 27, 19, 18,
-67, -30, -31, -60, 56, -19, -106, -18, 16, -46, 23, 64, 67, 77, 75, 71,
39, -1, 2, 17, 27, 77, 35, -72, -103, -85, -98, -93, 5, -22, -36, 79,
-35, 9, 77, 73, 35, 4, 25, -60, -43, -16, -86, 40, 1, -99, -41, 18,
-32, 8, 65, 66, 71, 70, 80, 48, 2, 6, 23, 12, 70, 53, -60, -99,
-89, -94, -99, -14, -8, -47, 63, -20, -6, 72, 71, 50, -5, 28, -49, -51,
-6, -86, 29, 19, -88, -56, 4, -20, -9, 58, 71, 67, 73, 77, 51, 8,
0, 23, 16, 57, 74, -39, -103, -88, -87, -100, -22, 3, -44, 49, 55, -17,
61, 72, 56, 4, 32, -37, -66, 0, -77, -66, 43, -77, -62, -1, -20, -29,
47, 75, 69, 71, 77, 50, 9, -4, 17, 19, 14, 80, -15, -100, -92, -87,
-103, -36, 10, -48, 30, 72, -23, 57, 73, 60, 12, 8, -18, -73, -7, -54,
-86, 37, -60, -78, -7, -13, -25, 35, 73, 75, 67, 70, 70, 15, -5, 17,
22, 4, 60, 10, -95, -99, -83, -97, -53, 15, -44, 7, 79, -9, 46, 77,
72, 15, -2, 26, -81, -16, -31, -94, 15, -39, -97, -13, -9, -37, 3, 61,
76, 70, 68, 73, 21, 1, 10, 20, 5, 43, 36, -78, -108, -89, -86, -104,
16, -33, -24, 84, 1, 28, 78, 78, 32, -4, 33, -85, -19, -12, -100, -5,
42, -99, -28, 0, -39, -3, 50, 67, 78, 61, 69, 55, 1, 6, 26, 12,
26, 78, -54, -109, -93, -86, -109, 4, -15, -41, 79, 30, -29, 73, 74, 47,
-10, 25, -24, -45, 4, -96, -36, 48, -93, -49, -5, -30, -10, 33, 69, 83,
66, 74, 61, 20, 7, 17, 17, 17, 70, -30, -99, -95, -87, -100, -67, 1,
-52, 53, 53, -33, 35, 72, 59, -1, 14, -1, -63, 7, -77, -67, 41, -31,
-68, -10, -26, -14, 33, 53, 77, 68, 72, 60, 18, 10, 16, 22, 10, 59,
54, -98, -97, -83, -97, -87, 5, -51, 23, 76, -18, 18, 75, 71, 7, -2,
12, -70, 5, -54, -85, 30, -2, -82, -17, -20, -22, 23, 50, 75, 72, 73,
68, 24, 8, 12, 26, 5, 42, 74, -89, -102, -84, -89, -96, -14, -39, -7,
78, -7, 1, 64, 74, 25, -11, 17, -59, -1, -32, -103, 10, 17, -84, -27,
-22, -16, 16, 40, 69, 70, 73, 77, 30, 7, 11, 25, 2, 23, 81, -17,
-104, -89, -91, -97, -35, 6, -23, 74, 11, -11, 61, 72, 42, -16, 8, -35,
-62, -8, -95, -20, 26, -74, -71, -22, -23, 14, 40, 59, 75, 67, 79, 44,
7, 13, 23, 11, 10, 78, 21, -96, -87, -90, -105, -58, 10, -41, 63, 40,
-22, 48, 75, 55, -11, 0, -23, -72, -7, -86, -51, 31, -53, -88, -13, -22,
7, 43, 58, 76, 68, 81, 53, 11, 17, 17, 15, 0, 67, 48, -79, -91,
-84, -102, -78, 10, -26, 44, 61, -24, 34, 72, 65, -1, -8, -6, -74, -24,
-64, -73, 30, -27, -95, -34, -23, -2, 35, 49, 71, 64, 80, 60, 14, 17,
16, 25, -4, 52, 71, -53, -105, -82, -96, -98, -6, -12, 17, 80, -15, 18,
76, 71, 10, -17, 6, -63, -42, -1, -90, 13, -5, -94, -49, -14, -4, 28,
42, 67, 70, 76, 75, 27, 16, 17, 27, -5, 27, 78, -26, -104, -82, -86,
-102, -26, 7, -44, 82, 4, -2, 65, 69, 56, -25, 11, -48, -60, 9, -100,
-15, 17, -84, -69, -11, -5, 29, 37, 60, 78, 63, 79, 32, 16, 19, 21,
10, 13, 79, 10, -98, -100, -80, -104, -54, 14, -37, 22, 27, -14, 58, 72,
66, -26, 5, -25, -74, 1, -44, -43, 25, -62, -80, -18, -12, 28, 37, 44,
74, 64, 75, 47, 12, 17, 23, 27, 0, 73, 34, -87, -100, -81, -97, -74,
11, -22, -1, 54, -23, 42, 70, 68, 21, -12, -5, -73, -16, -23, -68, 24,
-42, -86, -27, -8, 18, 41, 44, 67, 74, 69, 55, 15, 14, 17, 24, -4,
48, 63, -57, -107, -77, -90, -89, 0, -4, -22, 73, -20, 18, 69, 67, 43,
-26, 7, -63, -41, 0, -91, 11, -10, -89, -40, -2, -2, 37, 42, 64, 75,
69, 60, 17, 15, 18, 22, 15, 27, 71, -25, -105, -89, -69, -97, -26, 14,
-31, 52, 2, -2, 68, 72, 56, -17, 2, -53, -59, 4, -75, -72, 11, -76,
-55, -8, -2, 32, 37, 62, 71, 63, 75, 24, 19, 13, 20, 26, -9, 76,
2, -101, -95, -74, -92, -49, 10, -28, 30, 68, -19, 56, 75, 62, -1, -20,
-34, -71, -2, -50, -87, 17, -57, -64, -18, -1, 21, 32, 57, 73, 59, 71,
39, 12, 21, 20, 23, 0, 64, 28, -87, -98, -73, -84, -65, 7, -24, 4,
75, -27, 35, 71, 64, 13, -31, -19, -77, -15, -25, -94, -11, -33, -72, -20,
3, 16, 33, 50, 72, 59, 67, 73, 8, 20, 25, 27, 5, 17, 52, -65,
-107, -78, -76, -88, 0, -7, -14, 76, 20, 23, 71, 72, 31, -33, -7, -75,
-35, -13, -93, -42, -16, -71, -36, -1, 17, 29, 41, 74, 67, 62, 75, 41,
15, 24, 35, 10, 4, 70, -41, -107, -86, -73, -100, -24, 6, -29, 60, 46,
-25, 73, 75, 42, -25, -12, -64, -58, 2, -73, -72, 9, -60, -48, -6, 18,
28, 28, 70, 69, 60, 74, 55, 13, 22, 32, 14, -6, 57, -18, -102, -91,
-72, -84, -88, 17, -26, 41, 70, -26, 68, 77, 57, -11, -25, -9, -80, -2,
-52, -94, -2, -51, -57, -11, 12, 25, 24, 62, 71, 61, 74, 59, 21, 20,
25, 24, -3, 44, 9, -94, -98, -82, -81, -99, 12, -17, 20, 84, -15, 4,
79, 66, 7, -27, 0, -82, -10, -29, -99, -20, 3, -63, -18, 7, 19, 22,
34, 68, 63, 75, 64, 28, 18, 26, 30, -7, 32, 77, -83, -98, -87, -81,
-102, -52, -7, -5, 86, 8, -16, 82, 64, 26, -24, -5, -47, -27, -13, -93,
-42, 9, -52, -29, 6, 17, 21, 30, 70, 65, 68, 71, 38, 8, 27, 35,
-5, 14, 80, 3, -103, -85, -76, -96, -69, 3, -16, 69, 36, -19, 56, 72,
43, -22, -16, -36, -78, -4, -81, -67, 12, -34, -43, 7, 23, 22, 27, 59,
68, 66, 77, 45, 10, 18, 28, 0, 2, 69, 34, -103, -86, -75, -95, -82,
-5, -17, 53, 60, -13, 34, 79, 53, -16, -18, -23, -80, 0, -63, -87, 5,
-15, -69, 4, 15, 20, 27, 44, 68, 62, 73, 56, 19, 20, 32, 10, -5,
55, 57, -56, -95, -65, -85, -95, -14, -24, 37, 76, -11, 20, 76, 67, 1,
-24, -11, -77, -45, -43, -105, -11, 3, -73, -4, 14, 19, 28, 41, 73, 58,
69, 63, 22, 16, 32, 17, -9, 44, 69, -39, -101, -75, -77, -96, -37, 0,
17, 77, -1, 2, 71, 77, 23, -23, -9, -64, -65, -22, -102, -36, 18, -58,
-55, 15, 10, 18, 38, 68, 63, 67, 67, 24, 13, 30, 23, -10, 31, 78,
-20, -101, -81, -77, -98, -61, 1, -18, 81, 24, -19, 61, 83, 35, -22, -13,
-50, -81, -10, -93, -63, 21, -44, -63, 3, 7, 19, 38, 61, 65, 69, 71,
35, 14, 27, 34, -12, 18, 78, -3, -98, -84, -78, -98, -81, -4, -17, 66,
46, -25, 45, 87, 72, -13, -9, -32, -88, -21, -81, -80, 17, -31, -67, -8,
7, 17, 32, 57, 71, 67, 71, 44, 18, 23, 28, -8, 5, 73, 24, -86,
-99, -77, -88, -90, -13, -8, 2, 63, -26, 27, 79, 68, -6, -13, -18, -88,
-37, -13, -92, 5, -9, -63, -16, 20, 13, 26, 55, 72, 64, 73, 54, 17,
19, 30, 10, -7, 68, 40, -73, -99, -90, -81, -92, -33, -10, -7, 78, -16,
11, 74, 69, 35, -19, -7, -78, -55, -4, -87, -10, 5, -67, -29, 27, 3,
16, 54, 69, 63, 72, 56, 28, 27, 29, 21, -13, 57, 62, -58, -100, -93,
-82, -94, -45, -4, -17, 65, 3, -8, 63, 73, 48, -15, -2, -63, -72, -4,
-73, -28, 12, -56, -36, 18, 14, 16, 52, 69, 63, 68, 64, 31, 20, 28,
29, -10, 40, 73, -43, -99, -91, -85, -92, -58, -2, -20, 46, 24, -19, 55,
80, 56, -7, 4, -44, -86, -13, -57, -91, 11, -49, -47, 9, 15, 12, 51,
75, 68, 63, 76, 43, 18, 28, 36, -3, -12, 70, -32, -99, -96, -90, -91,
-74, -5, -18, 28, 80, -23, 43, 83, 64, 1, -15, -23, -89, -27, -45, -94,
16, -41, -50, 10, 17, 2, 41, 70, 70, 64, 73, 60, 23, 30, 35, 0,
-11, 79, -10, -93, -102, -90, -77, -87, -10, -16, 16, 83, 1, 28, 81, 68,
8, -20, 4, -86, -52, -32, -89, -24, -29, -54, 5, 17, 2, 18, 67, 73,
62, 71, 68, 23, 28, 37, 6, -15, 53, 2, -88, -101, -92, -77, -95, -13,
-13, 0, 82, 24, 14, 77, 74, 18, -25, 18, -79, -64, -25, -84, -37, -27,
-60, 4, 17, 1, 22, 64, 77, 60, 71, 75, 33, 26, 40, 14, -21, 41,
17, -91, -97, -87, -85, -97, -13, -8, -16, 73, 36, -21, 71, 74, 22, -31,
18, -71, -75, -20, -77, -42, 11, -71, 1, 25, -2, 18, 42, 80, 62, 64,
76, 38, 28, 43, 16, -21, 39, 73, -88, -98, -85, -84, -99, -61, 3, -16,
69, 47, -22, 68, 78, 26, -37, 13, 3, -85, -28, -66, -45, 14, -51, -9,
29, 4, 17, 36, 79, 69, 61, 73, 41, 15, 45, 21, -24, 34, 73, -34,
-97, -85, -90, -99, -57, 1, -19, 65, 55, -19, 26, 83, 37, -37, 7, 20,
-77, -34, -57, -45, 15, -50, -17, 38, 0, 8, 38, 63, 76, 57, 69, 56,
15, 26, 27, -27, 29, 75, -28, -95, -85, -89, -97, -60, 10, -24, 57, 64,
-14, 21, 80, 45, -38, -6, 32, -61, -46, -54, -41, 17, -44, -71, 41, 2,
0, 40, 64, 72, 61, 72, 55, 14, 20, 34, -18, 26, 74, -25, -98, -88,
-90, -96, -61, 15, -30, 50, 66, -12, 26, 74, 51, -36, -14, 37, -53, -76,
-48, -35, 21, -41, -77, 42, 4, -7, 32, 64, 74, 61, 68, 57, 20, 11,
45, -12, 27, 82, -21, -97, -93, -89, -93, -61, 20, -15, 50, 67, -14, 27,
76, 78, -38, -27, 40, -38, -74, -53, -38, 24, -38, -84, 7, 8, -4, 27,
56, 69, 65, 67, 62, 31, 5, 41, -10, 20, 81, -20, -94, -94, -89, -89,
-67, 22, -8, -13, 74, -10, 23, 73, 74, -39, -36, 35, -32, -73, -48, -37,
22, -36, -84, 3, 34, 4, 25, 54, 75, 67, 63, 67, 42, 0, 29, 20,
17, 83, -24, -105, -93, -92, -90, -74, 19, 4, -16, 72, -9, 21, 76, 77,
16, -39, 32, -25, -72, -53, -32, 18, -33, -79, -5, 29, 5, 22, 48, 70,
71, 64, 66, 51, 0, 22, 21, 25, 83, -26, -100, -89, -98, -90, -78, 19,
10, -16, 74, -4, 19, 67, 72, 18, -44, 25, -32, -70, -53, -56, 17, -32,
-70, -6, 25, 10, 16, 47, 72, 72, 65, 66, 57, 3, 19, 15, -6, 83,
-37, -101, -82, -97, -87, -83, 13, 22, -8, 71, 3, 22, 62, 66, 19, -59,
20, -27, -69, -57, -50, -3, -30, -62, -15, 16, 13, 12, 41, 68, 73, 69,
57, 57, 7, 11, 7, 3, 79, -44, -99, -84, -97, -82, -89, 7, 27, 2,
71, 41, 30, 55, 63, 25, -54, -10, -26, -64, -59, -45, 1, -37, -54, -16,
10, 19, 8, 45, 69, 68, 73, 54, 56, 14, 5, 0, 4, 79, -54, -103,
-84, -100, -85, -98, 5, 28, 15, 75, 43, 40, 46, 58, 26, -58, -7, -36,
-67, -53, -44, 2, -14, -53, -16, 3, 20, 13, 46, 70, 68, 77, 55, 54,
20, 3, -5, 10, 82, 12, -102, -83, -101, -86, -94, 1, 28, 27, 69, 36,
33, 38, 53, 26, -53, -5, -2, -68, -51, -36, 8, -20, -47, -7, -3, 14,
23, 28, 71, 68, 70, 56, 49, 37, -4, -10, 22, 76, 0, -98, -87, -102,
-90, -95, -41, 27, 35, 69, 38, 46, 45, 50, 21, -53, 6, -5, -72, -44,
-30, 7, -33, -64, -6, -10, 19, 21, 29, 65, 61, 74, 59, 47, 33, 2,
-14, 27, 81, -15, -100, -89, -100, -86, -94, -37, 18, 46, 68, 23, 56, 47,
39, 17, -54, 8, -4, -78, -46, -17, 11, -42, -62, -8, -16, 22, 26, 34,
67, 59, 75, 60, 46, 28, 7, -9, 40, 74, -32, -103, -91, -89, -82, -91,
-31, 13, 54, 69, 19, 60, 44, 16, 20, -49, 14, -10, -89, -44, -3, 12,
-59, -63, -4, -23, 28, 28, 26, 69, 66, 76, 66, 42, 25, 11, 0, 53,
56, -52, -100, -84, -91, -89, -89, -32, 10, 36, 61, 17, 65, 48, 16, 9,
-38, 12, -18, -84, -65, 8, 12, -60, -52, -3, -26, 32, 30, 29, 67, 65,
77, 72, 44, 23, 11, -11, 66, 41, -77, -97, -78, -90, -82, -80, -26, 4,
38, 61, 15, 66, 45, 13, 22, -34, 20, -23, -87, -64, -15, 4, -63, -39,
-6, -35, 35, 28, 36, 72, 72, 73, 62, 46, 19, -4, -12, 46, 21, -94,
-90, -72, -86, -88, -83, -18, 2, 35, 83, 28, 76, 45, 13, 11, -24, 26,
-31, -90, -60, -14, -3, -59, -30, -10, -36, 15, 30, 42, 70, 71, 75, 62,
46, 24, -5, -8, 59, 0, -102, -91, -72, -76, -84, -78, -13, 0, 39, 81,
38, 74, 46, 16, -7, -35, 24, -32, -85, -57, -4, 12, -55, -26, -11, -34,
10, 33, 43, 67, 70, 71, 72, 45, 23, -11, -5, 68, 34, -109, -80, -68,
-79, -91, -64, -3, 6, 44, 69, 44, 72, 36, 19, -13, -32, 14, -35, -81,
-53, 0, 7, -59, -23, -20, -39, 11, 39, 53, 75, 75, 69, 67, 54, 21,
-21, 0, 73, 15, -108, -73, -71, -82, -88, -83, -3, 7, 54, 70, 50, 71,
35, 21, -21, -27, 17, -43, -77, -44, 4, -9, -52, -18, -29, -26, 22, 37,
47, 77, 76, 71, 66, 48, 23, -25, 6, 73, -10, -101, -72, -84, -80, -87,
-77, 1, 15, 62, 61, 52, 71, 39, 17, -36, -22, 17, -19, -75, -36, 9,
-28, -56, -12, -36, -21, 18, 40, 60, 75, 77, 77, 73, 45, 32, -26, 20,
67, -36, -101, -75, -82, -79, -98, -68, -7, 20, 60, 51, 61, 71, 39, 15,
-37, -19, 12, -29, -65, -22, 3, -39, -51, -11, -38, -20, 19, 39, 63, 73,
71, 75, 75, 47, 24, -18, 38, 54, -64, -102, -65, -91, -86, -91, -53, -2,
13, 60, 48, 69, 65, 35, 8, -40, -9, 0, -41, -54, -21, -6, -42, -40,
-9, -35, -8, 25, 40, 63, 78, 74, 73, 74, 49, 18, -15, 50, 25, -89,
-95, -67, -92, -86, -89, -37, 8, 16, 60, 50, 75, 58, 37, 32, -42, -3,
-6, -42, -49, -34, -8, -53, -42, -8, -43, 0, 28, 36, 70, 82, 73, 78,
74, 48, 7, -13, 59, -11, -103, -83, -77, -93, -84, -88, -28, 11, 27, 56,
50, 79, 53, 44, 28, -45, 0, -13, -48, -42, -24, -17, -55, -34, -8, -47,
-30, 32, 36, 69, 84, 77, 77, 76, 46, -8, -2, 54, -50, -101, -74, -86,
-87, -71, -78, -18, 21, 43, 46, 61, 77, 38, 52, 22, -53, 7, -23, -52,
-33, -19, -15, -49, -23, -15, -49, -17, 31, 38, 75, 80, 71, 77, 72, 38,
-13, 11, 50, -26, -94, -74, -91, -78, -68, -70, -10, 31, 52, 41, 47, 71,
38, 60, 10, -55, -12, -33, -51, -27, -10, -16, -46, -15, -22, -51, -9, 29,
41, 75, 76, 72, 75, 75, 29, -15, 29, 35, -58, -85, -78, -96, -73, -65,
-72, -4, 32, 59, 42, 50, 78, 35, 57, 6, -47, -19, -39, -49, -23, -3,
-27, -47, -4, -35, -50, -2, 26, 49, 72, 73, 77, 76, 78, 15, -4, 43,
4, -82, -88, -86, -95, -63, -65, -61, 0, 32, 63, 42, 57, 78, 40, 53,
4, -35, -25, -35, -42, -18, -8, -35, -37, -5, -38, -40, 1, 22, 37, 68,
70, 78, 76, 72, 37, 9, 37, -26, -93, -82, -87, -79, -56, -68, -40, -1,
33, 59, 43, 64, 66, 44, 48, -5, -29, -32, -44, -37, -19, -12, -36, -32,
-3, -44, -39, 7, 28, 40, 63, 76, 77, 77, 71, 24, 18, 14, -60, -89,
-78, -90, -62, -56, -71, -28, 7, 18, 58, 54, 64, 60, 54, 42, -3, -25,
-41, -48, -40, -22, -13, -34, -27, -4, -28, -32, 11, 27, 41, 68, 74, 75,
81, 61, 13, 20, -17, -91, -70, -59, -95, -78, -55, -58, -19, 5, 25, 59,
56, 57, 49, 50, 49, 2, -30, -53, -41, -28, -29, -19, -25, -18, -11, -35,
-21, 14, 22, 51, 72, 71, 77, 74, 58, 20, 20, -48, -86, -49, -72, -98,
-65, -59, -41, -12, 11, 39, 54, 56, 47, 45, 51, 36, 3, -26, -51, -42,
-26, -30, -23, -10, -8, -17, -39, -35, 8, 19, 55, 74, 73, 76, 76, 59,
22, 3, -38, -68, -56, -84, -85, -61, -52, -32, -8, 21, 40, 49, 50, 42,
42, 48, 40, 14, -24, -44, -42, -28, -33, -34, -4, -6, -20, -40, -30, -1,
17, 63, 75, 72, 76, 78, 61, 20, -17, -49, -56, -69, -80, -67, -60, -41,
-19, -4, 26, 43, 44, 41, 42, 40, 44, 37, 9, -15, -40, -42, -29, -35,
-30, -2, -4, -14, -39, -26, -1, 11, 62, 79, 73, 70, 72, 61, 9, -27,
-36, -55, -77, -67, -72, -68, -33, -16, 6, 38, 50, 39, 35, 40, 39, 43,
29, 3, -17, -38, -41, -32, -35, -28, -9, -7, -13, -34, -26, -7, 20, 64,
75, 71, 72, 74, 50, 2, -20, -24, -53, -73, -57, -72, -62, -29, -18, 11,
45, 53, 28, 23, 39, 35, 36, 22, 1, -18, -33, -38, -35, -33, -19, -6,
-2, -15, -29, -20, -15, 1, 61, 70, 68, 71, 71, 54, 2, -9, -21, -59,
-67, -54, -69, -51, -26, -16, 3, 53, 53, 16, 23, 44, 32, 33, 19, -1,
-25, -39, -32, -44, -32, -9, -6, -1, -13, -29, -25, -20, -1, 37, 71, 71,
68, 69, 56, 3, -3, -17, -62, -68, -46, -61, -47, -25, -15, 7, 41, 43,
5, 20, 42, 28, 30, 16, -7, -28, -35, -29, -42, -24, -4, -3, 2, -6,
-30, -25, -25, -9, 32, 66, 68, 70, 70, 53, 24, -1, -23, -59, -66, -47,
-55, -44, -23, -8, 16, 39, 34, 3, 10, 28, 23, 27, 15, -8, -28, -34,
-26, -39, -21, 0, -4, -3, -5, -26, -25, -24, -7, 25, 52, 65, 64, 65,
50, 25, -3, -28, -57, -62, -41, -41, -40, -18, -2, 22, 39, 34, 5, 3,
16, 27, 31, 10, -10, -25, -31, -32, -36, -21, -7, -1, -3, -12, -19, -23,
-24, -7, 16, 41, 65, 60, 58, 47, 26, 8, -27, -53, -54, -35, -34, -41,
-13, 1, 18, 32, 24, 3, -1, 8, 25, 29, 17, -12, -21, -22, -29, -30,
-22, -12, -2, -6, -16, -20, -23, -24, -10, 12, 36, 59, 54, 48, 46, 25,
2, -17, -50, -48, -35, -29, -28, -17, 6, 21, 17, 12, 12, 1, 8, 27,
28, 11, -7, -18, -20, -26, -22, -16, -10, -1, -8, -23, -25, -23, -25, -15,
7, 37, 54, 43, 37, 37, 22, 0, -19, -43, -36, -26, -22, -21, -21, 8,
18, 7, 7, 10, 1, 9, 23, 23, 3, -14, -9, -16, -22, -19, -13, -8,
-1, -11, -23, -19, -18, -22, -15, 5, 30, 44, 46, 33, 34, 25, 0, -23,
-36, -30, -21, -16, -17, -17, 7, 7, -5, 1, 5, -1, 11, 20, 18, 3,
-7, -5, -15, -17, -12, -7, -6, -12, -18, -22, -24, -25, -19, -13, 9, 32,
38, 39, 30, 26, 23, -1, -27, -32, -21, -16, -12, -17, -21, -6, 3, -9,
-2, 5, 3, 11, 17, 15, 7, -2, -3, -15, -17, -9, -5, -7, -13, -19,
-23, -25, -23, -18, -14, 7, 28, 38, 35, 25, 29, 21, -4, -24, -31, -23,
-12, -11, -10, -14, -10, -4, -10, -4, -1, 4, 12, 18, 16, 1, -7, 2,
-3, -20, -7, -2, -7, -12, -23, -22, -19, -22, -20, -9, 8, 25, 32, 25,
19, 23, 16, -4, -22, -25, -18, -9, -11, -12, -7, -12, -10, -7, -10, -4,
4, 14, 15, 11, 5, 0, 2, -4, -13, -8, -1, -6, -17, -19, -16, -21,
-21, -10, -7, -5, 24, 27, 16, 14, 20, 16, -3, -22, -20, -9, -3, -8,
-8, -7, -18, -15, -8, -12, -4, 5, 14, 19, 9, 1, -1, -4, -7, -6,
-4, -3, -11, -20, -23, -24, -19, -14, -8, 1, 9, 20, 23, 17, 13, 17,
17, -3, -17, -12, -6, -6, -7, -12, -14, -21, -13, -4, -14, -8, 5, 19,
20, 8, 8, 6, -1, -1, -3, -11, -4, -14, -25, -22, -18, -12, -17, -12,
4, 9, 9, 24, 21, 18, 18, 13, 3, -21, -15, -5, -8, -7, -10, -22,
-23, -15, -16, -17, -2, 12, 27, 20, 5, 10, 6, -2, 3, 6, -2, -11,
-21, -30, -27, -18, -18, -10, 5, 11, 4, 3, 15, 14, 11, 12, 14, 7,
-9, -9, -9, -8, -2, 0, -17, -16, -11, -13, -17, -6, 15, 26, 21, 14,
8, -2, 1, 1, -5, -8, -8, -15, -21, -23, -27, -24, -6, -3, 8, 11,
11, 17, 13, 9, 1, 0, 7, 6, -5, -4, -2, -5, -13, -25, -17, -7,
-7, -8, -4, 17, 25, 10, -2, 1, 6, 8, 12, 6, -11, -19, -24, -31,
-24, -16, -15, -3, 6, 5, 0, 3, 11, 13, 17, 12, 3, -1, -4, -8,
-4, -6, -2, 6, -7, -17, -15, -23, -18, -5, 13, 33, 22, 8, 0, -5,
3, 4, 6, 3, -11, -16, -33, -34, -23, -20, -2, 13, 9, 6, 11, 9,
-3, 2, 10, 12, 9, 8, 4, -7, -8, -9, -13, -10, -2, -7, -16, -17,
-9, 5, 26, 16, 9, 16, 10, 2, 5, -8, -16, -13, -18, -22, -13, -12,
-10, -3, 5, 4, 5, 9, 10, 9, -1, 1, 5, 2, 7, 8, 1, 4,
-2, -16, -18, -14, -14, -13, -8, 4, 17, 27, 7, -9, -2, 2, 1, 20,
10, -9, -14, -21, -32, -22, -16, -11, 5, 18, 14, -6, 5, 8, -5, -2,
11, 8, 6, 5, 0, -3, -1, -5, -1, 8, -1, -11, -22, -18, 0, 13,
27, 18, 11, 11, -4, -12, -6, -5, -7, -8, -12, -13, -18, -18, -14, -11,
1, 14, 10, 13, 5, -11, -5, -3, -2, 12, 14, 13, 10, 3, -8, -9,
-5, -2, -6, -13, -8, 3, 11, 16, 12, 2, 10, 8, -1, 0, 4, -16,
-23, -17, -14, -13, -5, -4, 0, 7, 4, -2, 6, -3, -9, -1, 3, 3,
4, 13, 14, 2, 3, 2, -13, -7, -3, -18, -19, -2, -3, 11, 30, 15,
-11, 12, 12, -5, 3, 15, -9, -13, -19, -32, -20, -1, -6, 6, 15, 5,
-5, -1, -8, -23, -14, 9, 12, 9, 18, 2, -9, 11, 12, -5, 17, 8,
-12, -7, -22, -20, 12, 29, 14, 3, 20, 8, -12, -4, 2, -15, -4, -7,
-24, -8, 2, -21, -9, 10, 6, -1, 9, -7, -16, -7, -5, -4, 13, 20,
9, 9, 15, -2, -6, 8, -6, -6, -1, -13, -3, 10, 12, 2, -2, 9,
6, 4, 5, -2, -2, -4, -23, -21, 2, -5, -20, 6, 4, 2, 7, 0,
-7, -9, -7, -6, 7, 22, 4, -2, 6, 4, -3, 1, 6, 6, 1, -8,
-16, -21, 8, 19, 4, 9, 18, 5, 4, -4, -11, -6, -3, -18, -14, 0,
-4, -17, -4, 4, 3, 5, 0, -12, -7, -11, -13, 5, 23, 16, 5, 17,
8, -7, 0, -3, -4, 9, -1, -21, -6, 15, 3, -1, 3, 4, 2, 6,
2, -5, 8, 8, -22, -13, -12, -18, -12, -6, 5, 10, -3, -4, 2, -7,
-12, 1, 14, 17, 13, 4, 5, 11, 6, -1, 4, 1, -14, -22, -9, -5,
-9, 22, 17, 1, 4, 4, -8, -5, 4, 10, 10, 1, -15, -7, -12, -27,
-14, 7, 0, 0, 6, -1, -13, -3, -1, 2, 17, 17, 2, 10, 7, -3,
7, 13, -2, -6, -10, -22, -18, -2, 11, 16, 21, 15, 3, 5, -10, -19,
0, 9, -5, -11, -3, -15, -20, -7, -4, 8, 12, -8, -11, 1, -9, -9,
12, 24, 18, 15, 22, -8, -11, -1, -11, -9, 15, -4, -11, 7, 2, -22,
11, 15, -7, 11, 25, -13, 0, 6, -16, -20, -8, -10, -6, 0, -6, -10,
5, 6, -19, -2, 14, -7, 0, 5, 4, 17, 20, 6, 11, 13, -3, -11,
-7, -6, -15, -4, 3, -3, 9, 15, -4, 9, 15, -7, -9, 8, 3, -4,
-7, -18, -22, 0, -7, -6, 9, 8, 1, -6, -12, -9, -4, 3, 9, 20,
22, -1, -8, 7, -5, -4, 6, 6, 5, -11, -14, -1, 2, -1, 11, 19,
13, 7, -6, -17, -13, 2, 6, -5, -16, -7, -12, -19, -11, -7, 7, 15,
-4, 7, 3, -9, -3, 2, 12, 26, 16, -3, -3, -2, -12, -5, 9, 5,
3, 3, -7, -14, -13, -2, 12, 22, 18, 7, -1, -6, -16, -11, -9, -11,
-1, 1, -8, -9, -2, 2, -6, -1, 11, 6, 7, 3, -3, -1, 5, 10,
3, -4, 4, -2, 0, 2, -2, 4, -4, -1, 6, -3, 0, 12, 11, 13,
4, -1, 0, -11, -5, 1, -15, -23, -7, -2, -5, 7, 6, -7, -5, -1,
-11, -6, 7, 8, 13, 14, -3, -4, 1, -11, -3, 17, 12, 10, 16, 1,
-15, -10, -10, 0, 16, 17, 20, 8, -13, -13, -15, -7, 2, -9, -4, 8,
-2, -1, -2, -8, 3, 11, 6, 2, 0, 5, -3, -11, 19, 9, -7, 3,
0, -13, 5, 1, -3, 9, 15, 1, -10, 0, 1, 1, 11, 1, -1, 9,
-1, -10, 3, -11, -17, 2, -4, -16, 0, 2, -4, 5, 9, 1, -6, -4,
0, -2, -6, 0, 8, 5, 2, -3, -5, 1, 12, 10, 9, 12, 4, -13,
-4, 7, 3, 8, 19, -3, -2, -1, -9, -4, 1, -17, -16, -3, -2, -4,
8, 1, 0, 11, 4, -10, 1, 0, -5, 0, 7, 5, -1, 8, -2, -9,
12, 1, -5, 11, 9, -5, -10, -11, 11, 19, 2, -4, -1, -12, -10, -7,
-11, 4, 3, -9, 4, -3, -13, 5, -1, -3, 16, 14, 2, 8, -1, -13,
-11, 1, 8, 3, 10, 3, -2, 7, 4, -12, 7, 17, -4, -9, 2, -3,
5, 8, -8, -5, 7, -13, -6, 11, 4, -9, -2, 0, -6, 0, 7, -15,
6, 17, -7, -14, 4, -10, -15, -4, -8, -1, 14, 11, 4, -6, -7, 7,
1, 3, 14, 8, 2, -1, -4, -1, -1, 7, 4, -6, 0, -6, -3, -1,
-8, -9, 8, 8, 0, 7, 6, -11, -4, 2, -10, -4, 9, -8, 2, 12,
2, 2, 13, -3, -2, 8, -1, -5, 20, 7, -16, -8, 3, -14, 1, 8,
-6, -1, 8, -11, -9, -7, -7, 9, 8, 6, 16, 4, 0, 7, -8, -8,
-3, -12, -7, 7, -4, -12, -7, -7, -3, 14, -11, -3, 17, 5, -3, 7,
3, -6, -9, 1, -2, -2, 12, 7, 1, 14, 13, -9, 6, 4, -10, -1,
0, -5, 9, 9, 3, 0, -12, -16, -27, -17, 4, 0, 7, 6, -4, 10,
14, -8, 2, 17, 9, 4, 19, 3, -13, -13, -12, -13, -9, 8, 7, -2,
4, 4, -19, -2, 7, -5, -3, 6, 9, 5, -4, 0, -2, -5, 2, -7,
2, 10, -1, -2, 2, 1, 4, 14, 2, 4, 17, -11, -11, 20, 8, -7,
2, -17, -26, -18, -8, 10, 13, 8, 14, 11, -1, 5, -3, -6, 8, 11,
2, 2, -2, -3, -7, -10, 1, -9, 0, 14, -6, -4, -6, -12, 3, 11,
7, 15, 11, 0, 4, 7, -14, -5, 0, -7, 1, 8, 7, 9, 3, 0,
-3, 3, 13, -3, 1, 15, -9, -5, -2, -17, -8, -3, -14, -7, 2, -4,
-5, 7, 8, 12, 14, 5, 2, 4, 4, -1, 3, 17, 9, -10, -10, -19,
-24, -17, 0, 11, 0, 0, 5, -8, -28, 10, 17, 1, 17, 23, -1, 5,
-2, -15, -2, 5, 0, 8, 9, 8, -5, -10, 7, -1, 10, 13, -5, 0,
0, -22, -8, 11, -2, 0, -4, -20, -13, 4, 7, 5, 13, 18, 15, 2,
1, -5, -11, 5, 3, -8, 16, 1, -18, 2, -2, -29, -6, -4, -8, -2,
-6, 1, 9, -5, 7, 17, 7, 13, 0, -4, 5, -5, -7, 2, -3, -2,
9, 14, 4, 7, 5, -8, -4, 4, -2, -3, -2, -6, -8, 2, -6, -1,
9, -3, -10, -1, 2, -11, -2, 12, 8, 12, 12, 13, 5, -3, 9, -14,
-6, 18, 1, -14, -4, -14, -26, -24, -4, 18, 9, 0, 3, 2, 1, 1,
-2, 8, 11, 1, 2, 0, -13, -10, 5, 3, -5, 11, 1, -10, -2, -4,
-9, 2, 2, 7, 8, 0, -5, -3, 3, 5, 7, 3, -13, -5, -2, -4,
7, 23, 19, 11, 7, -7, -5, -1, -5, 9, 3, -4, 1, -11, -11, -16,
-15, -8, -8, 1, -6, 1, 5, -1, 9, 2, 6, 8, 3, 8, -1, 5,
10, 6, 3, -5, -11, -4, 5, 4, 0, 5, 0, -15, -19, -3, 3, 0,
1, 0, 14, 9, -16, -2, 6, 1, 2, 2, 7, 15, 8, 4, 9, 7,
2, 3, 2, 3, -3, -12, 2, -11, -13, -3, -8, -18, -8, 9, 8, 8,
16, 1, -1, -3, -1, 10, 9, 3, 6, 6, -2, -8, -5, -12, -9, 1,
-7, -9, 1, -11, -8, 6, -1, -9, 8, 6, 5, 11, 3, 5, 4, -3,
-3, -1, -3, -5, 11, 23, 18, 9, 3, 1, -2, -3, 0, -4, -4, -2,
-7, -11, -8, -4, -11, 1, 5, -5, 0, 4, 1, 5, 9, 4, -3, 7,
-1, -1, 9, -3, 0, 7, -2, 1, -14, -14, -8, -15, 3, 12, 3, -6,
-1, -4, -14, 2, 12, 3, 11, 3, -2, -2, -8, -8, 5, 15, 5, 3,
13, 0, -1, 0, -2, -1, 1, 0, -2, -2, -10, -15, -1, 3, 5, 2,
-3, -5, 5, 1, 0, 12, 12, 10, 0, 1, 4, 0, 2, 1, 1, -6,
-13, -5, -10, -13, 2, -13, -22, -4, 3, -6, -5, 2, 6, 5, 12, -1,
4, 12, -2, -2, 11, 0, -5, 4, 2, -1, 15, 9, 3, 2, -7, -18,
-6, 1, 3, 8, -7, -8, 1, -12, -7, 7, 5, 8, 4, -1, 0, 3,
7, 11, 12, -1, -2, 8, -6, -10, -10, -6, -2, 2, 3, -5, -12, -18,
-22, -7, 1, 9, 7, 4, 5, -1, 11, 5, -4, 4, 5, -1, -7, 1,
-2, -12, 16, -1, -7, 10, 1, -11, 0, -1, -8, -2, 2, -7, 2, -4,
-3, 16, 9, 8, 15, 10, 1, -10, -7, 9, 11, 7, 8, 4, 2, -2,
-9, 0, 2, -9, -1, 6, -6, -14, -10, -11, -15, -12, -5, 5, 3, 8,
12, 0, 2, 8, 0, -5, -4, 2, 6, 5, 3, 1, 2, -6, -17, -12,
13, 0, -9, -5, -10, -9, -7, -9, 0, 9, 1, -3, 10, 8, 3, 5,
8, 2, 4, 1, 5, 11, 7, 10, 5, 8, 6, -5, -5, -10, -4, 3,
-2, -2, -7, -13, -17, -17, -11, 4, 17, 14, 11, 10, 2, -6, -12, -6,
4, -2, -3, 1, -3, -4, -10, -8, -1, -4, -8, -7, -8, -6, -13, -15,
2, 6, 4, 7, 2, 12, 12, 9, 15, 7, 1, 1, -10, -2, 11, 11,
12, 6, -2, -4, 2, -8, -7, 3, -2, -12, -4, -3, -11, -3, -7, -3,
5, -1, 14, 16, 11, 11, 0, -6, -3, -1, -6, -5, 4, 4, 1, 1,
1, -2, -16, -21, -12, -8, -11, -13, -14, -9, -3, -2, 0, 8, 8, 13,
12, 4, 8, -7, -4, 5, -3, 2, 9, 1, 6, 13, 7, -6, -4, 0,
-12, -14, -6, -7, 1, 5, 5, 9, 8, -4, -3, 1, 8, 18, 14, 2,
9, 3, -4, -3, 7, 5, -7, -2, 1, -4, 4, -10, -8, -3, -10, -5,
-21, -20, -12, -8, -3, -4, 7, 12, 6, 7, 9, -3, 4, 2, -1, 6,
-8, -6, -2, 6, 12, 6, 3, -2, -2, -3, -11, -18, -6, -1, -4, 5,
12, 3, 6, 8, 2, -1, 11, 7, -2, 10, 5, -2, 0, -8, 5, 6,
-4, 5, 0, -4, 3, 2, 0, 0, -17, -22, -20, -10, -6, -8, 3, 8,
13, 11, 3, 5, -1, -8, -6, -1, -2, 1, 1, -2, 3, 5, 3, 2,
-4, -6, -9, -11, -26, -24, -1, 3, -4, 7, 18, 15, 11, 11, 12, 4,
6, 4, 7, 13, 5, -1, 5, 8, 0, -1, 10, 2, -5, -2, -3, -6,
-3, -19, -21, -11, -11, -17, -1, 7, 5, 11, 11, 11, -4, -12, -8, -8,
-10, -9, 10, 7, 5, 11, 2, -12, 2, 7, 1, -3, -14, -25, -18, -10,
-8, -1, 12, 12, 17, 12, 3, 5, -1, 6, 9, 2, 1, 5, 11, 6,
2, 7, 7, 3, -4, -7, -3, -5, -8, -1, 2, -4, -11, -18, -13, -4,
0, 7, 8, 17, 11, 0, -3, -2, -7, -19, -4, -7, -4, 7, -2, -4,
1, -11, -6, 8, 2, -22, -14, -24, -31, -18, -5, 10, 8, 19, 20, 10,
12, 7, 5, 8, 6, 4, -1, 5, 18, 17, 4, 2, 9, 5, -2, -4,
-3, -13, -5, -9, -16, 3, 5, -10, 4, 10, 10, 7, 8, 8, 10, 5,
-12, -15, -7, -9, -8, -1, -1, 7, 6, -4, 4, -4, -22, -12, -3, -17,
-24, -30, -27, -18, 7, 11, 3, 13, 18, 2, 3, -7, -12, 5, 9, -1,
17, 17, 4, 11, 9, 4, 9, -5, -8, 0, -12, -15, -6, -5, -5, 8,
17, 12, 13, 13, 5, 8, 12, 5, 0, -2, 2, -8, -12, 1, 0, -11,
-4, 4, -8, -8, -3, -8, -7, -3, -5, -11, -23, -38, -13, -1, -4, 14,
18, 2, 9, -6, -20, -7, -6, 3, 10, 4, 10, 7, 3, 6, 2, 8,
0, -5, -3, -31, -17, -9, -22, -7, 18, 16, 21, 24, 17, 14, 21, 13,
5, 4, 0, -4, 4, -1, 0, 7, 5, -12, -12, 0, 1, -4, 0, -4,
0, -1, -16, -23, -23, -21, -12, 3, 12, 16, 13, 2, -3, -16, -28, -24,
-8, -7, -5, 12, 15, 6, 18, 2, -9, 5, 5, -15, -22, -39, -32, -15,
-15, 12, 26, 29, 26, 27, 20, 6, 7, -3, -1, 12, 3, 4, 15, 12,
7, 6, -2, -13, -17, -7, -1, -2, -2, 11, 11, -4, -12, -20, -16, -10,
-5, 7, 19, 16, 14, 7, -13, -28, -27, -22, -18, 0, 12, 12, 12, 6,
-3, -5, -1, 0, 3, -4, -28, -47, -42, -17, -3, 18, 30, 26, 18, 13,
5, -2, -3, 2, 13, 9, 10, 13, 10, 12, 9, 1, -8, -11, -8, -8,
-9, -9, 2, 16, 15, 8, -13, -24, -18, 3, 11, 13, 32, 31, 13, -1,
-6, -23, -37, -22, -9, -8, 1, 7, 4, 2, 3, -5, -5, 7, 15, 7,
-31, -61, -44, -27, -6, 10, 20, 26, 15, 4, 0, 4, -4, 4, 12, 10,
21, 23, 14, 7, 4, 1, -2, 2, -5, -14, -12, -17, -2, 7, 7, 14,
10, 4, 5, 8, 11, 20, 20, 15, 15, 7, -19, -27, -24, -19, -20, -7,
10, 16, 13, 10, -1, -20, -8, -3, 1, 13, 6, -49, -61, -40, -11, 11,
20, 26, 17, -1, -11, -20, -16, -3, 7, 16, 31, 35, 1, -9, 1, 6,
-2, 3, 4, -16, -39, -37, -11, 7, 25, 38, 33, 28, 12, 2, 8, 16,
15, 14, 7, -1, -11, -15, -7, -7, -4, -7, 3, 12, -1, -1, -4, -15,
-13, -6, 1, 3, -13, -29, -36, -33, -22, 8, 20, 17, 0, -13, -12, -28,
-20, -9, -7, 11, 24, 19, 12, 2, -5, 0, 5, -11, -22, -29, -32, -24,
-16, 7, 34, 48, 45, 25, 16, 3, 8, 13, 14, 15, -3, 3, 6, 2,
-2, -16, -11, 1, -7, -8, 18, 12, 7, 6, -8, -10, 3, -12, -23, -19,
-21, -16, 7, 16, 11, 4, -3, -17, -23, -33, -39, -24, -10, 0, 26, 34,
17, -1, 0, 9, 13, -5, -43, -62, -48, -38, -14, 12, 33, 49, 46, 30,
12, 5, 5, 4, 4, 9, 19, 17, 14, 13, 1, -2, -14, -17, -3, -7,
2, 13, 14, 15, 17, 11, 1, -14, -20, -15, -13, 2, 18, 16, 9, 8,
-4, -27, -39, -41, -34, -17, -6, 7, 16, 17, 7, -9, -5, -13, -1, 50,
-15, -89, -84, -55, -27, 0, 28, 34, 37, 26, 0, -6, 9, 15, 17, 17,
24, 25, 18, 11, 3, 4, 1, -22, -17, -10, -17, -15, 9, 25, 22, 31,
21, -4, -1, -5, -7, 11, 21, 18, 10, 6, -2, -20, -33, -37, -25, -7,
-4, -2, 6, 4, 14, -2, -22, -15, -6, -5, 38, 39, -45, -96, -72, -29,
-9, 23, 21, 11, 17, -12, -15, 2, 13, 26, 31, 33, 25, 8, 5, 3,
10, 2, -14, -12, -21, -27, -16, -1, 23, 35, 35, 11, 5, 5, 8, 18,
18, 30, 22, -6, -15, -13, -27, -25, -19, -16, 0, 18, 3, 4, 11, 13,
-3, -31, -12, -7, -10, 11, 37, -9, -73, -73, -30, -2, -9, -15, 2, -22,
-27, -11, -15, 15, 28, 37, 40, 20, 11, 3, -13, -21, -21, -20, -31, -32,
-19, -3, 19, 49, 50, 43, 22, 3, 4, 12, 23, 21, 7, 11, 19, -9,
-14, -18, -20, -6, -15, -7, 18, 22, 10, 5, 6, 3, -9, -12, -5, 0,
14, -1, -10, -26, -44, -30, -21, -8, -26, -23, 5, -45, -29, -3, -8, 6,
26, 29, 22, 22, 24, -8, -64, -49, -26, -15, -14, -11, 13, 24, 33, 37,
33, 26, 8, 5, 11, 17, 31, 27, 14, 15, 2, -4, -5, -15, -23, -28,
-2, 15, 17, 32, 21, 15, 17, 6, -11, -3, 2, 3, 2, -9, -15, -23,
-27, -13, -2, -16, -19, -18, -54, -65, -34, -1, -3, 6, 26, 28, 13, 48,
45, -45, -95, -68, -36, -12, 10, 24, 16, 21, 17, 7, 21, 34, 30, 23,
27, 24, 22, 35, 35, 5, -12, -23, -29, -24, -9, -8, 13, 29, 26, 35,
43, 17, 0, 10, -9, -35, 10, 12, 6, 0, -13, -17, -13, -17, -28, -29,
-22, -28, -51, -12, 10, -13, -16, 2, 6, 13, 12, -9, 24, 44, -58, -102,
-50, -22, -43, 28, 21, -7, 13, 4, 10, 45, 52, 50, 46, 28, 3, -3,
9, 20, 3, -1, -12, -41, -32, -1, 28, 49, 44, 27, 8, 6, 11, 4,
41, 30, -9, 12, 7, -20, -14, -24, -24, -21, -21, -25, -12, -8, -30, -22,
12, 11, -16, -37, -10, 8, -27, 2, 5, 13, 66, -44, -95, -80, -75, -56,
-30, -17, 3, 31, 23, 21, 41, 29, 32, 49, 30, 5, -16, -20, 1, 6,
3, -3, -20, -10, 14, 36, 40, 39, 28, 16, 15, 23, 29, 17, -8, -23,
-18, -16, -12, -19, -13, 2, 12, 12, -13, 7, 18, 3, -13, -12, 13, -17,
-41, -23, 1, 7, -10, -14, 3, 1, -28, -38, -90, -100, -63, -79, -60, 14,
17, 37, 59, 52, 4, -10, 17, -8, -31, -6, 19, 10, 15, 25, 17, 9,
11, 16, 41, 38, 23, 24, 11, 27, 46, 24, -5, -19, -35, -16, -5, -8,
2, -4, 8, 36, 36, 3, 0, 7, -8, 8, 14, -7, 2, 3, -11, -10,
-10, -24, -38, -34, -44, -43, -2, -14, -70, -40, -66, -79, -41, -6, 40, 67,
80, 60, -24, -90, -51, -20, -6, 23, 24, 7, 12, 5, 19, 29, 17, 49,
51, 27, 18, 10, 25, 24, 15, 10, -10, -14, -2, 5, 20, -6, -5, 25,
21, 36, 26, 20, 30, 7, -2, -5, -3, -4, -18, -11, -8, -16, -18, -27,
-57, -61, -59, -27, -6, -17, -27, -42, -24, -20, -23, 20, 30, 8, 42, 78,
5, -107, -46, 2, -44, 5, 57, -34, 21, 41, 1, 41, 74, 25, 4, -7,
5, 26, 41, 35, 8, -1, -4, -28, 16, 39, 25, 22, 22, 13, 9, 35,
41, 22, 43, -16, -65, -8, -1, -40, -13, 3, -28, -24, -29, -60, -23, -13,
-51, -55, -13, 16, -12, -45, -19, 16, -4, -22, -6, 9, -16, 15, 74, -50,
-94, -53, -11, -46, -17, 62, -9, 28, 79, 29, 30, 66, -4, -7, 9, 26,
45, 30, 23, 18, 20, -1, -11, 26, 34, 23, 43, 33, 22, 28, 1, 7,
-6, 12, -24, -68, -12, 15, -13, -6, 24, -10, -54, -36, -16, -5, 3, -30,
-52, -12, 15, -19, -60, -34, 11, -7, -15, -38, -29, 36, -16, -53, 41, -53,
-105, -35, -13, -1, 71, 24, -3, 45, 44, 49, 76, 34, 2, 17, -2, 19,
38, 48, 54, 39, 13, -22, -33, -6, 27, 34, 8, 29, -12, -25, 22, 2,
26, 16, -43, -67, -29, 28, 0, 1, 19, -12, -13, 6, -29, -10, -17, -64,
-31, 3, 11, -10, -61, -64, -40, -55, -40, -33, 42, 21, -73, -9, -31, -7,
-9, -104, -22, 67, 57, 31, 16, 32, 36, 24, 44, 24, -10, 27, 42, 27,
28, 48, 41, 0, -9, 13, 0, -21, 17, 46, 20, -29, -40, 3, 59, 25,
42, 23, -50, -35, -16, 42, 37, -1, 24, -21, -31, 21, -2, -48, -28, -55,
-61, -33, -30, -32, -60, -69, -52, -30, -11, 2, 59, -49, -76, -18, -69, -63,
52, 62, -23, -109, -23, 29, -26, 58, 62, -20, 17, 49, 32, 42, 24, 10,
18, 31, 16, 17, 35, 2, 18, 4, -6, 37, 23, -3, 17, 37, 66, 53,
24, 0, -45, -29, 52, 43, -18, 3, -7, -39, -35, -9, -9, -37, -38, -49,
-60, -44, -64, -49, -21, -2, -23, -68, 2, -21, -9, 65, 18, -36, -66, -91,
-52, 20, 79, -45, -122, -20, 55, -17, 10, 26, 3, 55, 67, 49, 52, 25,
-40, -5, 49, 30, 47, 71, 28, 16, 42, 16, -15, 23, 45, 32, 8, 26,
49, 20, 17, 23, -17, -8, -25, -65, -13, 14, -20, -4, 23, -15, -38, -42,
-59, -60, -19, -34, -78, 1, -18, -75, -61, -22, 4, -16, 24, 76, -14, -95,
-43, -74, -22, 78, -2, -94, -64, 33, -5, 28, 71, 16, 19, 92, 47, 48,
37, -2, 36, 11, 3, 37, 75, 67, -7, 21, -15, -57, 20, 63, 4, 18,
26, 39, 44, 34, 7, -60, -29, 37, -36, -20, 30, -10, -16, 39, 11, -41,
-15, -64, -62, -37, -69, -61, -33, -16, -5, -44, -54, -4, -17, -11, 52, 44,
-90, -18, -52, -104, 31, 12, -109, -87, 25, 50, 43, 83, 6, 1, 71, 36,
3, 91, 6, -29, 44, 56, 5, 46, 45, -20, -9, 12, -40, 45, 61, -1,
1, 25, 44, 66, 63, 33, -28, -36, 17, -43, -66, 27, 48, -13, 26, 11,
-44, -34, -70, -71, -38, -45, -48, -76, -1, 11, -63, -60, 7, -6, -30, 73,
53, -80, -48, -24, -109, 33, 63, -56, -113, 59, 63, 15, 51, 38, -24, 65,
69, 25, 54, 23, -19, 45, 23, 18, 43, 41, 5, 5, 15, -12, -9, 51,
43, 44, 16, 23, 79, 58, -15, -47, -51, 10, 16, -37, 13, 3, -23, 4,
33, -66, -61, -44, -77, -47, -29, -55, -48, -31, -2, -16, -51, -20, -24, -38,
14, 78, -61, -58, -17, -103, -46, 78, -36, -109, -23, 56, 13, 67, 55, -9,
12, 72, 64, 59, 27, -12, 35, 46, 19, 58, 42, 2, 19, 31, -36, -11,
70, 60, 27, 27, 21, 66, 50, 18, 9, -65, -3, 44, -48, -67, -8, -32,
-12, 18, -5, -32, -36, -67, -33, -34, -59, -55, -50, -4, -8, -49, -32, -2,
-19, 15, 70, -5, -88, -37, -98, -56, 68, 41, -76, -43, 44, 44, 59, 65,
25, 36, 66, 69, 66, 61, 4, 25, 54, 12, 23, 51, -13, -9, 26, 4,
-32, 24, 60, 43, 45, 5, 27, 84, 13, -24, -54, -51, 12, -56, -56, -7,
-29, -20, 30, -10, -37, -20, -60, -92, -63, -43, -61, -63, -8, 33, -39, -36,
0, -27, -44, 40, 19, -85, -59, -67, -100, 0, 76, -46, -97, 3, 62, 50,
75, 43, 11, 48, 67, 57, 57, -9, -14, 45, -6, 7, 62, 31, -9, 37,
7, -45, 17, 78, 59, 43, 12, 36, 75, 22, -14, -32, -87, -10, 4, -86,
-59, -16, -15, 27, 23, -38, -47, -57, -67, -41, -37, -26, -50, -35, 7, -24,
-68, -46, -17, -31, 27, 67, -38, -73, -54, -88, 22, 88, 5, -91, -9, 52,
37, 52, 68, -1, 26, 75, 49, 47, 40, -13, 51, 47, 11, 53, 43, -3,
37, 41, -27, -7, 70, 49, 48, 15, -6, 59, 26, -31, -3, -49, -74, 3,
-84, -57, 8, -13, -9, 25, -36, -45, -22, -55, -48, -26, -26, -43, -69, -23,
3, -61, -48, -6, -37, -29, 86, -21, -77, -25, -84, -84, 84, 12, -91, -72,
30, 35, 40, 70, 34, 10, 49, 58, 54, 47, -2, 19, 58, -4, 43, 68,
25, 24, 29, -26, -19, 35, 46, 53, 23, -1, 62, 58, -16, -14, -57, -57,
10, -45, -93, 5, -11, 1, 38, 10, -34, -18, -44, -48, -47, -51, -36, -62,
-15, 33, -33, -82, -3, -13, -4, 76, 51, -70, -54, -77, -88, 24, 77, -73,
-83, 18, 51, 16, 51, 41, 0, 58, 82, 50, 68, -2, -10, 57, 19, -15,
65, 20, -3, 36, 25, -27, 32, 75, 59, 42, 15, 31, 54, 1, -1, -33,
-85, 1, -42, -82, -16, -2, -19, 42, 16, -39, -28, -34, -59, -42, -55, -40,
-52, -62, 12, -28, -85, -57, -15, -15, 62, 59, -54, -75, -43, -82, 21, 84,
-10, -101, -41, 57, 21, 48, 74, 13, 8, 88, 42, 56, 45, -26, 27, 43,
-13, 28, 51, 16, 44, 38, -15, 1, 53, 58, 51, 7, 15, 77, 44, -4,
-14, -82, -46, 0, -72, -41, -9, -31, 12, 52, -12, -36, -33, -55, -31, -44,
-60, -62, -65, -8, 20, -49, -52, -11, -27, 13, 91, 25, -67, -26, -89, -63,
63, -5, -93, -47, 42, 33, 25, 67, 17, 12, 73, 72, 42, 45, -22, 19,
80, 28, 40, 58, 24, 24, 57, 16, -18, 57, 49, 43, 43, 2, 61, 59,
17, -8, -58, -54, -10, -66, -76, -12, -19, -2, 56, -3, -58, -32, -42, -29,
-45, -66, -63, -70, 3, 40, -27, -86, -36, -1, 13, 89, 39, -83, -65, -48,
-69, 46, 63, -42, -98, 35, 43, 21, 71, 63, 10, 76, 64, 39, 73, 30,
-18, 65, 16, 8, 67, 50, 16, 42, 17, -32, 13, 60, 40, 48, 10, 35,
73, 32, -6, -61, -95, -32, -24, -83, -14, -1, -25, 26, 53, -42, -23, -30,
-39, -39, -64, -47, -60, -39, 19, 10, -102, -43, 7, -20, 35, 85, -84, -67,
-33, -85, -24, 81, -24, -101, -21, 60, 24, 64, 72, 1, 18, 80, 44, 61,
48, -13, 34, 50, 11, 71, 56, 15, 32, 49, -27, 3, 61, 38, 32, 25,
25, 64, 32, 4, -7, -88, -37, -5, -74, -63, 3, -9, 15, 51, -16, -65,
-33, -48, -46, -57, -60, -69, -52, 15, 16, -70, -84, -4, -25, 16, 84, -6,
-88, -34, -85, -41, 79, 44, -84, -37, 46, 11, 28, 94, 39, 10, 78, 44,
31, 83, 25, 19, 56, 1, 41, 89, 13, 32, 54, -3, -34, 45, 45, 34,
40, 11, 45, 64, 16, 5, -59, -72, -10, -80, -66, -1, -11, -21, 30, -19,
-63, -21, -39, -57, -41, -67, -67, -69, -31, 25, -57, -76, -4, 1, -18, 52,
8, -81, -40, -52, -97, 9, 46, -76, -99, 6, 48, 17, 90, 53, -17, 43,
84, 35, 70, 29, -6, 50, 10, 39, 86, 39, 21, 55, 0, -30, 43, 71,
37, 50, 13, 45, 73, 21, 4, -58, -88, -26, -42, -92, -43, -7, -23, 29,
40, -44, -41, -32, -56, -46, -57, -53, -72, -41, 22, -12, -79, -31, 7, -26,
41, 64, -51, -78, -41, -104, -15, 78, -3, -101, 12, 54, -2, 50, 95, -18,
43, 88, 44, 58, 58, -7, 52, 41, 15, 68, 41, 14, 50, 48, -11, -2,
72, 41, 47, 32, 16, 62, 14, -4, -9, -78, -68, -34, -82, -39, -1, -16,
5, 39, -36, -38, -17, -53, -53, -69, -64, -57, -65, -19, -12, -79, -41, 23,
-8, -6, 74, -43, -82, -18, -79, -81, 83, -2, -106, -59, 49, 0, 37, 90,
15, -10, 75, 44, 46, 63, 1, 14, 52, 12, 61, 69, 23, 22, 41, -4,
-5, 54, 66, 41, 20, 22, 68, 51, 5, 8, -72, -61, 1, -64, -85, 1,
-35, -10, 45, -14, -68, -6, -52, -70, -60, -73, -60, -45, -13, 3, -50, -66,
23, 5, 0, 67, 41, -76, -14, -71, -93, 50, 67, -110, -68, 47, 34, -5,
67, 30, -14, 66, 77, 23, 60, 4, 5, 54, 19, 31, 67, 18, 26, 53,
21, -16, 42, 67, 54, 37, 13, 46, 60, 3, 25, -18, -91, 0, -55, -106,
-31, -7, -43, 40, 3, -70, -33, -11, -50, -67, -68, -68, -57, -24, 8, -57,
-74, 1, 23, -13, 59, 49, -68, -49, -13, -94, 37, 69, -51, -109, -20, 44,
-7, 45, 81, 6, 6, 78, 21, 53, 45, -18, 37, 35, 30, 79, 47, 7,
54, 24, -15, 13, 51, 44, 47, 24, 38, 77, 26, 2, -17, -88, -33, -5,
-82, -35, -9, -38, 8, 43, -33, -44, -28, -52, -61, -63, -61, -60, -32, 7,
-20, -74, -4, 14, -15, 15, 78, 10, -57, -16, -92, -52, 68, -38, -105, -33,
42, 16, 11, 73, 14, 7, 80, 54, 28, 50, -8, 43, 67, 15, 59, 45,
13, 33, 42, 5, -2, 39, 44, 53, 45, 13, 75, 27, 7, 32, -52, -35,
3, -84, -79, -3, -22, 3, 43, -32, -61, -29, -43, -54, -54, -56, -65, -56,
11, -27, -78, -34, 9, -9, 18, 84, 18, -79, -26, -48, -67, 68, 36, -86,
-92, 45, 23, 12, 74, 48, -15, 80, 53, 36, 72, 15, 0, 65, 21, 26,
51, 30, 19, 35, 18, -14, 21, 59, 53, 43, 7, 54, 69, 9, 38, -45,
-82, -5, -35, -85, -11, -17, -37, 29, 21, -59, -11, -35, -58, -52, -58, -76,
-60, -3, -10, -70, -29, -2, -9, -6, 47, 73, -71, -26, -38, -102, 6, 50,
-67, -98, -2, 51, 2, 63, 48, -22, 41, 78, 23, 64, 11, -2, 64, 55,
29, 47, 39, 17, 29, 47, -16, 12, 59, 49, 47, 22, 49, 64, 7, 24,
7, -81, -5, -28, -98, -52, 3, -27, 21, 19, -63, -37, -10, -62, -50, -71,
-81, -75, -22, -5, -47, -61, -18, 11, -2, 47, 87, -22, -69, -11, -106, -7,
87, 3, -105, -19, 49, 1, 24, 79, 14, 43, 86, 23, 46, 62, -5, 54,
61, 22, 36, 55, 8, 21, 46, 5, -22, 36, 54, 48, 30, 28, 78, 48,
19, 17, -81, -67, 6, -97, -61, 3, -27, -24, 36, -62, -45, -9, -59, -55,
-50, -73, -60, -43, -9, -22, -61, -14, 11, 0, 8, 66, -18, -72, -18, -73,
-85, 47, 12, -102, -75, 38, 37, 33, 80, 27, 1, 71, 61, 29, 59, -3,
0, 66, 19, 23, 58, 30, 7, 41, 20, -17, 33, 71, 56, 49, 27, 64,
47, 3, 28, -75, -83, -8, -60, -104, -30, -20, -22, 44, -3, -77, -23, -48,
-44, -41, -72, -66, -61, -12, -16, -68, -41, 1, -14, 5, 65, 51, -58, -41,
-58, -87, 42, 73, -43, -76, 33, 39, 12, 62, 57, -2, 59, 54, 16, 55,
36, 2, 69, 52, 21, 55, 26, 0, 38, 43, -5, 0, 66, 58, 43, 14,
34, 70, 21, 34, -20, -89, -30, -56, -92, -26, -10, -45, -1, -2, -73, -28,
-28, -59, -34, -73, -74, -74, -42, 2, -58, -34, 9, 2, -14, 17, 57, -54,
-49, -8, -91, -43, 73, -38, -106, -29, 57, 8, 49, 57, 0, 29, 76, 20,
57, 42, -17, 30, 74, 22, 53, 47, 0, 23, 41, -17, -7, 47, 56, 59,
17, 34, 75, 37, 20, -13, -77, -32, -19, -91, -74, -11, -53, -18, 31, -42,
-64, -23, -57, -34, -49, -79, -69, -34, 4, -35, -59, -12, -3, -13, 23, 76,
9, -79, -15, -94, -48, 81, 32, -99, -31, 52, 19, 22, 68, -5, 30, 76,
37, 34, 64, -22, 15, 70, 37, 34, 47, 2, 20, 54, 18, -19, 47, 62,
60, 37, 16, 61, 43, 21, 26, -46, -75, -19, -92, -84, -11, -28, -48, 37,
-27, -59, -22, -49, -52, -44, -65, -67, -60, -18, -40, -69, -22, 9, -7, -8,
81, 15, -86, -26, -44, -95, 79, 32, -76, -88, 11, 24, 27, 68, 25, 7,
59, 34, 29, 64, 9, -13, 68, 33, 39, 67, 11, -2, 58, 18, -17, 23,
61, 54, 37, 21, 58, 64, 24, 27, -41, -81, -26, -46, -100, -4, -25, -54,
11, 13, -57, -22, -42, -47, -36, -55, -77, -72, -18, -20, -57, -40, 1, -1,
-10, 50, 79, -42, -39, -49, -94, 20, 71, -74, -88, 5, 33, 8, 63, 27,
-6, 52, 64, 14, 49, 28, -30, 51, 64, 15, 70, 26, 7, 51, 46, -10,
16, 60, 65, 57, 26, 38, 64, 30, 33, 5, -69, -34, -42, -90, -34, -4,
-60, 3, 14, -55, -41, -19, -49, -48, -54, -65, -83, -41, -23, -58, -47, -15,
12, -6, 48, 92, -28, -76, -23, -87, 3, 70, -13, -93, -61, 46, 11, 38,
65, 13, 9, 74, 28, 48, 66, -20, 2, 60, 5, 54, 59, 1, 52, 49,
-9, -11, 45, 70, 54, 21, 38, 76, 51, 33, 15, -58, -56, -20, -77, -44,
-7, -59, -46, 24, -11, -45, -19, -46, -51, -55, -49, -75, -41, -13, -46, -49,
-24, 15, 0, -6, 78, 51, -79, -20, -86, -75, 57, -16, -93, -73, 31, 46,
8, 64, 20, 6, 75, 59, 13, 69, -18, 1, 77, 21, 57, 61, -1, 20,
62, 31, -9, 40, 74, 69, 38, 28, 70, 48, 31, 32, -14, -60, -24, -69,
-82, -16, -31, -59, 20, -2, -66, -29, -29, -52, -49, -50, -70, -72, -10, -46,
-49, -35, -6, 16, -9, 68, 52, -68, -44, -34, -79, 54, 42, -59, -96, 29,
48, 8, 49, 47, -8, 80, 65, 17, 71, 31, -36, 78, 19, 18, 77, 29,
18, 62, 34, -20, 5, 66, 66, 42, 33, 56, 62, 43, 36, -4, -59, -42,
-42, -68, -14, -35, -68, -15, 22, -67, -36, -35, -56, -44, -54, -75, -67, -19,
-29, -51, -45, -4, 24, -19, 16, 87, -60, -49, -36, -103, -9, 79, -58, -101,
-28, 62, 30, 55, 51, -13, 29, 88, 38, 64, 35, -34, 48, 56, 21, 79,
25, 2, 45, 51, -17, 10, 71, 75, 46, 24, 56, 62, 44, 42, 24, -61,
-45, -46, -82, -33, -4, -70, -19, 23, -42, -62, -25, -55, -48, -52, -67, -79,
-23, -30, -42, -50, -35, 30, -13, 6, 83, 8, -75, -27, -93, -13, 73, -4,
-90, -33, 61, 30, 29, 74, 19, 19, 81, 38, 24, 67, -8, 35, 57, -3,
56, 75, -1, 39, 56, 3, -15, 44, 67, 45, 28, 44, 66, 45, 41, 28,
-36, -57, -41, -82, -33, -4, -57, -61, 15, -40, -66, -17, -40, -55, -37, -68,
-82, -47, -27, -38, -53, -37, 32, 16, -16, 60, 12, -73, -24, -67, -89, 43,
1, -84, -89, 15, 55, 21, 72, 25, -10, 55, 73, 29, 62, -1, -7, 63,
16, 59, 85, 16, 16, 60, -2, -21, 41, 70, 54, 39, 37, 60, 51, 42,
52, -35, -56, -41, -70, -69, -22, -48, -59, 10, 8, -76, -51, -39, -55, -32,
-55, -78, -44, -38, -38, -40, -62, -9, 17, -18, 58, 79, -45, -63, -58, -96,
34, 62, -40, -90, 5, 52, 10, 52, 63, -10, 54, 73, 32, 58, 46, -10,
70, 26, 9, 84, 19, 16, 54, 28, -20, 5, 69, 56, 43, 29, 43, 64,
46, 53, 9, -59, -58, -62, -64, -28, -26, -67, -37, 15, -79, -59, -18, -59,
-43, -46, -83, -63, -39, -35, -36, -56, -14, 30, -4, 7, 79, -38, -72, -19,
-86, -52, 67, -37, -102, -44, 52, 6, 51, 67, -8, 9, 80, 36, 49, 48,
-23, 23, 69, 4, 72, 65, 11, 28, 30, -16, 9, 62, 57, 47, 32, 45,
68, 52, 48, 34, -53, -68, -57, -52, -40, -29, -63, -36, 29, -27, -75, -19,
-60, -41, -23, -64, -63, -44, -35, -30, -49, -42, 22, -7, 9, 90, 41, -77,
-17, -82, -53, 80, 30, -109, -52, 46, 26, 14, 75, -18, 3, 82, 61, 33,
57, -14, 20, 61, 9, 21, 67, 27, 24, 42, 14, -16, 62, 56, 35, 32,
32, 61, 56, 57, 31, -32, -58, -46, -48, -47, -30, -41, -57, 28, -22, -77,
-27, -35, -54, -25, -68, -71, -50, -42, -25, -46, -45, 4, 14, -10, 84, 46,
-79, -35, -28, -103, 77, 37, -83, -103, -5, 32, 20, 74, 16, -33, 40, 59,
42, 66, 22, -5, 53, -4, 16, 73, 48, 15, 32, 7, -23, 34, 72, 46,
44, 33, 53, 61, 58, 54, -25, -55, -51, -39, -50, -40, -40, -51, 1, 21,
-63, -35, -37, -51, -12, -51, -84, -46, -40, -28, -27, -39, -11, 9, -7, 31,
89, -12, -46, -22, -99, 2, 85, -78, -99, -1, 55, 15, 52, 26, -21, 43,
74, 31, 49, 33, -18, 47, 36, -5, 83, 55, 16, 18, 17, -13, 28, 70,
52, 37, 26, 40, 67, 56, 52, 14, -41, -56, -39, -57, -50, -25, -41, -5,
20, -55, -64, -22, -53, -16, -56, -90, -62, -54, -37, -27, -31, -20, 7, 0,
27, 90, -8, -83, -8, -60, -7, 91, -6, -104, -61, 57, 8, 43, 64, -3,
6, 71, 32, 45, 69, 3, 17, 27, -14, 52, 74, 37, 19, 18, -5, -1,
49, 57, 30, 22, 44, 75, 61, 48, 16, -42, -55, -32, -47, -38, -24, -51,
-39, 16, -19, -66, -17, -53, -44, -27, -72, -65, -52, -41, -39, -31, -10, 4,
-1, -6, 67, 67, -75, -14, -66, -89, 53, 67, -101, -70, 47, 37, -1, 72,
3, -10, 71, 63, 12, 76, 16, 17, 54, -11, 41, 76, 46, 19, 16, 18,
-11, 34, 59, 54, 38, 27, 72, 57, 44, 43, -6, -68, -26, -37, -64, -36,
-27, -34, 20, -9, -83, -44, -30, -47, -32, -65, -65, -56, -51, -36, -27, -16,
5, 7, -17, 65, 74, -49, -45, -19, -95, 42, 72, -47, -112, 37, 34, -18,
54, 62, -22, 65, 73, 0, 47, 66, 0, 60, 7, -6, 66, 72, 19, 18,
26, -13, -10, 47, 59, 41, 24, 53, 65, 54, 52, -6, -58, -36, -23, -77,
-48, -30, -37, -4, 26, -82, -60, -22, -40, -31, -43, -66, -63, -71, -49, -22,
-20, 7, 2, -32, 11, 94, -46, -57, -15, -96, -47, 80, -47, -115, -25, 60,
-4, 52, 70, -19, 15, 94, 25, 35, 79, 4, 32, 53, -17, 62, 73, 32,
12, 27, -13, -12, 52, 68, 49, 33, 55, 55, 55, 69, 29, -52, -25, -30,
-74, -56, -29, -39, -3, 24, -43, -89, -36, -36, -39, -37, -63, -70, -72, -47,
-19, -32, -17, 9, -27, 10, 84, 25, -74, -27, -85, -51, 68, 20, -84, -34,
57, 17, 3, 71, 30, 17, 88, 27, -4, 77, 43, 31, 49, -22, 18, 80,
29, 12, 27, 12, -17, 30, 78, 49, 28, 42, 61, 58, 65, 23, -40, -42,
-24, -73, -44, -26, -39, -19, 18, -32, -82, -44, -23, -42, -38, -68, -73, -75,
-77, -31, -31, -29, 11, 0, -19, 45, 43, -66, -32, -38, -95, 9, 35, -76,
-94, 14, 61, -5, 63, 40, -17, 49, 78, -4, 70, 54, 7, 54, 16, 18,
78, 49, 14, 16, 13, -15, 22, 73, 65, 21, 34, 71, 65, 59, 53, 2,
-45, -15, -50, -69, -26, -38, -32, 16, 3, -84, -77, -19, -52, -42, -48, -72,
-84, -73, -21, -18, -31, 5, -4, -24, 40, 90, -16, -65, -38, -104, 4, 83,
-22, -103, 9, 55, -5, 32, 67, -18, 56, 85, 4, 23, 86, 0, 49, 27,
-22, 49, 42, 8, 30, 25, -15, -1, 70, 64, 26, 24, 54, 61, 61, 45,
5, -34, -30, -45, -75, -46, -21, -36, -13, 7, -83, -74, -10, -36, -53, -42,
-60, -72, -86, -48, -18, -24, 3, 1, -22, -8, 85, -6, -69, -18, -72, -70,
88, -9, -111, -64, 50, -5, 25, 61, 0, 15, 82, 10, 17, 76, 20, 20,
68, -20, 45, 65, 15, 22, 20, -16, 3, 49, 74, 52, 25, 51, 56, 61,
59, 26, -24, -29, -39, -74, -68, -13, -35, -6, 39, -37, -97, -9, -47, -59,
-33, -49, -63, -89, -56, -17, -20, -12, 5, -12, -11, 59, 59, -55, -15, -66,
-74, 60, 53, -108, -71, 52, 31, -14, 61, 4, 9, 76, 46, -8, 53, 30,
23, 68, 6, 9, 69, 15, 24, 36, -7, -17, 41, 64, 49, 17, 30, 59,
62, 49, 31, 5, -32, -34, -65, -72, -18, -19, -35, 34, -27, -92, -40, -24,
-65, -35, -46, -65, -88, -81, -7, -26, -26, 10, 4, -22, 56, 65, -48, -45,
-22, -98, 56, 54, -62, -103, -3, 32, -14, 67, 49, -12, 41, 45, -14, 44,
72, 10, 40, 18, 19, 76, 39, 17, 42, -13, -19, 23, 49, 52, 23, 35,
53, 63, 60, 30, 11, -24, -39, -39, -75, -23, -9, -44, 3, 24, -69, -45,
-22, -63, -44, -32, -54, -88, -80, -20, -17, -38, 7, -3, -18, 22, 88, 16,
-52, -17, -102, -29, 86, 6, -99, -1, 59, -6, 24, 50, -7, 38, 73, 10,
3, 72, 13, 38, 50, 4, 69, 36, 20, 55, 13, -27, 26, 33, 51, 47,
21, 39, 68, 57, 30, 18, -4, -44, -38, -75, -63, 1, -25, -1, 30, -70,
-90, -20, -39, -49, -28, -48, -82, -97, -18, -22, -38, -11, -4, -12, 19, 87,
20, -79, -21, -51, -36, 74, 7, -91, -61, 55, -4, 25, 69, 6, 5, 81,
9, 3, 76, 42, 17, 50, 5, 45, 65, 20, 50, 16, -24, 7, 32, 37,
48, 19, 29, 63, 68, 40, 21, -11, -51, -29, -45, -67, -2, -22, -27, 41,
-9, -94, -29, -39, -57, -36, -41, -80, -99, -50, -19, -41, -13, -6, -8, -15,
48, 82, -81, -16, -39, -93, 31, 65, -85, -58, 41, 28, -9, 64, 8, 5,
72, 48, -9, 74, 37, 14, 65, 34, 21, 63, 13, 34, 43, -9, 4, 19,
37, 60, 36, 16, 59, 64, 40, 28, 15, -48, -27, -51, -86, -25, -2, -24,
43, -10, -106, -65, -21, -52, -37, -43, -62, -96, -43, -15, -39, -18, -9, -7,
-17, 39, 87, -37, -69, -11, -93, 28, 70, -40, -95, 30, 36, 3, 56, 45,
-7, 64, 50, 1, 42, 62, 4, 60, 39, 23, 66, 30, 36, 46, -8, -15,
13, 30, 68, 39, 7, 44, 69, 49, 37, 10, -43, -40, -31, -77, -18, 0,
-41, 2, 33, -98, -63, -26, -53, -44, -37, -63, -93, -79, -20, -29, -22, -6,
6, -3, -3, 78, -31, -65, -10, -79, -54, 63, -37, -107, -38, 48, 13, 53,
45, -10, 35, 82, 31, 40, 68, 3, 25, 64, 21, 66, 35, 7, 42, 24,
-11, 16, 30, 52, 61, 18, 48, 78, 54, 39, 25, -20, -34, -31, -72, -53,
3, -40, -5, 32, -56, -95, -39, -55, -38, -32, -51, -76, -87, -30, -23, -32,
-18, -1, -4, -3, 80, 45, -75, -30, -81, -70, 65, 32, -85, -45, 41, 17,
23, 61, 8, 37, 85, 39, 9, 64, 46, 24, 60, 22, 41, 55, 11, 44,
27, -13, -2, 20, 54, 69, 23, 20, 68, 68, 45, 33, -15, -47, -27, -74,
-55, 6, -15, -29, 24, -59, -91, -38, -46, -47, -25, -60, -79, -95, -59, -17,
-31, -31, -11, 7, -7, 37, 48, -79, -43, -25, -100, -1, 35, -80, -90, 6,
47, 15, 58, 12, -4, 61, 73, 5, 56, 54, 7, 44, 42, 44, 51, 13,
30, 40, -14, -10, 14, 41, 71, 48, 12, 61, 76, 51, 38, 19, -47, -29,
-49, -71, -6, -17, -30, 31, -9, -91, -49, -48, -50, -31, -59, -69, -84, -61,
-16, -27, -41, -19, 12, -9, 32, 87, -19, -81, -18, -109, -12, 83, -16, -99,
4, 55, 0, 40, 54, -14, 52, 79, 19, 18, 70, 3, 47, 49, 22, 55,
17, 27, 37, 0, -19, -7, 40, 78, 50, 8, 36, 74, 49, 45, 24, -39,
-39, -46, -70, -3, 11, -46, -8, 8, -89, -58, -25, -52, -35, -60, -69, -83,
-81, -36, -27, -34, -22, 7, 0, -2, 93, -16, -84, -7, -69, -87, 82, -13,
-105, -61, 47, 2, 39, 52, -12, 14, 76, 15, 15, 75, 25, 14, 64, 20,
52, 44, 18, 32, 0, -24, -10, 22, 60, 70, 11, 28, 75, 65, 42, 48,
-42, -40, -12, -65, -52, 9, -45, -8, 41, -48, -92, -24, -49, -32, -46, -72,
-68, -81, -36, -21, -41, -37, 8, -1, -2, 74, 59, -75, -11, -59, -85, 52,
53, -64, -66, 50, 34, 13, 69, -22, 5, 82, 55, -8, 49, 32, 10, 55,
31, 42, 51, 23, 29, 13, -13, -16, 19, 56, 70, 27, 4, 49, 64, 44,
51, 7, -55, -24, -57, -50, 15, -10, -37, 32, -49, -85, -23, -39, -57, -45,
-73, -63, -80, -77, -16, -39, -45, -6, 6, -15, 70, 66, -66, -64, -20, -92,
57, 55, -73, -104, -3, 40, 21, 64, 13, -20, 49, 56, -5, 40, 67, 14,
35, 28, 43, 73, 37, 23, 11, -18, -17, 4, 35, 69, 23, -6, 44, 76,
56, 45, 10, -53, -39, -26, -63, 13, -4, -36, 30, 13, -92, -28, -35, -62,
-41, -64, -68, -76, -79, -27, -20, -46, 3, 7, -19, 26, 92, 9, -61, -15,
-95, -30, 83, -4, -100, 0, 57, 10, 46, 19, -20, 49, 83, 25, 7, 69,
19, 30, 46, 29, 58, 39, 31, 13, -17, -12, 4, 36, 67, 50, 4, 20,
74, 55, 46, 36, -24, -48, -21, -57, -30, 17, -27, 26, 21, -87, -72, -20,
-55, -43, -62, -72, -61, -74, -26, -21, -45, -15, 13, -12, 22, 91, 14, -85,
-25, -54, -35, 85, 11, -96, -71, 55, 14, 48, 59, -26, -3, 89, 32, 8,
63, 48, 12, 45, 29, 53, 58, 33, 18, -9, -15, -8, 21, 61, 52, 5,
13, 63, 66, 47, 34, -32, -72, -32, -33, -31, 11, -21, -13, 42, -29, -73,
-17, -51, -58, -53, -76, -59, -73, -52, -15, -37, -22, 12, -3, -11, 54, 77,
-80, -30, -50, -93, 37, 70, -92, -76, 34, 37, 18, 56, -33, -4, 77, 68,
19, 62, 53, 18, 43, 38, 32, 65, 42, 23, 7, -7, -15, 23, 63, 67,
33, 1, 63, 70, 47, 44, 6, -59, -31, -33, -45, -5, -1, -16, 40, -20,
-98, -43, -19, -61, -60, -74, -59, -62, -57, -20, -51, -44, 8, 5, -12, 48,
73, -38, -69, -18, -91, 24, 65, -40, -99, 35, 40, 17, 68, 11, -29, 68,
63, 21, 38, 76, 35, 34, 33, 33, 69, 56, 25, 9, -12, -11, 3, 38,
68, 31, 4, 40, 72, 57, 44, 10, -51, -48, -19, -41, -12, -3, -26, 15,
27, -95, -49, -26, -60, -55, -69, -57, -66, -86, -31, -32, -42, 15, 0, -28,
11, 86, -39, -75, -23, -88, -45, 73, -49, -100, -18, 52, 21, 73, 2, -29,
54, 79, 42, 38, 76, 38, 22, 39, 22, 67, 55, 30, 25, -8, -23, 1,
38, 68, 53, 11, 42, 79, 66, 48, 38, -19, -47, -20, -39, -31, -1, -28,
7, 20, -68, -84, -23, -57, -57, -64, -64, -54, -80, -26, -39, -68, -11, 19,
-31, 6, 84, 32, -82, -40, -90, -49, 78, 23, -87, -28, 52, 27, 66, 56,
-43, 58, 79, 45, 30, 62, 55, 29, 40, 13, 49, 72, 32, 32, -5, -32,
-20, 11, 68, 56, 11, 21, 69, 71, 50, 45, -20, -64, -33, -46, -30, 6,
-16, -20, 32, -66, -90, -29, -36, -54, -61, -62, -58, -88, -53, -18, -67, -10,
17, -25, -21, 53, 36, -77, -44, -42, -98, 19, 28, -85, -79, 24, 42, 59,
62, -34, 5, 76, 62, 26, 61, 62, 19, 41, 32, 42, 78, 43, 33, 22,
-25, -20, -1, 39, 68, 30, 10, 65, 72, 43, 42, 21, -66, -32, -25, -45,
-10, -5, -16, 28, -5, -94, -67, -38, -58, -62, -71, -54, -74, -57, -18, -57,
-36, 22, -29, -18, 53, 82, -22, -76, -33, -96, 4, 72, -31, -105, 22, 44,
24, 86, 24, 0, 71, 70, 36, 28, 76, 27, 39, 36, 12, 57, 42, 32,
18, -18, -25, -19, 41, 73, 32, 3, 38, 70, 49, 53, 28, -55, -61, -29,
-55, -7, 20, -23, -10, 1, -94, -66, -13, -50, -57, -59, -57, -72, -74, -28,
-60, -37, 9, -13, -37, -1, 84, -18, -78, -18, -70, -66, 77, -21, -101, -39,
52, 29, 86, 24, -29, 44, 74, 29, 14, 76, 57, 25, 45, 7, 58, 52,
27, 37, -16, -27, -23, 12, 62, 61, 11, 29, 62, 58, 44, 49, -42, -66,
-29, -38, -34, 15, -17, -5, 32, -49, -100, -14, -56, -60, -49, -55, -62, -83,
-34, -36, -58, -12, -3, -39, -13, 76, 59, -66, -13, -70, -82, 59, 51, -73,
-50, 55, 35, 44, 66, -18, 32, 71, 64, 10, 38, 62, 27, 43, 12, 33,
71, 26, 44, 19, -32, -41, 12, 58, 58, 19, 11, 51, 55, 43, 53, 0,
-66, -23, -39, -30, 18, 3, -27, 32, -36, -98, -35, -37, -71, -51, -63, -53,
-84, -74, -22, -55, -27, 14, -8, -33, 77, 63, -67, -45, -19, -105, 54, 46,
-71, -96, 8, 41, 42, 62, -13, -1, 63, 56, 13, 39, 79, 42, 36, 5,
27, 71, 47, 47, 14, -33, -38, -19, 30, 67, 20, 3, 45, 71, 45, 42,
2, -69, -42, -26, -45, 9, 3, -19, 17, 19, -81, -37, -28, -68, -51, -58,
-61, -82, -71, -19, -41, -51, 11, -17, -33, 29, 99, 5, -51, -9, -103, -29,
77, -10, -100, 9, 70, 26, 52, -9, -6, 66, 77, 27, 9, 85, 46, 31,
21, 1, 50, 48, 42, 42, -1, -32, -30, 29, 64, 43, 10, 18, 70, 50,
42, 34, -45, -66, -19, -46, -14, 14, -14, 19, 28, -78, -71, -12, -66, -44,
-51, -70, -70, -87, -26, -29, -45, -3, 3, -34, 30, 100, 8, -84, -7, -45,
-31, 76, -19, -111, -54, 62, 22, 58, 41, -26, 22, 85, 30, 7, 68, 70,
29, 21, -2, 44, 71, 42, 38, 5, -35, -43, 3, 57, 44, 6, 18, 64,
62, 35, 39, -37, -65, -20, -38, -9, 29, -13, -26, 36, -22, -78, -9, -63,
-61, -31, -66, -63, -81, -54, -15, -40, -8, 7, -36, -21, 73, 69, -86, -5,
-40, -95, 44, 58, -105, -54, 51, 41, 26, 50, -22, 6, 78, 66, 1, 62,
75, 32, 18, 4, 21, 64, 46, 43, 26, -13, -48, -6, 56, 66, 23, -1,
66, 65, 34, 44, 13, -59, -23, -36, -40, 16, 22, -30, 33, -12, -100, -43,
-38, -51, -26, -66, -60, -73, -85, -8, -41, -44, 9, -5, -23, 73, 73, -58,
-53, 4, -96, 40, 56, -77, -101, 49, 44, 24, 54, 6, -12, 76, 61, 2,
27, 82, 54, 23, 6, 13, 53, 58, 46, 29, -13, -46, -30, 34, 59, 17,
1, 47, 78, 47, 52, 14, -56, -42, -24, -34, 11, 14, -34, 2, 34, -93,
-46, -44, -68, -23, -49, -63, -70, -81, -26, -18, -48, 4, 2, -41, 14, 94,
-60, -58, 6, -90, -44, 82, -80, -98, 4, 61, 24, 53, 6, -14, 51, 81,
32, 16, 78, 59, 24, 18, 10, 53, 57, 47, 48, 17, -33, -31, 26, 65,
39, 6, 43, 81, 50, 40, 45, -25, -39, -28, -42, -3, 28, -40, -8, 30,
-55, -73, -28, -65, -28, -46, -68, -58, -87, -41, -19, -53, -29, 16, -40, 11,
97, 19, -85, -11, -91, -46, 92, -6, -115, -60, 60, 27, 34, 31, -18, 54,
83, 39, 8, 55, 75, 22, 21, 17, 28, 50, 40, 49, 23, -13, -31, -14,
68, 40, 2, 20, 71, 69, 41, 35, -28, -51, -24, -46, -2, 41, -14, -43,
22, -52, -71, -31, -65, -53, -29, -68, -61, -83, -69, -21, -53, -25, 17, -28,
-32, 62, 18, -88, -16, -31, -100, 40, -7, -113, -58, 44, 49, 40, 29, -27,
19, 85, 63, 3, 58, 78, 34, 21, 21, 23, 41, 33, 40, 35, -12, -23,
-11, 49, 65, 18, 13, 70, 67, 37, 42, 6, -49, -30, -32, -29, 18, -6,
-46, 15, -2, -77, -45, -62, -52, -29, -63, -60, -72, -64, -6, -31, -56, -2,
-21, -35, 54, 79, -50, -68, -23, -92, 36, 72, -63, -108, 46, 55, 27, 53,
-5, 12, 83, 65, 5, 21, 83, 36, 29, 27, 17, 39, 37, 37, 29, -9,
-19, -22, 40, 71, 32, -5, 36, 82, 32, 46, 13, -48, -45, -34, -26, 22,
33, -44, -26, 11, -79, -45, -32, -68, -33, -61, -66, -75, -89, -37, -33, -48,
-5, -2, -36, 11, 79, -49, -70, 1, -80, -47, 67, -64, -104, -12, 66, 31,
52, -6, -25, 54, 81, 6, 18, 82, 59, 21, 31, 17, 43, 44, 35, 45,
-6, -19, -20, 10, 56, 45, -2, 33, 75, 50, 38, 30, -47, -38, -32, -30,
0, 34, -42, -21, 45, -44, -83, -37, -61, -29, -47, -65, -51, -92, -41, -17,
-49, -29, 2, -33, 9, 92, 30, -87, -6, -82, -51, 73, 0, -98, -14, 65,
42, 38, 19, -9, 58, 72, 29, -1, 58, 59, 24, 27, 11, 30, 54, 41,
49, 16, -15, -17, 14, 55, 44, 8, 15, 58, 45, 42, 34, -29, -56, -38,
-27, -3, 40, -1, -50, 43, -47, -83, -31, -53, -45, -53, -70, -47, -84, -74,
-16, -53, -28, 8, -23, -30, 92, 34, -89, -38, -34, -92, 77, 5, -100, -73,
40, 45, 46, 32, -30, 13, 82, 34, -3, 58, 78, 28, 24, 16, 37, 52,
32, 37, 15, -9, -17, -3, 42, 56, 8, 14, 61, 60, 35, 48, -27, -60,
-43, -28, -16, 42, -5, -61, 22, 18, -82, -28, -50, -52, -37, -65, -53, -84,
-74, -21, -36, -43, 4, -34, -37, 51, 84, -40, -36, -37, -90, 34, 67, -53,
-80, 35, 72, 42, 52, -28, 10, 81, 72, 9, 22, 70, 28, 29, 25, 29,
52, 30, 39, 29, -1, -16, -2, 46, 51, 19, 3, 36, 65, 35, 41, 3,
-52, -50, -23, -12, 24, 32, -54, 24, 15, -90, -49, -27, -62, -41, -63, -49,
-62, -84, -49, -41, -41, 2, -1, -44, 51, 85, -35, -74, -5, -70, 15, 65,
-48, -102, -22, 64, 36, 50, 6, -18, 44, 78, 13, 21, 79, 44, 20, 29,
20, 39, 33, 32, 31, -12, -17, -6, 22, 50, 19, 11, 46, 72, 39, 33,
11, -48, -58, -35, -19, 17, 26, -55, -23, 49, -52, -51, -26, -56, -39, -50,
-56, -57, -78, -50, -35, -45, -4, -9, -42, 1, 90, 45, -79, -4, -65, -51,
79, 21, -114, -28, 68, 55, 51, -5, -29, 36, 92, 50, -4, 84, 45, 12,
31, 28, 41, 31, 22, 42, 11, -24, -7, 20, 43, 31, 7, 19, 73, 39,
32, 37, -17, -57, -28, -20, -8, 36, -15, -19, 49, -52, -92, -29, -41, -49,
-45, -47, -45, -70, -69, -24, -37, -23, 1, -29, -3, 83, 49, -79, -41, -23,
-54, 78, 20, -92, -81, 30, 61, 48, 29, -30, -5, 85, 46, -1, 56, 71,
12, 34, 35, 43, 56, 30, 36, 7, -21, -6, 8, 26, 27, 5, 14, 70,
62, 20, 41, -11, -56, -48, -19, -3, 27, -7, -43, 31, 7, -86, -31, -43,
-52, -45, -55, -46, -56, -57, -38, -28, -19, 8, -29, -42, 41, 90, -80, -46,
-28, -104, 10, 73, -95, -75, 37, 76, 46, 35, -20, -7, 63, 75, 7, 56,
72, 11, 14, 41, 36, 53, 29, 22, 31, -8, -5, 10, 29, 39, 18, 5,
68, 61, 26, 47, 22, -47, -42, -21, -14, 9, 17, -38, 31, 8, -90, -48,
-14, -62, -56, -55, -39, -58, -66, -30, -30, -29, -6, -11, -37, 38, 86, -19,
-79, -11, -102, 7, 76, -40, -103, -34, 74, 55, 44, 0, -20, 59, 72, 5,
17, 76, 41, 22, 33, 32, 49, 45, 14, 18, -11, -17, 4, 18, 44, 23,
3, 42, 78, 41, 46, 21, -45, -54, -29, -10, 5, 12, -32, -9, 37, -80,
-43, -19, -54, -53, -60, -40, -55, -67, -46, -37, -32, -8, -15, -41, -9, 69,
-16, -78, -6, -67, -69, 80, -34, -105, -37, 58, 58, 40, 3, -26, 25, 82,
40, 15, 85, 50, 5, 28, 45, 50, 48, 19, 15, -2, -14, 6, 11, 38,
37, 2, 43, 80, 39, 27, 43, -11, -49, -34, -15, -3, 9, -24, -8, 39,
-42, -82, -28, -57, -52, -52, -44, -42, -62, -43, -39, -43, -26, -8, -43, -14,
72, 56, -69, -45, -67, -68, 77, 41, -91, -90, 66, 59, 41, 26, -15, 26,
79, 53, -1, 52, 81, 2, 28, 53, 48, 53, 30, 20, 3, -25, 8, 16,
35, 47, 2, 9, 70, 59, 33, 46, -15, -54, -40, -15, -14, 2, -2, -26,
37, -41, -85, -32, -50, -60, -49, -42, -38, -62, -59, -43, -31, -28, -15, -28,
-42, 24, 59, -69, -42, -13, -97, 0, 36, -93, -89, 26, 72, 40, 23, -17,
11, 65, 75, 5, 52, 82, 18, 5, 44, 47, 54, 30, 16, 14, -19, 18,
15, 19, 54, 24, 7, 71, 54, 19, 50, 18, -54, -43, -19, -12, -11, 1,
-24, 40, 23, -77, -53, -46, -59, -55, -53, -33, -57, -63, -40, -37, -33, -19,
-32, -47, 27, 91, -15, -82, -10, -90, 10, 78, -46, -111, 31, 75, 41, 34,
-7, 15, 68, 71, 21, 18, 80, 20, 5, 40, 44, 58, 52, 7, 12, -15,
-5, 22, 29, 49, 23, -11, 39, 80, 26, 45, 6, -41, -48, -43, -6, -7,
12, -17, -3, 22, -74, -48, -24, -67, -59, -53, -43, -49, -63, -50, -38, -32,
-18, -15, -42, -22, 82, -21, -86, -7, -57, -58, 76, -50, -113, -30, 71, 46,
34, -11, -9, 47, 69, 26, 14, 74, 57, -4, 23, 52, 53, 45, 14, 15,
-20, -6, 25, 18, 34, 46, -9, 33, 73, 40, 38, 28, -41, -56, -42, 0,
-11, 15, -13, -6, 52, -27, -83, -22, -67, -72, -52, -47, -45, -59, -52, -39,
-30, -26, -7, -31, -22, 64, 49, -81, -6, -54, -63, 72, 29, -96, -41, 64,
58, 44, 22, -19, 45, 74, 48, -1, 43, 52, -3, 32, 57, 52, 58, 17,
13, 0, -19, 2, 13, 39, 43, 0, 8, 60, 30, 39, 36, -24, -56, -49,
-1, -13, 6, 0, -31, 64, -31, -96, -21, -31, -89, -42, -38, -46, -53, -56,
-48, -26, -25, -10, -15, -38, 61, 56, -69, -51, -14, -90, 74, 35, -93, -91,
14, 66, 49, 26, -25, 12, 67, 49, -11, 35, 81, 19, 7, 52, 52, 62,
38, 14, -5, -25, 1, 6, 18, 52, -1, 4, 59, 50, 26, 43, -10, -45,
-50, -19, -7, 3, -4, -34, 37, 40, -76, -29, -35, -88, -56, -35, -37, -47,
-60, -40, -22, -29, -8, -17, -44, 17, 88, -1, -49, -16, -97, 0, 90, -37,
-91, 22, 65, 42, 43, -19, 16, 66, 71, 12, -4, 79, 22, 4, 45, 48,
47, 52, 17, -4, -20, -8, -1, 24, 56, 15, -17, 36, 53, 21, 45, 28,
-30, -58, -15, -7, -13, 11, -26, 34, 42, -70, -66, -20, -73, -59, -37, -39,
-39, -48, -44, -23, -30, -24, -10, -30, 14, 81, 7, -77, -16, -53, -8, 85,
-34, -119, -34, 63, 35, 46, 4, -13, 43, 74, 4, -6, 75, 54, -6, 39,
44, 49, 57, 27, 5, -19, -2, 8, 7, 51, 12, -21, 37, 67, 24, 30,
27, -34, -64, -42, 0, -7, 12, -29, -9, 68, -20, -65, -15, -78, -93, -44,
-33, -39, -45, -44, -29, -20, -25, -16, -25, -11, 54, 57, -75, -13, -51, -81,
63, 46, -118, -33, 67, 51, 34, 3, -14, 43, 82, 43, -17, 73, 55, -3,
19, 44, 43, 59, 28, 4, -13, -12, 16, 18, 50, 47, -2, -2, 70, 33,
23, 39, -5, -55, -43, 11, -4, -3, 1, 0, 67, -20, -90, -27, -36, -89,
-55, -35, -29, -41, -49, -33, -19, -24, -16, -15, -21, 53, 68, -53, -63, -11,
-83, 63, 49, -94, -88, 25, 53, 24, 20, -15, 2, 82, 48, -19, 30, 86,
24, 9, 42, 43, 56, 46, 19, -12, -12, 7, 8, 35, 54, -1, -10, 62,
60, 18, 48, -4, -58, -71, -14, 12, -10, -7, -26, 44, 43, -86, -29, -32,
-91, -77, -36, -32, -48, -51, -38, -15, -33, -20, -19, -36, 15, 80, -57, -69,
-6, -82, -18, 87, -87, -85, 27, 74, 25, 20, -13, 9, 62, 64, 5, 34,
84, 16, -6, 29, 37, 69, 43, 25, 8, -21, 6, 3, 32, 65, 31, -18,
62, 61, 19, 53, 38, -33, -73, -24, -2, -15, 2, -23, 45, 42, -64, -57,
-17, -94, -70, -34, -27, -38, -57, -33, -14, -31, -33, -15, -37, 16, 88, 17,
-90, -16, -84, -22, 89, -30, -114, -34, 72, 29, 33, 11, -13, 63, 66, 7,
-8, 66, 52, -12, 29, 44, 62, 62, 37, 10, -31, -4, 11, 3, 73, 40,
-33, 6, 80, 37, 53, 43, -38, -80, -53, -5, -13, 2, -22, 11, 73, -74,
-63, -13, -72, -96, -52, -29, -40, -53, -39, -31, -24, -26, -14, -25, -26, 55,
23, -91, -17, -32, -87, 54, -30, -109, -38, 62, 57, 42, 16, -14, 38, 75,
41, -6, 62, 50, -13, 4, 46, 67, 63, 34, 18, -12, -9, 5, 8, 47,
56, 0, 7, 66, 32, 33, 60, -1, -70, -60, -20, 2, 8, -31, 12, 67,
-21, -84, -22, -74, -97, -50, -32, -31, -50, -45, -25, -20, -33, -16, -20, -33,
51, 87, -46, -77, -25, -78, 48, 48, -86, -87, 61, 53, 34, 40, -11, 39,
80, 43, -14, 26, 76, 6, 4, 36, 59, 63, 52, 17, -26, -24, 5, -5,
42, 60, -1, -29, 49, 63, 20, 59, 8, -57, -72, -48, 2, 18, -16, -27,
52, -20, -79, -21, -30, -91, -76, -34, -37, -52, -48, -34, -17, -26, -15, -11,
-30, 14, 80, -44, -69, 0, -75, -25, 46, -83, -81, 20, 63, 35, 44, -17,
8, 74, 67, -15, 31, 79, 29, 5, 19, 47, 61, 54, 42, -6, -26, 7,
-8, 17, 66, 30, -22, 54, 59, 14, 43, 34, -47, -75, -54, -7, 15, -18,
-30, 51, 33, -70, -46, -31, -87, -79, -44, -26, -43, -35, -32, -26, -16, -14,
-24, -38, 14, 87, 28, -83, 3, -72, -24, 83, -24, -109, 19, 67, 46, 56,
0, 19, 78, 59, 10, -3, 66, 28, 1, 26, 40, 48, 49, 45, -3, -32,
-2, -2, 12, 63, 33, -30, 13, 73, 14, 46, 34, -30, -63, -65, 0, 10,
-6, -42, 9, 34, -77, -49, -4, -66, -99, -35, -24, -47, -41, -32, -35, -18,
-21, -13, -30, -25, 85, 30, -84, -13, -13, -77, 84, -29, -112, -31, 52, 50,
61, -11, -16, 65, 63, 13, 2, 67, 63, 3, 16, 40, 42, 53, 63, 19,
-37, 13, 0, -19, 41, 67, -32, 11, 75, 28, 21, 58, -24, -69, -69, -16,
7, -1, -35, 5, 64, -27, -76, -3, -65, -97, -63, -25, -37, -46, -34, -36,
-25, -19, -12, -39, -24, 51, 82, -42, -23, -19, -73, 52, 38, -96, -30, 49,
57, 66, 18, -7, 75, 56, 29, -6, 24, 68, -2, 15, 50, 42, 43, 57,
15, -26, -6, 11, -20, 38, 66, 0, -24, 50, 39, 32, 52, 6, -40, -74,
-15, 4, 1, -19, -35, 70, -25, -84, -11, -23, -91, -57, -26, -43, -53, -42,
-43, -18, -17, -6, -31, -45, 62, 79, -48, -67, 1, -81, 54, 38, -95, -87,
21, 64, 49, 16, -30, 47, 74, 22, -8, 31, 79, 27, 2, 45, 38, 38,
62, 44, -10, -4, 12, -20, 0, 61, 7, -17, 47, 64, 25, 40, 9, -32,
-77, -47, 4, -5, -13, -32, 47, 42, -74, -11, -24, -92, -73, -33, -34, -51,
-51, -45, -15, -18, 0, -28, -53, 21, 89, 23, -68, -2, -85, -26, 86, -26,
-91, 20, 71, 53, 47, -35, 38, 75, 43, 4, -2, 84, 24, -7, 35, 48,
29, 61, 44, -3, -9, 10, -22, 9, 60, 25, -24, 19, 59, 21, 39, 27,
-7, -56, -44, 7, -11, 1, -28, 44, 45, -78, -59, 0, -67, -75, -31, -41,
-52, -46, -42, -17, -24, 1, 2, -59, 15, 81, 23, -86, -28, -28, -26, 80,
-26, -114, -38, 68, 55, 44, -22, -4, 77, 37, 5, 4, 74, 51, -16, 42,
50, 34, 45, 54, 20, -9, 9, -9, -21, 37, 26, -28, 21, 75, 43, 28,
21, -3, -58, -81, -11, -3, 5, -22, -7, 64, -24, -57, -4, -76, -95, -50,
-41, -49, -47, -39, -26, -20, -12, 2, -60, -27, 60, 69, -83, -30, -26, -76,
49, 40, -116, -35, 61, 65, 52, -11, 3, 70, 55, 25, -8, 63, 55, -11,
18, 56, 39, 50, 60, 16, -19, 3, -17, -24, 42, 52, -8, -8, 67, 46,
39, 28, 1, -26, -78, -6, 1, -7, -5, -1, 62, -31, -81, -6, -40, -95,
-42, -33, -45, -51, -45, -33, -21, -5, 11, -33, -18, 55, 70, -37, -74, -4,
-77, 46, 36, -101, -92, 18, 67, 48, 14, -18, 45, 58, 25, -11, 26, 77,
23, 16, 62, 47, 27, 57, 50, -19, -7, -2, -22, 9, 49, -7, -8, 53,
59, 32, 22, 14, -15, -81, -49, 8, -10, -7, -24, 35, 32, -79, -7, -33,
-105, -70, -28, -41, -63, -51, -36, -24, -15, 24, -29, -63, 18, 86, -39, -78,
-7, -73, -34, 80, -88, -100, 9, 75, 53, 35, -24, 33, 74, 50, 2, 24,
81, 28, -10, 40, 65, 30, 56, 50, 2, -17, -7, -22, 11, 57, 30, -20,
43, 64, 40, 28, 12, 8, -78, -53, 0, -16, -7, -20, 31, 31, -75, -49,
16, -107, -80, -33, -31, -49, -55, -33, -19, -12, 18, 7, -60, 9, 72, 36,
-80, -42, -71, -37, 82, -12, -107, -52, 72, 57, 44, -5, -4, 74, 47, 6,
-6, 53, 57, -9, 31, 60, 37, 41, 67, 1, -22, -5, -13, -8, 48, 32,
-12, 6, 55, 57, 36, 6, 4, -50, -86, -20, -14, 3, -15, -12, 54, -67,
-52, 12, -70, -104, -49, -37, -53, -57, -33, -25, -25, 19, -2, -56, -28, 39,
49, -75, -49, -21, -84, 28, -10, -109, -50, 49, 63, 54, 0, -1, 62, 67,
38, -20, 52, 63, -3, 8, 54, 33, 39, 68, 36, -25, -20, -16, -7, 43,
45, -9, 2, 68, 67, 46, 18, 10, -53, -86, -12, -4, -1, -15, -13, 52,
-16, -82, -3, -60, -104, -49, -26, -42, -64, -29, -29, -29, 2, 10, -45, -26,
34, 92, -7, -98, -15, -87, 22, 58, -79, -95, 52, 64, 45, 21, -5, 58,
53, 43, -8, 9, 75, 4, 5, 46, 42, 23, 55, 44, -22, -23, 2, -10,
42, 42, -12, -27, 34, 72, 46, 22, 12, -17, -90, -52, -4, 1, 3, -36,
23, -13, -75, 1, -6, -89, -74, -26, -37, -66, -47, -29, -33, 4, 11, -27,
-44, 0, 96, -8, -100, -12, -56, -51, 53, -83, -96, 9, 65, 43, 20, -9,
44, 59, 48, -7, 13, 75, 29, -5, 27, 37, 21, 59, 75, 11, -33, 3,
-9, 20, 57, 22, -32, 32, 78, 61, 33, 13, -15, -93, -57, 4, -1, 3,
-37, 30, 33, -64, -43, -9, -89, -69, -30, -33, -61, -41, -28, -37, -15, 10,
-21, -39, -3, 63, 67, -70, -7, -44, -51, 64, -12, -107, 8, 63, 45, 44,
-2, 45, 56, 48, 27, -20, 44, 36, -6, 21, 51, 28, 34, 77, 13, -33,
-6, 0, 15, 60, 22, -33, -8, 54, 61, 37, 10, 9, -56, -90, 9, 1,
1, -35, -11, 38, -61, -45, 10, -60, -89, -29, -34, -69, -68, -24, -36, -14,
5, -5, -32, -22, 58, 70, -69, -54, 13, -73, 58, -21, -114, -43, 49, 59,
41, -15, 18, 71, 42, 23, -22, 45, 68, 10, 5, 46, 34, 38, 69, 49,
-11, -6, 4, -3, 46, 49, -34, -9, 43, 64, 53, 14, 7, -56, -88, -9,
6, -1, -44, -6, 63, -19, -75, 14, -63, -97, -46, -29, -49, -61, -31, -43,
-22, 4, 1, -26, -25, 21, 88, 9, -46, 11, -68, 17, 44, -88, -40, 49,
62, 53, 15, 18, 69, 48, 39, -16, 1, 66, 5, 2, 40, 41, 22, 71,
50, -9, -19, 1, -4, 49, 49, -23, -33, 28, 59, 45, 22, 10, -19, -84,
-19, 3, 5, -20, -40, 56, -29, -69, 7, -19, -99, -47, -30, -49, -64, -45,
-42, -13, -6, -9, -11, -28, 23, 84, 6, -81, -5, -43, 28, 49, -89, -95,
9, 70, 50, 19, 2, 59, 61, 34, -14, 8, 75, 34, -9, 32, 40, 31,
62, 71, 14, -23, 6, -2, 15, 55, -16, -28, 25, 62, 66, 37, 3, -17,
-88, -59, 2, 0, -27, -38, 41, 24, -70, 16, -16, -94, -68, -35, -35, -61,
-49, -48, -40, -16, -9, -9, -34, -10, 67, 67, -81, 0, -43, -45, 66, -22,
-96, 12, 73, 59, 44, 2, 47, 65, 40, 3, -15, 70, 38, 0, 12, 45,
42, 65, 76, 20, -29, -8, 5, 17, 48, 15, -36, -10, 69, 63, 30, 3,
6, -55, -59, 9, 13, -13, -56, 47, 24, -70, -21, 12, -77, -62, -38, -44,
-55, -57, -43, -37, -20, -18, -2, -10, -8, 60, 66, -59, -42, -7, -49, 67,
-25, -115, -36, 54, 62, 60, -3, 5, 71, 29, 5, -6, 50, 66, 16, 16,
50, 41, 44, 74, 51, -31, -17, 12, 15, 32, 23, -40, -19, 62, 79, 49,
5, 6, -54, -84, -12, 20, -25, -60, 4, 52, -31, -22, 0, -80, -86, -42,
-46, -50, -41, -43, -48, -21, -17, 1, -2, -20, 18, 84, -60, -40, -5, -79,
20, 49, -111, -41, 52, 69, 62, 24, 15, 71, 44, 21, -14, 52, 68, 2,
-6, 39, 54, 34, 64, 52, -10, -28, 3, 20, 43, 50, -12, -46, 56, 77,
63, 9, -4, -18, -92, -9, 20, -14, -51, 1, 46, -24, -47, 9, -31, -88,
-42, -43, -50, -40, -39, -55, -22, -13, -7, -6, -17, 28, 88, 4, -87, -8,
-61, 23, 39, -95, -97, 10, 69, 56, 20, -4, 60, 45, 22, -14, 10, 78,
39, -6, 34, 57, 35, 45, 75, -11, -32, 1, 17, 28, 41, -17, -44, 21,
65, 69, 22, 6, -21, -93, -50, 22, -8, -47, -37, 33, 15, -44, 3, -40,
-94, -59, -38, -53, -49, -38, -53, -47, -24, -6, -7, -24, 0, 70, 12, -85,
-13, -38, -36, 62, -99, -97, 21, 72, 54, 39, -3, 67, 68, 25, 4, 14,
75, 42, 1, 11, 50, 36, 44, 79, 27, -37, -16, 16, 18, 41, 27, -37,
14, 61, 67, 47, 16, 3, -86, -41, 13, 2, -24, -53, 27, 9, -51, -17,
-11, -95, -58, -36, -43, -51, -40, -55, -54, -30, -18, 0, -26, -1, 74, 72,
-65, -56, -39, -35, 67, -29, -118, -35, 74, 61, 34, -16, 28, 64, 23, 7,
-12, 50, 74, 0, 12, 56, 55, 29, 67, 27, -46, -17, 26, 24, 34, 29,
-35, -32, 39, 70, 45, 12, -1, -75, -78, 12, -4, -31, -50, 0, 36, -56,
-19, -10, -82, -88, -41, -44, -46, -27, -42, -62, -36, -18, 7, -10, -22, 25,
62, -69, -54, -5, -62, 25, -29, -112, -32, 64, 71, 55, -8, 31, 77, 33,
18, -14, 53, 70, 14, 3, 42, 46, 26, 65, 60, -19, -41, 32, 31, 20,
35, 0, -20, 42, 61, 59, 28, 15, -81, -82, 11, 10, -14, -41, 1, 37,
-36, -41, 1, -94, -83, -29, -41, -55, -27, -48, -59, -27, -29, -9, -2, -22,
27, 87, -1, -90, -13, -67, 30, 38, -95, -87, 69, 73, 45, 9, 5, 69,
28, 23, -12, 9, 78, 19, 4, 46, 56, 23, 49, 63, -23, -42, 15, 32,
18, 43, 14, -35, 3, 61, 60, 24, 9, -38, -91, -23, -5, -17, -31, -35,
34, -38, -42, -3, -61, -94, -48, -41, -53, -29, -25, -67, -52, -23, -10, -6,
-22, 2, 89, 3, -82, -11, -48, -35, 31, -96, -85, 23, 78, 55, -1, 1,
70, 62, 34, -23, 0, 77, 51, 1, 21, 53, 31, 51, 75, 23, -45, 14,
31, 13, 28, 34, -23, 6, 56, 58, 33, 19, -40, -87, -16, 7, -25, -24,
-34, 38, 9, -52, -16, -55, -84, -43, -30, -44, -38, -41, -64, -40, -29, -21,
3, -31, 0, 70, 70, -54, -14, -48, -27, 61, -38, -112, 20, 78, 55, 21,
-10, 38, 62, 34, -3, -34, 44, 47, 2, 22, 48, 35, 36, 73, 17, -48,
-17, 29, 13, 29, 33, -15, -24, 35, 59, 30, 24, 9, -72, -56, 10, -24,
-20, -50, -1, 7, -54, -13, -23, -86, -69, -23, -43, -40, -31, -52, -44, -35,
-17, 8, -26, -19, 68, 72, -50, -45, -15, -56, 64, -52, -112, -28, 62, 73,
17, -10, 35, 68, 37, 2, -31, 46, 73, 10, 9, 50, 28, 31, 68, 50,
-28, -6, 28, 18, 16, 34, -4, -26, 28, 72, 45, 8, 12, -74, -56, 17,
-17, -25, -41, 9, 32, -37, -31, -36, -95, -63, -17, -28, -43, -37, -52, -41,
-27, -36, 3, -22, -27, 28, 95, 15, -53, -20, -59, 45, 24, -109, -23, 67,
75, 38, 0, 4, 68, 42, 25, -22, -3, 71, 18, 4, 37, 44, 24, 63,
52, -23, -29, 28, 29, 11, 42, 31, -19, -8, 65, 46, 14, 18, -45, -92,
23, -9, -25, -39, -21, 34, -39, -35, -11, -74, -90, -16, -30, -38, -38, -50,
-50, -29, -40, 4, 1, -28, 28, 86, 13, -73, -17, -54, 46, 22, -114, -80,
33, 81, 42, -4, -1, 64, 61, 30, -18, -1, 64, 44, 7, 50, 44, 19,
46, 68, 14, -31, 20, 29, 14, 30, 31, -19, -7, 51, 64, 22, 13, -43,
-83, -5, 5, -23, -34, -22, 37, 0, -47, -7, -71, -95, -29, -15, -41, -41,
-51, -52, -27, -44, -22, 0, -33, -2, 66, 76, -69, -10, -54, -22, 65, -50,
-81, 24, 77, 63, 19, -28, 70, 70, 38, -2, -30, 75, 48, 4, 25, 52,
33, 43, 69, 15, -38, -3, 29, 19, 42, 45, -5, -26, 48, 61, 24, 10,
-9, -80, -1, 9, -31, -23, -27, 17, -4, -49, -13, -37, -100, -30, -20, -37,
-39, -47, -51, -16, -53, -29, 20, -24, -6, 63, 82, -47, -47, -16, -26, 66,
-42, -105, -25, 60, 61, 15, -36, 24, 80, 37, 4, -35, 36, 73, 22, 28,
48, 34, 29, 60, 60, -48, -10, 34, 19, 25, 38, -5, -23, 25, 63, 42,
-2, -5, -72, -53, 17, -14, -22, -33, 15, 33, -35, -13, -43, -104, -60, -7,
-24, -42, -50, -48, -15, -29, -58, 14, -26, -21, 26, 89, -44, -44, -13, -68,
36, 27, -110, -19, 68, 74, 38, -21, 22, 80, 54, 32, -27, 36, 69, 27,
17, 38, 45, 22, 60, 61, -25, -40, 21, 18, 28, 42, 23, -16, 27, 66,
40, 8, 0, -50, -45, 17, -16, -31, -39, -21, 38, -29, -34, -14, -72, -57,
-9, -25, -37, -50, -58, -22, -30, -48, -3, -5, -23, 29, 91, 30, -72, -17,
-52, 36, 16, -111, -77, 33, 76, 39, -35, -31, 76, 47, 33, -24, -4, 72,
49, 21, 30, 49, 28, 42, 78, -27, -37, 21, 31, 7, 39, 27, -19, -5,
53, 64, 8, 5, -53, -84, 0, 8, -32, -39, -10, 44, -6, -20, -12, -79,
-85, -22, -19, -34, -48, -60, -39, -22, -38, -7, -3, -19, -9, 59, 29, -81,
-17, -32, -14, 55, -113, -82, 32, 82, 64, 6, -29, 74, 60, 46, 12, -13,
81, 48, 17, 22, 43, 31, 43, 74, 9, -41, -2, 27, 2, 22, 48, 5,
-1, 53, 59, 21, 16, -9, -96, -3, 18, -16, -34, -41, 50, -7, -34, -9,
-53, -89, -23, -15, -35, -39, -53, -39, -16, -27, -24, 1, -13, -8, 63, 82,
-54, -53, -31, -8, 60, -68, -127, -18, 80, 65, 4, -53, 29, 77, 44, 6,
-45, 48, 74, 16, 27, 46, 48, 25, 61, 11, -46, -7, 29, 21, 26, 44,
2, -19, 32, 65, 15, 16, -12, -98, -55, 21, -14, -35, -41, 35, 36, -39,
-12, -52, -107, -63, -17, -29, -36, -54, -51, -25, -12, -27, -3, -15, -19, 26,
75, -61, -50, 3, -32, 41, -71, -117, -15, 72, 82, 39, -54, 35, 71, 37,
41, -38, 45, 74, 29, 18, 38, 52, 21, 61, 51, -33, -37, 34, 31, 12,
34, 30, -17, 37, 69, 28, 9, 18, -98, -51, 20, -2, -28, -47, 32, 25,
-32, -17, -26, -111, -58, -26, -28, -24, -51, -41, -22, -20, -34, -7, -3, -22,
26, 90, 13, -76, 6, -29, 36, -2, -111, -66, 69, 81, 48, -41, -33, 70,
38, 41, -21, -5, 77, 34, 19, 39, 58, 34, 44, 40, -27, -25, 13, 30,
18, 35, 23, -17, 7, 54, 34, 16, 15, -64, -92, -2, 2, -34, -53, -3,
39, -35, -16, -27, -100, -92, -38, -24, -22, -54, -54, -27, -10, -35, -13, -6,
-20, -7, 84, 14, -71, -1, -24, -4, -3, -112, -60, 37, 81, 76, -43, -29,
77, 52, 40, -10, 1, 74, 48, 17, 28, 54, 24, 45, 69, 0, -37, 14,
25, 18, 24, 38, -22, 8, 63, 51, 18, 23, -68, -87, -3, 14, -16, -44,
-2, 31, -26, -32, -11, -95, -91, -40, -25, -25, -39, -45, -25, -13, -27, -18,
-1, -20, -13, 51, 77, -52, 6, -23, -9, 47, -72, -105, 34, 76, 73, -1,
-56, 41, 44, 43, 28, -24, 38, 43, 15, 26, 54, 37, 27, 60, -12, -36,
1, 20, 18, 27, 44, 6, -19, 30, 55, 19, 21, -30, -99, -40, 19, -3,
-41, -32, 29, -5, -26, -9, -71, -98, -58, -30, -32, -44, -46, -39, -21, -23,
-13, 3, -17, -20, 55, 81, -49, -43, 9, -30, 44, -72, -111, -9, 62, 74,
-9, -62, 40, 70, 41, 13, -28, 47, 69, 23, 5, 66, 40, 32, 61, 13,
-31, -5, 14, 22, 25, 53, -2, -22, 30, 60, 42, 21, -28, -98, -50, 27,
22, -22, -36, 29, -9, -46, -4, -68, -89, -49, -34, -38, -43, -47, -42, -27,
-11, -23, -9, -11, -17, 13, 85, 14, -46, 16, -16, 39, -8, -114, -5, 63,
70, 37, -57, -32, 70, 39, 43, -19, -2, 69, 27, 8, 49, 60, 38, 68,
17, -30, -22, 10, 30, 21, 41, 16, -21, 6, 56, 45, 22, 2, -71, -86,
19, 18, -16, -49, 9, 21, -50, 3, -30, -91, -82, -31, -29, -50, -50, -40,
-35, -13, -28, 0, -2, -21, -10, 83, 16, -82, 1, -1, 41, -7, -122, -65,
39, 73, 43, -57, -29, 79, 50, 43, -18, -6, 64, 46, 9, 52, 58, 40,
67, 50, -11, -27, 10, 28, 13, 34, 17, -21, 3, 50, 60, 26, 3, -83,
-87, -6, 17, 6, -46, 13, 14, -52, -21, -36, -92, -86, -45, -18, -35, -46,
-33, -33, -19, -26, -9, -7, -18, -3, 57, 70, -79, 11, -7, 3, 41, -80,
-69, 38, 85, 75, -9, -70, 81, 53, 44, 4, -36, 75, 41, 3, 25, 65,
45, 63, 47, -12, -27, -11, 13, 12, 35, 43, -6, -24, 52, 60, 30, 22,
-41, -99, -15, 10, 7, -32, -18, 28, -48, -25, -11, -67, -92, -48, -20, -36,
-52, -43, -38, -10, -31, -11, 7, -13, 0, 58, 67, -65, -39, 28, 7, 33,
-80, -107, -10, 59, 76, 0, -67, 34, 70, 41, 3, -32, 54, 66, 13, 26,
66, 42, 52, 70, 14, -22, -20, 9, 14, 19, 43, -6, -28, 26, 75, 53,
14, -51, -99, -44, 9, 5, -25, -11, 23, -16, -40, -10, -75, -94, -65, -35,
-34, -52, -35, -45, -21, -17, -27, 9, -5, -2, 12, 85, -55, -42, 29, 6,
36, -24, -102, -4, 54, 66, 45, -56, 42, 65, 37, 32, -35, 57, 60, 18,
10, 51, 61, 46, 67, 31, -11, -38, -11, 7, 11, 51, 29, -22, 23, 74,
50, 21, -7, -81, -50, 3, 5, -6, -19, 7, -24, -38, 3, -44, -104, -51,
-30, -50, -59, -36, -41, -18, -12, -26, 2, -1, 1, 21, 83, 9, -86, 1,
22, 39, -29, -121, -59, 44, 68, 39, -60, -13, 86, 45, 28, -26, 22, 80,
44, 1, 45, 65, 44, 58, 50, -11, -35, -5, 16, 4, 33, 27, -20, -8,
55, 68, 22, -3, -84, -85, -8, 10, -10, -21, 8, -6, -55, 6, -48, -105,
-69, -35, -46, -55, -33, -45, -43, -8, -21, 10, 5, -4, 1, 50, 14, -84,
-10, 28, 36, 19, -113, -58, 42, 76, 67, -23, -9, 88, 48, 43, 6, 23,
76, 41, 5, 25, 58, 35, 59, 59, 16, -36, -27, 20, -5, 28, 42, -7,
-4, 45, 58, 36, 22, -46, -85, 1, 12, -7, -22, -11, -8, -55, -15, -19,
-89, -68, -31, -49, -69, -42, -41, -43, -7, -28, -12, 13, 0, -3, 51, 74,
-55, -55, 30, 42, 24, -85, -102, 0, 74, 57, -24, -64, 54, 78, 33, 5,
2, 58, 59, 17, 18, 52, 53, 49, 60, 18, -43, -28, 23, 6, 5, 40,
-11, -26, 31, 70, 28, 22, -48, -104, -33, 12, -1, -22, -16, 16, -40, -47,
-13, -84, -95, -43, -25, -70, -37, -41, -64, -17, -18, -14, 19, 0, 0, 16,
68, -50, -55, 22, 34, 48, -92, -99, -3, 59, 76, 34, -66, 50, 81, 38,
12, 2, 61, 64, 35, 14, 33, 45, 51, 61, 40, -22, -47, 24, 9, 11,
42, 23, -13, 31, 70, 38, 21, -3, -101, -31, 4, -1, -3, -33, 13, -32,
-45, -2, -57, -83, -28, -31, -65, -57, -38, -55, -23, -26, -32, 15, 15, -4,
13, 74, 10, -83, 21, 40, 45, -39, -115, -56, 61, 75, 32, -64, -15, 81,
30, 1, -9, 45, 65, 42, 20, 28, 50, 46, 55, 50, -22, -41, 11, 21,
2, 39, 27, -7, 1, 49, 36, 14, -2, -81, -70, -5, -8, -2, -27, 0,
-1, -54, 0, -50, -105, -59, -19, -71, -56, -40, -65, -40, -5, -29, 12, 23,
2, -11, 49, 6, -91, -15, 43, 54, -47, -119, -52, 39, 68, 72, -63, -18,
81, 48, 13, 1, 50, 65, 42, 27, 23, 58, 54, 49, 69, 25, -40, 10,
11, 5, 29, 40, -9, -7, 52, 57, 18, 15, -89, -67, -2, -15, -7, -21,
7, 1, -62, -17, -11, -107, -59, -30, -58, -57, -36, -66, -33, -7, -31, -3,
19, 2, 0, 39, 60, -54, -21, 56, 63, -3, -96, -95, 35, 81, 70, -21,
-57, 49, 48, 11, -2, 21, 61, 35, 16, 35, 61, 57, 42, 67, 20, -42,
-10, 24, 1, 32, 38, 4, -6, 28, 54, 16, 10, -48, -93, -30, -12, -10,
-23, -16, 13, -37, -10, -22, -103, -87, -30, -51, -50, -40, -60, -51, -15, -30,
-3, 10, 2, 0, 7, 58, -60, -61, 38, 51, 4, -89, -99, 2, 65, 74,
-16, -58, 53, 82, 32, 3, 4, 63, 61, 28, 21, 59, 52, 38, 65, 44,
-30, 5, 24, 2, 15, 32, 7, 4, 34, 66, 23, 3, -50, -99, -27, -4,
-19, -9, -13, 9, -39, -38, 9, -98, -86, -27, -34, -56, -44, -59, -57, -16,
-19, -32, 6, 6, -5, 18, 70, 0, -56, 38, 56, 36, -48, -113, 4, 57,
69, 32, -61, -11, 80, 33, 9, -8, 37, 60, 30, 25, 50, 60, 35, 72,
41, -40, -25, 21, 8, 16, 29, 11, 0, 25, 72, 21, 10, -14, -89, -58,
-7, -18, -14, -22, 6, -9, -42, -2, -65, -107, -51, -38, -53, -39, -47, -68,
-38, -19, -27, 14, 13, -5, -1, 76, 1, -88, -6, 56, 35, -53, -115, -46,
47, 69, 26, -62, -9, 88, 44, 10, 6, 35, 66, 44, 14, 51, 69, 39,
55, 73, -10, -28, 23, 9, 4, 28, 25, 0, 22, 70, 51, 9, -10, -93,
-65, -3, -17, -13, -21, 1, -7, -54, -27, -70, -108, -59, -31, -40, -41, -57,
-68, -38, -11, -29, -8, 18, 3, 11, 63, 64, -87, -12, 67, 60, -14, -101,
-47, 52, 83, 61, -30, -62, 93, 39, 8, 9, 8, 66, 44, 12, 30, 66,
47, 53, 71, -16, -55, 9, 25, 4, 26, 19, -5, 6, 76, 40, 5, 16,
-59, -93, 6, -16, -9, -20, -17, 14, -52, -26, -38, -101, -83, -37, -41, -36,
-48, -68, -57, -11, -27, 1, 32, 8, 10, 67, 65, -52, -68, 39, 54, -29,
-104, -96, 6, 81, 55, -32, -61, 57, 71, 9, 13, 4, 46, 64, 23, 34,
67, 36, 23, 70, 30, -49, 15, 27, -2, 10, 32, -8, 4, 61, 73, 23,
11, -62, -80, 4, -1, -19, -25, -19, 14, -34, -41, -19, -98, -77, -35, -34,
-39, -49, -64, -51, -18, -25, -23, 33, 12, 11, 37, 78, -52, -69, 40, 79,
6, -80, -84, 8, 74, 75, 15, -74, 59, 67, 10, 18, 10, 41, 68, 28,
11, 54, 55, 32, 67, 23, -41, -15, 19, 4, 12, 34, 10, -10, 59, 72,
28, 16, -23, -97, 7, -13, -22, -2, -34, -1, -36, -36, -14, -78, -95, -25,
-36, -42, -43, -58, -60, -18, -27, -26, 30, 23, 4, 43, 72, 6, -85, -15,
80, -1, -80, -109, -42, 58, 66, 21, -67, -5, 82, 36, 20, 7, 18, 57,
47, 10, 48, 54, 30, 58, 56, -46, -18, 20, 14, 6, 32, 6, -3, 38,
71, 46, 18, -29, -100, -25, 8, -27, 3, -35, 5, -3, -44, -10, -80, -93,
-43, -27, -39, -49, -69, -68, -28, -16, -41, 25, 25, 6, 29, 64, 47, -82,
-18, 77, 43, -42, -113, -43, 63, 67, 51, -32, 0, 91, 26, 10, 20, 13,
61, 53, 13, 30, 64, 31, 57, 63, -16, -45, -2, 26, 8, 24, 20, -3,
44, 67, 38, 18, 14, -77, -14, 12, -27, 8, -18, -19, -8, -36, 0, -47,
-105, -46, -38, -45, -35, -53, -84, -32, -16, -45, -9, 34, 10, 36, 66, 42,
-51, -71, 78, 42, -38, -94, -92, 24, 62, 53, -22, -60, 55, 58, 12, 19,
5, 41, 61, 19, 37, 58, 33, 37, 75, -5, -38, -6, 30, 12, 2, 20,
-3, 23, 56, 54, 23, 10, -82, -65, 19, -16, 2, -32, -13, 16, -38, -11,
-43, -103, -74, -41, -38, -33, -49, -75, -56, -22, -38, -1, 38, 14, 22, 47,
55, -44, -74, 43, 80, -8, -94, -83, 31, 71, 54, 22, -58, 53, 56, 11,
19, -1, 35, 58, 27, 18, 54, 36, 33, 71, 44, -18, -26, 37, 10, -3,
27, 5, 26, 48, 47, 40, 33, -47, -57, 21, -15, -3, -10, -34, 13, -45,
-11, 0, -86, -73, -37, -42, -43, -39, -60, -52, -25, -41, -24, 31, 25, 29,
45, 63, 14, -81, 43, 75, -15, -79, -99, -26, 62, 55, 16, -72, -1, 86,
17, 11, -8, 10, 59, 33, 23, 57, 58, 32, 61, 39, -28, -25, 22, 35,
1, 21, 4, 5, 40, 53, 41, 35, -49, -102, -12, 5, 1, -22, -43, 11,
-34, -52, 0, -87, -91, -52, -50, -37, -39, -59, -60, -32, -33, -30, 23, 39,
41, 32, 44, 17, -80, -23, 84, 35, -85, -102, -30, 54, 62, 55, -69, -1,
84, 40, 20, 6, 16, 52, 41, 19, 38, 57, 34, 62, 73, 2, -42, 25,
41, 1, 14, 21, -7, 36, 59, 49, 32, -9, -95, -14, 2, -6, 0, -50,
1, -37, -43, 14, -41, -100, -58, -49, -40, -27, -45, -63, -40, -38, -40, 5,
34, 44, 32, 40, 51, -52, -14, 95, 27, -63, -101, -75, 59, 60, 51, -35,
-55, 60, 42, 17, 9, 3, 35, 50, 11, 31, 60, 35, 41, 76, 9, -45,
-5, 45, 14, 18, 21, 1, 22, 48, 48, 38, -9, -90, -49, 7, 0, 1,
-53, -13, -5, -61, 14, -42, -99, -69, -53, -47, -26, -40, -61, -50, -39, -36,
13, 23, 31, 38, 21, 51, -52, -87, 48, 80, -61, -95, -62, 32, 55, 58,
-31, -59, 53, 68, 22, 7, 3, 42, 59, 29, 12, 58, 37, 33, 74, 49,
-31, 4, 40, 4, 10, 35, 7, 16, 50, 55, 46, 32, -95, -52, 6, -1,
17, -31, -8, -8, -66, -6, 7, -86, -74, -48, -54, -41, -33, -58, -53, -39,
-43, -13, 25, 34, 34, 18, 57, 16, -85, 53, 75, -27, -88, -97, 43, 65,
66, 15, -76, 13, 67, 16, 14, 0, 22, 65, 26, 15, 55, 55, 20, 73,
53, -35, -28, 40, 21, 18, 36, 5, -1, 26, 52, 48, 35, -63, -92, -11,
-4, 18, -36, -44, 5, -51, -8, -5, -91, -99, -59, -49, -40, -37, -50, -57,
-40, -47, -20, 29, 31, 36, 22, 50, 22, -90, -26, 89, -36, -97, -101, -9,
69, 73, 3, -78, 24, 93, 29, 11, 9, 17, 61, 53, 14, 60, 53, 17,
51, 79, 1, -23, 43, 30, 0, 33, 33, -17, 20, 54, 53, 47, -64, -85,
-16, -4, 14, -6, -38, 1, -67, -44, 22, -60, -89, -49, -53, -51, -34, -46,
-51, -34, -44, -44, 9, 32, 42, 23, 29, 62, -39, -20, 89, 13, -71, -103,
-11, 68, 72, 42, -57, -38, 90, 37, 4, 8, 15, 60, 51, 13, 38, 60,
32, 41, 70, 3, -45, 17, 50, 14, 37, 27, -6, 3, 44, 41, 44, -9,
-89, -50, -8, 21, 0, -56, -11, -25, -40, 18, -54, -108, -67, -56, -61, -28,
-35, -66, -44, -36, -46, 2, 32, 38, 41, 31, 58, -38, -79, 55, 8, -63,
-96, -64, 40, 68, 45, -58, -32, 79, 61, 15, 5, 11, 40, 72, 34, 28,
56, 35, 34, 74, 40, -46, 26, 39, 14, 48, 44, -7, 5, 36, 53, 45,
-14, -95, -48, -3, 0, 16, -51, -12, -35, -68, 4, -8, -105, -62, -49, -69,
-47, -29, -55, -49, -44, -55, -20, 32, 36, 42, 24, 48, 18, -73, 64, 73,
-36, -89, -56, 41, 71, 74, -6, -73, 67, 56, 18, 4, 12, 27, 61, 30,
18, 59, 55, 34, 79, 40, -52, -14, 45, 10, 46, 40, -9, -12, 50, 58,
41, 21, -67, -81, 3, 6, 18, -38, -30, -4, -68, 7, 1, -96, -98, -50,
-67, -40, -21, -56, -62, -36, -54, -23, 21, 32, 44, 26, 49, 19, -84, -17,
70, -43, -97, -93, -7, 62, 70, -10, -69, 29, 84, 42, -4, 21, 33, 51,
54, 19, 56, 52, 28, 61, 76, -52, -23, 38, 27, 26, 44, -8, -15, 28,
60, 44, 23, -59, -84, -11, 2, 15, -28, -26, -7, -64, -38, 16, -86, -85,
-47, -54, -59, -30, -53, -51, -27, -42, -37, 4, 22, 51, 37, 32, 51, -96,
-27, 90, 5, -82, -94, -16, 60, 70, 38, -52, 36, 96, 40, -14, 4, 32,
49, 50, 13, 35, 55, 19, 61, 75, -6, -43, 4, 28, 43, 53, 15, -20,
5, 68, 49, 39, -12, -90, -8, -2, 12, 2, -37, -10, -66, -38, 18, -53,
-102, -39, -52, -62, -39, -45, -57, -25, -46, -38, -5, 6, 42, 37, 24, 46,
-36, -82, 85, 5, -86, -102, -64, 33, 76, 36, -51, -20, 78, 75, -2, 6,
25, 31, 62, 15, 34, 59, 23, 32, 80, -12, -45, 11, 31, 23, 47, 13,
-16, 8, 48, 57, 48, -9, -92, -46, 3, 3, 5, -36, -12, -34, -68, 0,
-62, -104, -48, -43, -63, -41, -54, -62, -34, -29, -42, -8, 5, 38, 61, 27,
36, -28, -84, 49, 68, -58, -100, -61, 42, 80, 60, -11, -19, 77, 69, 10,
-9, 23, 29, 56, 37, 12, 53, 33, 35, 78, 33, -48, -21, 36, 30, 50,
32, -15, -8, 42, 57, 63, 32, -71, -46, -3, -1, 28, -13, -33, -43, -73,
-1, -13, -101, -80, -48, -68, -48, -37, -58, -38, -25, -38, -18, 7, 18, 64,
27, 32, 30, -82, 39, 63, -54, -90, -86, -3, 76, 63, 7, -47, 31, 86,
16, -10, 12, 24, 42, 34, 5, 44, 47, 15, 62, 38, -50, -24, 29, 41,
55, 24, -20, -2, 35, 47, 63, 36, -73, -85, -18, -14, 35, -13, -30, -17,
-73, -42, -11, -98, -76, -38, -65, -47, -36, -55, -42, -25, -45, -13, 11, 24,
62, 41, 14, 34, -86, -44, 85, 7, -95, -87, -8, 70, 75, 39, -44, 35,
77, 41, -3, -3, 32, 38, 40, 11, 26, 50, 18, 64, 78, -15, -44, 21,
42, 61, 47, -6, -19, 41, 44, 53, 61, -23, -72, -14, -21, 19, 21, -33,
-14, -70, -47, 8, -60, -98, -43, -67, -61, -36, -52, -42, -24, -48, -36, 9,
18, 58, 36, 10, 57, -13, -95, 79, 2, -93, -93, -45, 61, 67, 40, -34,
-15, 65, 39, -6, 9, 29, 25, 35, 18, 36, 58, 25, 29, 72, -15, -43,
-3, 35, 63, 42, -8, -14, 27, 48, 57, 55, -23, -85, -37, -21, 18, 15,
-40, -22, -42, -67, 9, -58, -94, -50, -52, -56, -36, -54, -59, -30, -30, -39,
3, 18, 44, 57, 3, 56, -2, -91, 26, 66, -89, -104, -53, 40, 76, 68,
-42, -15, 70, 70, 7, -13, 28, 30, 52, 25, 13, 61, 27, 37, 84, 33,
-41, -8, 39, 59, 51, 19, -18, 26, 55, 55, 66, 29, -84, -33, -29, -13,
29, -26, -15, -39, -62, -2, -24, -94, -44, -50, -65, -46, -42, -61, -34, -37,
-58, -11, 22, 41, 53, -3, 27, 57, -65, 35, 60, -61, -104, -93, 41, 76,
64, -10, -40, 44, 61, 5, -12, 22, 18, 34, 32, 13, 54, 50, 20, 78,
37, -39, -36, 22, 60, 43, 22, -14, 2, 53, 55, 64, 28, -75, -64, -25,
1, 47, -25, -35, -15, -61, -3, -33, -104, -66, -34, -67, -44, -42, -63, -46,
-27, -61, -9, 19, 19, 51, 22, 27, 50, -75, -45, 80, -62, -96, -87, -3,
78, 82, -12, -42, 43, 82, 39, -14, 14, 13, 37, 51, 7, 56, 55, 18,
55, 73, -6, -33, 29, 60, 51, 39, -1, 3, 52, 55, 69, 66, -86, -67,
-19, -18, 41, 23, -47, -21, -53, -41, -18, -79, -64, -40, -70, -63, -48, -61,
-32, -19, -56, -36, 10, 28, 49, 13, 0, 54, -14, -48, 83, 9, -79, -88,
-2, 89, 83, 24, -45, -3, 91, 34, -24, 10, 22, 17, 55, -3, 27, 68,
26, 51, 79, -3, -64, -12, 47, 48, 47, -4, -27, 31, 58, 70, 61, -45,
-94, -31, -30, 25, 23, -48, -34, -33, -33, -16, -77, -92, -46, -61, -65, -55,
-63, -50, -10, -51, -37, 9, 23, 48, 38, 4, 57, -6, -84, 36, 10, -80,
-94, -59, 54, 95, 26, -50, -15, 80, 80, -1, 7, 23, 13, 68, 29, 15,
70, 38, 26, 74, 48, -75, 1, 62, 37, 40, 28, -21, 29, 58, 62, 69,
-46, -95, -33, -27, -9, 42, -43, -27, -22, -41, -17, -42, -94, -44, -43, -76,
-60, -59, -53, -13, -36, -66, -16, 34, 44, 35, 2, 33, 54, -88, 21, 71,
-46, -100, -60, 51, 93, 63, -17, -49, 76, 77, 2, -18, 30, 11, 65, 39,
-2, 53, 60, 29, 75, 55, -55, -54, 51, 38, 36, 25, -24, -2, 51, 58,
67, 7, -88, -60, -35, -15, 51, -1, -45, -25, -49, -22, -38, -98, -74, -29,
-77, -53, -39, -66, -41, -34, -67, -24, 28, 42, 51, 2, 16, 54, -53, -59,
69, -50, -93, -82, -3, 85, 50, -24, -41, 44, 89, 41, -18, 24, 8, 39,
70, -4, 51, 59, 19, 43, 73, -51, -33, 50, 39, 27, 45, -17, 0, 46,
53, 69, 9, -89, -57, -18, -34, 23, 5, -34, -24, -45, -33, -19, -92, -62,
-37, -68, -70, -35, -56, -41, -23, -60, -44, 34, 38, 54, 21, -13, 56, -48,
-71, 69, 21, -81, -95, -4, 92, 75, 7, -56, 46, 92, 42, -17, 7, 13,
30, 72, 10, 20, 68, 9, 42, 79, -11, -70, 16, 39, 19, 43, 14, -6,
32, 45, 67, 55, -49, -79, -17, -38, 17, 34, -13, -20, -52, -30, -13, -72,
-92, -52, -65, -68, -42, -46, -51, -24, -59, -39, 21, 28, 44, 21, -15, 59,
29, -88, 12, 14, -84, -99, -53, 57, 69, 16, -49, 0, 81, 65, -10, 9,
3, 4, 72, 1, 22, 75, 28, 10, 70, -12, -62, 16, 49, 19, 36, 9,
1, 40, 38, 51, 56, -57, -80, -14, -35, -31, 42, -10, -24, -40, -49, -14,
-69, -93, -58, -53, -66, -34, -48, -50, -23, -40, -61, 20, 36, 40, 45, -3,
17, 29, -85, 12, 69, -35, -109, -53, 66, 82, 49, -19, 3, 79, 65, 3,
-9, 13, 4, 69, 40, 0, 55, 29, 12, 71, 45, -53, -33, 51, 29, 35,
31, -6, 10, 44, 55, 78, 0, -90, -11, -31, -36, 40, 26, -30, -40, -42,
-15, -41, -97, -78, -58, -61, -34, -44, -59, -23, -46, -66, -18, 30, 44, 56,
-7, 4, 66, -42, -60, 70, -45, -96, -86, 11, 84, 50, -24, -35, 47, 79,
10, -19, 10, -3, 35, 66, 3, 58, 58, 9, 41, 43, -41, -31, 35, 53,
34, 24, 3, 10, 36, 43, 78, -3, -83, -27, -7, -50, 37, 20, -25, -34,
-52, -21, -39, -96, -70, -57, -73, -28, -47, -63, -31, -36, -75, -10, 26, 36,
63, 24, -27, 67, -48, -67, 75, 17, -101, -80, 14, 82, 70, 10, -35, 51,
85, 54, -11, -3, 1, 36, 64, 11, 37, 56, 11, 45, 68, -1, -41, 31,
50, 34, 25, 18, 17, 33, 31, 69, 48, -54, -20, -13, -58, 2, 42, -9,
-38, -54, -20, -6, -74, -90, -60, -71, -40, -39, -68, -23, -38, -77, -37, 11,
15, 68, 19, -35, 49, 24, -98, 76, 15, -95, -95, -37, 74, 74, 8, -57,
14, 79, 57, -5, -5, 6, 11, 66, 9, 46, 82, 29, 20, 67, 6, -39,
-1, 45, 39, 30, 20, 19, 41, 33, 45, 41, -51, -44, -2, -54, 10, 45,
-11, -25, -44, -49, -11, -79, -91, -51, -69, -48, -37, -68, -38, -15, -69, -41,
15, 12, 41, 55, -22, 44, 23, -91, 14, 65, -91, -95, -41, 56, 84, 42,
-51, 24, 81, 77, 24, -17, 10, 6, 64, 40, 25, 87, 34, 25, 66, 40,
-30, 5, 44, 32, 21, 23, 20, 44, 23, 36, 69, -9, -44, 1, -60, -43,
48, 22, -16, -33, -50, -15, -38, -93, -54, -70, -66, -28, -53, -31, -13, -76,
-78, -2, 10, 37, 56, -19, -1, 58, -59, 19, 62, -59, -99, -80, 60, 76,
33, -35, -20, 57, 75, 27, -13, 1, -17, 31, 49, 32, 77, 58, 25, 66,
38, -27, -17, 33, 40, 28, 29, 25, 40, 37, 21, 66, -15, -68, -5, -28,
-43, 47, 17, -23, -19, -40, -16, -49, -99, -62, -48, -80, -28, -48, -53, -18,
-45, -81, -4, 7, 7, 64, 25, -1, 59, -53, -58, 71, -58, -101, -75, 19,
82, 67, -47, -32, 67, 90, 52, -11, 7, -15, 22, 60, 28, 82, 59, 14,
44, 73, 10, -21, 32, 37, 24, 32, 27, 51, 49, 16, 49, 39, -63, -6,
-24, -73, 3, 44, -22, -17, -34, -29, -26, -84, -69, -52, -77, -42, -36, -50,
-12, -50, -91, -39, 8, 10, 67, 29, -26, 45, 12, -55, 73, 1, -96, -97,
22, 81, 61, -5, -55, 21, 85, 48, -7, 4, -2, -9, 57, 24, 55, 81,
29, 45, 74, 3, -40, 4, 38, 27, 33, 23, 35, 64, 31, 54, 39, -53,
-31, 2, -79, 15, 44, -21, -13, -14, -29, -32, -88, -100, -56, -63, -49, -41,
-62, -21, -22, -88, -33, 6, -1, 45, 63, -29, 45, 14, -87, 17, 55, -90,
-96, -33, 66, 86, -9, -54, 33, 85, 70, 15, 9, 1, -10, 55, 41, 51,
70, 22, 20, 69, 46, -44, -2, 39, 27, 30, 39, 42, 56, 19, 37, 68,
-48, -23, -5, -75, -41, 46, -21, -7, -10, -35, -23, -54, -92, -49, -68, -77,
-41, -62, -11, -19, -84, -66, -8, -3, 47, 65, -19, -2, 56, -88, 21, 58,
-52, -98, -32, 67, 82, 35, -52, -22, 79, 70, 23, -6, 11, -18, 56, 44,
34, 79, 52, 15, 68, 41, -33, -21, 25, 30, 36, 30, 25, 52, 32, 43,
74, -17, -51, 3, -79, -38, 44, -2, -21, 1, -39, -22, -57, -107, -66, -47,
-84, -45, -67, -46, 3, -88, -69, -1, 0, 18, 76, -22, 1, 57, -56, -46,
81, -61, -113, -70, 35, 89, 28, -61, -22, 69, 78, 56, 7, 13, -26, 23,
65, 27, 82, 50, 10, 47, 60, -32, -20, 18, 30, 38, 34, 33, 54, 24,
21, 70, -25, -35, 13, -51, -89, 11, -4, -19, 4, -35, -35, -39, -107, -47,
-43, -93, -55, -58, -37, -2, -59, -89, -31, -6, 23, 80, 22, -34, 40, -58,
-48, 71, 1, -95, -69, 33, 82, 58, -18, -53, 71, 83, 58, 10, 14, -1,
22, 59, 24, 52, 72, 12, 48, 68, -7, -42, 2, 30, 39, 35, 23, 41,
46, 22, 70, 26, -55, -14, -52, -92, 12, 32, -27, -7, -40, -40, -35, -93,
-82, -28, -89, -55, -37, -44, -6, -62, -93, -36, -5, 2, 64, 20, -26, 43,
3, -86, 28, -9, -102, -90, -17, 69, 55, -30, -60, 40, 83, 68, 16, 13,
-7, -10, 55, 40, 49, 64, 26, 37, 70, -9, -34, -1, 28, 38, 28, 24,
49, 47, 16, 52, 65, -54, -1, -6, -98, -39, 37, -28, -2, -8, -47, -32,
-94, -77, -26, -76, -82, -44, -51, -3, -25, -94, -63, -10, -6, 62, 65, -20,
7, 13, -86, 34, 58, -75, -95, -19, 67, 74, 23, -61, 37, 81, 64, 30,
11, 14, -10, 56, 45, 33, 70, 31, 45, 74, 25, -34, -21, 28, 36, 32,
24, 30, 51, 22, 52, 57, -31, -30, -11, -90, -35, 47, 6, -16, -28, -47,
-20, -68, -106, -41, -80, -82, -41, -55, -25, -23, -96, -64, -6, -15, 21, 68,
-20, -1, 59, -50, -32, 56, -82, -108, -56, 33, 73, 25, -60, -8, 77, 69,
32, 12, 9, -24, 27, 68, 40, 69, 40, 32, 74, 16, -37, -18, 14, 32,
40, 21, 32, 55, 28, 29, 69, -35, -27, 3, -74, -81, 52, -2, -19, -8,
-52, -39, -70, -102, -35, -45, -90, -51, -55, -22, -2, -72, -90, 0, -21, 12,
73, 17, -38, 70, -47, -39, 82, -13, -102, -59, 34, 81, 57, -24, 5, 77,
67, 47, 6, 24, -20, 17, 62, 25, 56, 46, 32, 71, 54, -17, -43, 10,
33, 44, 34, 24, 43, 17, 33, 72, 2, -47, 4, -69, -81, 33, 46, -17,
-15, -52, -33, -42, -105, -69, -56, -90, -40, -44, -49, -2, -79, -85, -13, -17,
-14, 74, 11, -37, 48, 15, -79, 86, -21, -100, -81, -17, 84, 62, -23, -46,
58, 78, 43, 16, 23, -6, -18, 54, 23, 64, 66, 17, 54, 49, -27, -46,
-4, 24, 34, 38, 22, 45, 45, 18, 57, 9, -43, -2, -26, -91, 33, 36,
-14, -1, -38, -58, -39, -102, -62, -28, -90, -64, -42, -55, 5, -35, -104, -18,
-17, -13, 55, 54, -34, 46, 23, -73, 41, 49, -77, -85, -13, 80, 79, 15,
-30, 61, 69, 55, 29, 11, -3, -27, 52, 49, 34, 69, 37, 58, 67, 17,
-44, -1, 31, 25, 38, 38, 35, 34, 25, 62, 45, -29, 3, -31, -90, -17,
54, 9, -7, -48, -56, -26, -74, -88, -31, -88, -64, -23, -57, 3, -43, -102,
-50, -20, -35, 58, 52, -36, -1, 63, -46, 42, 39, -84, -93, -52, 80, 86,
15, -52, 12, 72, 69, 32, 2, 16, -26, 13, 53, 43, 81, 57, 47, 68,
16, -44, -23, 27, 22, 38, 34, 25, 36, 29, 40, 35, -24, -7, -7, -83,
-10, 55, 11, -5, -23, -60, -30, -81, -85, -33, -64, -89, -41, -65, -16, -4,
-88, -51, -17, -39, 16, 76, 2, -1, 71, -43, -28, 71, -35, -91, -49, 41,
96, 51, -50, 27, 74, 65, 62, 3, 9, -18, 21, 64, 34, 60, 50, 53,
78, 46, -17, -14, 22, 19, 28, 30, 27, 42, 13, 37, 67, -1, -7, -7,
-86, -64, 42, 42, -10, -32, -70, -37, -42, -89, -45, -67, -89, -51, -49, -10,
4, -76, -91, -18, -20, 9, 70, -2, -44, 55, 17, -32, 81, -25, -101, -70,
42, 88, 46, -27, -14, 66, 73, 50, -3, 7, -6, -13, 64, 22, 52, 68,
40, 71, 47, -17, -39, 5, 18, 28, 43, 27, 36, 34, 33, 70, -5, -25,
6, -58, -59, 44, 35, -7, -19, -61, -33, -45, -85, -62, -47, -80, -53, -50,
-39, 6, -32, -91, -16, -16, -24, 58, 51, -47, 54, 22, -62, 48, 42, -97,
-82, -14, 80, 73, -39, -17, 70, 70, 62, 29, 11, -2, -11, 56, 38, 28,
66, 40, 64, 67, 17, -48, 2, 24, 8, 29, 35, 39, 30, 28, 73, 44,
-29, 3, -48, -94, -4, 63, -4, -15, -52, -59, -42, -68, -58, -53, -86, -68,
-48, -43, 2, -38, -98, -56, -7, -18, 58, 51, -43, 3, 72, -60, 41, 38,
-84, -102, 0, 75, 63, -1, -42, 28, 70, 71, 28, 7, 24, -33, 57, 46,
26, 71, 56, 65, 62, 29, -27, -25, 24, 10, 31, 37, 35, 38, 24, 67,
36, -30, -6, -8, -95, 2, 64, 7, -10, -24, -60, -42, -71, -78, -47, -62,
-68, -56, -67, -9, -3, -102, -54, -17, -35, 17, 74, -48, 6, 77, -37, -26,
73, -80, -102, -52, 51, 95, -12, -40, 41, 75, 71, 62, 8, 21, -34, 13,
63, 24, 74, 56, 62, 69, 49, -19, -27, 21, 20, 18, 29, 37, 44, 21,
44, 60, -6, -2, -6, -81, -70, 37, 17, -11, -30, -60, -45, -58, -78, -46,
-67, -84, -52, -68, -3, -1, -85, -91, -35, -25, 15, 59, -5, -40, 62, -31,
-24, 82, -22, -111, -53, 42, 92, 32, -43, -1, 78, 68, 60, 13, 16, -20,
30, 64, 18, 68, 75, 54, 70, 54, 4, -39, -9, 15, 13, 19, 33, 48,
29, 49, 60, -10, -19, 14, -84, -63, 47, 40, -18, -13, -48, -47, -58, -90,
-62, -49, -88, -44, -68, -45, 11, -78, -94, -33, -15, -20, 54, 0, -49, 60,
41, -57, 45, -20, -115, -89, -10, 82, 29, -50, 2, 82, 74, 72, 13, 23,
-18, -22, 60, 41, 60, 68, 50, 60, 58, 8, -34, -14, 19, 17, 13, 38,
53, 41, 35, 61, 30, -23, 20, -39, -101, -7, 40, -19, -21, -29, -40, -48,
-95, -67, -49, -90, -59, -54, -46, 12, -42, -95, -68, -12, -8, 54, 54, -40,
-6, 41, -61, 35, 53, -76, -107, -9, 87, 73, -23, -36, 74, 70, 71, 23,
17, 19, -20, 60, 38, 41, 77, 46, 63, 58, 34, -10, -23, 25, 23, 25,
27, 30, 48, 42, 60, 33, -31, -1, -42, -102, -3, 58, -1, -28, -31, -38,
-51, -89, -95, -52, -87, -63, -58, -82, -20, -40, -100, -69, -11, -12, 16, 53,
-37, -7, 77, -25, -36, 53, -78, -105, -47, 48, 66, -27, -33, 53, 66, 58,
41, 31, 12, -33, 29, 62, 48, 72, 53, 64, 64, 26, -2, -18, 14, 23,
20, 26, 27, 50, 47, 52, 58, -26, -2, 3, -81, -69, 56, -3, -38, -19,
-32, -51, -95, -95, -50, -77, -83, -38, -87, -21, 1, -74, -93, -11, -9, 11,
56, 2, -54, 80, -16, -34, 75, -12, -106, -43, 41, 93, 24, -52, 53, 72,
68, 62, 31, 34, -39, 22, 61, 39, 71, 64, 61, 55, 35, 16, -26, 9,
19, 13, 29, 34, 43, 50, 60, 57, -1, -20, -7, -97, -69, 49, 27, -40,
-13, -38, -54, -69, -104, -77, -75, -80, -38, -67, -46, -3, -76, -87, -32, -10,
-14, 54, -2, -61, 39, 42, -45, 84, -19, -111, -70, 6, 86, 28, -35, 15,
76, 68, 64, 37, 31, -25, -23, 58, 43, 68, 63, 56, 61, 28, 16, -25,
-14, 17, 6, 23, 34, 42, 51, 60, 66, -15, -18, 12, -56, -106, 48, 25,
-43, -24, -21, -50, -72, -97, -72, -60, -88, -57, -67, -32, 16, -51, -106, -24,
-10, -16, 46, 48, -58, 35, 52, -42, 45, 56, -86, -72, 20, 87, 65, -8,
16, 72, 65, 71, 56, 36, -21, -19, 57, 59, 61, 73, 54, 60, 38, 37,
1, -12, 15, -8, 1, 27, 38, 46, 50, 58, 12, -26, 4, -55, -99, -2,
60, -21, -24, -17, -50, -62, -89, -97, -56, -86, -61, -54, -60, 6, -57, -105,
-58, -11, -22, 42, 50, -46, -40, 61, -4, 40, 45, -87, -104, -27, 85, 63,
-10, -29, 50, 76, 66, 60, 37, -6, -47, 25, 59, 54, 72, 49, 56, 50,
36, 1, -19, 8, 2, 2, 26, 43, 46, 34, 56, 7, -39, 2, -3, -86,
0, 64, -27, -47, -6, -29, -56, -91, -94, -52, -71, -75, -59, -56, 4, -22,
-96, -53, -5, -24, 12, 72, 7, -50, 61, -1, -19, 70, -20, -103, -37, 54,
84, 26, -35, 44, 80, 67, 64, 41, 3, -50, 7, 73, 53, 63, 58, 52,
49, 44, 24, -14, 16, 2, -11, 10, 32, 57, 42, 49, 37, -24, -17, -9,
-90, -57, 57, 17, -47, -4, -28, -50, -66, -87, -59, -80, -75, -46, -62, -22,
-27, -90, -85, -19, -7, 11, 68, 3, -78, 13, 54, -18, 72, -14, -104, -74,
51, 85, 24, -33, 4, 70, 69, 69, 38, 26, -21, -44, 74, 61, 59, 65,
58, 44, 40, 29, -8, 5, 13, -16, 12, 41, 59, 50, 47, 44, -27, -15,
20, -54, -62, 56, 16, -63, -22, -14, -55, -73, -86, -67, -73, -88, -45, -65,
-16, 9, -60, -83, -21, -7, -16, 44, 46, -81, 14, 48, -41, 37, 58, -103,
-82, 0, 88, 63, -29, 11, 62, 69, 78, 52, 41, -7, -54, 38, 79, 48,
61, 60, 53, 36, 43, -8, -1, 10, -12, -1, 23, 59, 54, 45, 59, 13,
-33, 19, -57, -104, 11, 63, -68, -22, -11, -46, -60, -85, -81, -72, -79, -51,
-54, -45, 6, -63, -97, -48, 1, -25, 40, 50, -58, -53, 59, -42, 39, 65,
-72, -99, -41, 88, 67, -15, -22, 38, 70, 79, 54, 43, 34, -52, 43, 87,
44, 52, 60, 50, 38, 49, 16, -15, 7, -6, 5, 25, 48, 57, 35, 62,
18, -43, 0, -8, -100, 14, 61, -35, -45, -8, -41, -47, -82, -98, -72, -73,
-45, -49, -46, 7, -22, -104, -54, 5, -17, 4, 66, -56, -59, 55, 6, -20,
78, -68, -96, -37, 54, 95, -17, -25, 42, 65, 72, 75, 38, 38, -45, -27,
79, 70, 59, 61, 51, 41, 42, 8, -17, 12, 2, -12, 9, 41, 52, 33,
50, 52, -21, 1, -13, -93, -47, 64, -29, -46, -16, -34, -37, -55, -97, -78,
-78, -63, -43, -52, 12, -35, -99, -83, -10, -12, 12, 65, -2, -79, 2, 5,
-22, 70, -9, -110, -67, 54, 86, 30, -25, 9, 71, 76, 74, 40, 49, 1,
-34, 75, 71, 59, 73, 54, 35, 51, 38, -17, -1, 5, -23, -1, 35, 54,
31, 57, 52, -32, -22, 17, -102, -50, 69, 15, -63, -22, -35, -42, -58, -87,
-83, -80, -59, -43, -52, -4, 0, -94, -77, -16, -4, -9, 46, -3, -71, 2,
44, -35, 19, 2, -101, -73, 14, 87, 26, -25, 13, 72, 75, 72, 38, 48,
-5, -67, 23, 74, 54, 72, 54, 44, 50, 29, -18, 3, 20, -9, -8, 30,
47, 40, 44, 67, 7, -18, 23, -61, -101, 18, 12, -57, -16, -27, -56, -46,
-84, -81, -81, -77, -49, -56, 1, 1, -68, -98, -51, 1, -7, 41, 34, -48,
-45, 44, -33, 21, 59, -60, -96, 11, 86, 60, -11, -11, 68, 76, 73, 52,
47, 31, -67, 24, 73, 54, 70, 65, 43, 41, 43, 4, -15, 22, -8, -13,
20, 46, 48, 45, 60, 5, -32, 15, -14, -97, 17, 54, -40, -34, -25, -55,
-36, -68, -89, -81, -78, -46, -51, -26, 4, -67, -88, -46, 1, -17, 15, 34,
-49, -45, 38, 6, -13, 53, -66, -99, -36, 59, 56, -17, -14, 48, 77, 70,
59, 48, 24, -50, -23, 65, 56, 68, 64, 50, 38, 37, 5, -10, 24, 16,
-16, 14, 47, 53, 36, 51, 44, -28, 11, -19, -101, -51, 50, -34, -26, -4,
-55, -43, -60, -90, -95, -94, -52, -47, -31, 9, -33, -88, -84, 3, -10, 17,
53, -6, -65, 34, 6, -7, 70, -9, -104, -33, 59, 84, 15, -24, 49, 74,
69, 72, 55, 45, -48, -18, 64, 60, 59, 68, 52, 38, 35, 27, -11, 22,
16, -10, 8, 26, 45, 38, 56, 44, -24, -14, 6, -100, -49, 56, 7, -40,
-5, -59, -42, -43, -78, -83, -93, -60, -57, -53, 4, -6, -90, -88, -32, -3,
4, 52, -3, -66, -12, 36, -9, 69, -13, -104, -69, 15, 81, 15, -26, 16,
71, 67, 71, 60, 51, -7, -51, 28, 65, 65, 69, 58, 56, 23, 21, -11,
5, 28, -15, 19, 26, 37, 51, 54, 56, -26, -3, 12, -63, -89, 55, -1,
-43, 4, -37, -67, -44, -70, -88, -99, -73, -48, -57, 2, -4, -74, -98, -29,
-9, 6, 48, 29, -44, -10, 32, -10, 48, 53, -76, -70, 21, 86, 47, -10,
12, 62, 74, 71, 64, 53, -11, -47, 32, 73, 55, 70, 58, 50, 30, 24,
5, 9, 30, -14, -3, 28, 31, 42, 61, 54, -9, -14, 18, -60, -84, 20,
45, -47, 4, -35, -67, -43, -59, -78, -94, -71, -50, -71, -33, 13, -64, -93,
-59, -19, -11, 51, 32, -45, -53, 23, 7, 51, 56, -76, -105, -33, 63, 47,
-15, -11, 46, 73, 69, 55, 47, 31, -36, -7, 61, 46, 70, 62, 56, 25,
21, 8, -12, 29, 18, -1, 26, 34, 36, 46, 70, -13, -17, 21, -22, -95,
18, 45, -46, -24, -8, -64, -40, -55, -78, -89, -83, -53, -76, -35, 15, -30,
-86, -65, -24, -6, 33, 49, -4, -50, 24, 14, 12, 78, -6, -104, -28, 70,
75, 5, -12, 49, 74, 59, 60, 52, 28, -37, -2, 61, 46, 62, 59, 57,
35, 13, 22, -12, 31, 17, -12, 16, 37, 35, 35, 62, 19, -25, 14, -19,
-94, -44, 52, -3, -22, -6, -62, -57, -40, -66, -88, -85, -56, -56, -66, -11,
-27, -88, -82, -39, -13, 33, 42, 0, -58, -22, 37, 14, 73, 3, -104, -78,
27, 77, 6, -30, 14, 73, 60, 68, 47, 39, 1, -30, 61, 55, 67, 68,
58, 42, 16, 20, -19, 14, 44, -16, 9, 35, 34, 25, 60, 8, -27, 25,
14, -68, -36, 48, -8, -40, 3, -38, -57, -40, -68, -81, -83, -81, -50, -66,
-16, 12, -63, -84, -34, -7, 16, 35, 24, -64, -31, 35, 4, 47, 60, -108,
-76, 24, 81, 40, -29, 17, 81, 62, 53, 60, 40, 4, -27, 35, 63, 58,
68, 61, 48, 16, 27, -20, 14, 47, -11, -9, 35, 32, 20, 56, 42, -23,
3, 14, -70, -83, 17, 33, -36, 2, -34, -67, -45, -51, -83, -86, -83, -55,
-69, -51, 11, -68, -93, -56, -20, 8, 30, 29, -35, -64, 12, -1, 46, 56,
-65, -104, -37, 83, 36, -24, -12, 52, 62, 59, 69, 47, 24, -23, 36, 72,
68, 75, 62, 65, 16, 20, 1, -14, 41, -15, -7, 39, 39, 15, 33, 39,
-25, 8, 39, -23, -89, 13, 31, -39, -9, -3, -68, -39, -59, -86, -81, -87,
-57, -73, -42, 22, -32, -95, -56, -16, 2, 17, 34, -31, -64, 10, 18, 10,
69, -67, -102, -29, 71, 69, -25, -10, 46, 74, 61, 79, 44, 17, -22, 0,
75, 79, 68, 66, 64, 30, 10, 2, -8, 34, 13, -13, 21, 33, 8, 28,
66, 0, -25, 46, -17, -93, -52, 38, -33, -6, -2, -68, -61, -45, -81, -80,
-89, -65, -62, -71, 19, -37, -99, -79, -24, -1, 16, 36, 1, -68, -32, 25,
14, 67, -5, -97, -65, 71, 62, -2, -21, 11, 76, 55, 76, 69, 31, -5,
-1, 71, 74, 69, 68, 62, 29, 10, 17, -14, 17, 21, -21, 11, 36, 22,
13, 64, -4, -22, 38, 14, -68, -41, 43, -10, -39, 13, -67, -59, -42, -76,
-81, -90, -64, -67, -71, 5, -4, -80, -76, -26, -4, 3, 23, -1, -63, -31,
38, 12, 47, -4, -100, -63, 35, 83, -4, -33, 6, 72, 67, 62, 65, 31,
-6, -23, 36, 70, 71, 63, 60, 58, 16, 18, -16, 13, 45, -11, -12, 45,
27, 15, 54, 29, -29, 38, 19, -60, -82, 6, -13, -30, 19, -28, -72, -43,
-75, -89, -93, -73, -55, -86, 10, 1, -81, -96, -53, -8, 3, 18, 13, -30,
-59, 33, 15, 51, 53, -64, -95, 34, 83, 34, -19, -19, 69, 65, 63, 80,
50, 13, -27, 27, 66, 73, 75, 54, 56, 23, 21, 1, -16, 38, -15, -2,
42, 37, 9, 52, 31, -27, 11, 37, -22, -77, 3, 16, -37, 10, -28, -75,
-36, -55, -95, -92, -70, -56, -81, -34, 13, -41, -98, -53, -10, -9, 10, 11,
-33, -58, 12, 35, 28, 51, -67, -98, -9, 78, 66, -14, -26, 40, 77, 56,
84, 49, 11, -27, -3, 65, 66, 68, 61, 63, 38, 26, 0, -25, 35, 17,
-21, 40, 35, 4, 29, 60, -12, 13, 46, -27, -88, -34, 12, -41, 12, 15,
-67, -55, -53, -92, -91, -84, -62, -76, -28, 7, -49, -97, -81, -8, -8, 13,
16, -13, -54, 7, 32, 31, 73, -7, -106, -6, 79, 71, 8, -37, 46, 72,
48, 77, 73, 32, -27, -4, 61, 73, 70, 66, 60, 39, 18, 16, -15, 33,
18, -13, 24, 46, 21, 31, 58, -13, -19, 51, 17, -91, -27, 27, -24, -21,
6, -63, -57, -41, -77, -94, -84, -67, -80, -53, 2, -31, -91, -75, -18, -6,
0, 14, -16, -54, -33, 28, 26, 70, -15, -110, -60, 49, 83, 8, -28, 6,
68, 62, 78, 73, 33, -7, -22, 29, 77, 70, 58, 51, 54, 28, 15, -13,
5, 34, -2, 25, 51, 32, 14, 53, 30, -17, 52, 13, -78, -63, 27, -28,
-31, 14, -26, -72, -40, -74, -94, -91, -81, -79, -50, 1, -27, -79, -93, -17,
-6, 2, 19, -2, -37, -28, 26, 29, 65, 46, -70, -57, 50, 82, 37, -10,
5, 71, 63, 56, 77, 56, -11, -21, 27, 66, 72, 67, 50, 52, 26, 25,
6, 5, 35, -11, 1, 47, 43, 10, 55, 28, -38, 24, 58, -82, -60, 21,
3, -41, 17, -27, -78, -43, -47, -94, -92, -79, -80, -76, -21, -4, -78, -92,
-35, -1, -5, 23, -5, -32, -42, 6, 36, 67, 45, -68, -97, 0, 79, 38,
-5, -19, 45, 72, 59, 77, 51, 6, -34, -3, 68, 72, 67, 49, 55, 34,
28, 14, -15, 24, 10, -2, 38, 45, 12, 27, 50, -36, 33, 48, -42, -78,
-17, 6, -43, -6, 15, -55, -50, -51, -94, -104, -85, -74, -77, -14, -3, -53,
-97, -31, 6, 1, 23, 8, -15, -42, -1, 38, 60, 74, -18, -106, -1, 83,
56, 8, -15, 50, 74, 52, 73, 71, 2, -36, -5, 49, 65, 76, 54, 56,
37, 22, 25, -7, 31, 9, -14, 17, 46, 9, 32, 49, -36, -11, 63, -44,
-81, -24, 16, -30, -6, 21, -45, -69, -43, -66, -100, -84, -73, -86, -47, 6,
-54, -99, -66, -11, -6, 21, 0, -15, -39, -27, 27, 57, 74, -22, -111, -57,
55, 56, 0, -24, 22, 76, 53, 76, 67, 26, -22, -30, 56, 68, 71, 65,
58, 45, 26, 35, -5, 17, 30, -20, 18, 53, 25, 3, 59, -34, -9, 57,
1, -72, -64, 19, -22, -28, 15, -17, -74, -43, -56, -93, -92, -69, -88, -45,
4, -19, -80, -94, -15, -10, 12, 5, -13, -34, -34, 27, 52, 72, 32, -112,
-54, 56, 82, 30, -28, 33, 76, 49, 67, 81, 24, -26, -31, 38, 71, 68,
67, 53, 33, 21, 44, -5, 23, 33, -21, -13, 40, 28, 12, 60, -5, -51,
37, 8, -71, -62, 10, 0, -28, 19, -11, -69, -63, -51, -89, -84, -67, -84,
-74, -11, -23, -88, -97, -33, -7, 5, 1, -9, -15, -43, -4, 61, 79, 33,
-77, -93, 14, 79, 21, -20, 0, 67, 47, 62, 74, 47, 12, -37, 29, 71,
66, 69, 65, 48, 13, 47, 19, -6, 48, -15, -18, 48, 51, -4, 32, -3,
-39, 38, 39, -45, -87, 15, -6, -44, 4, 19, -72, -56, -52, -79, -80, -76,
-86, -67, -10, -6, -61, -99, -42, -8, 1, 3, -6, -13, -53, -9, 58, 76,
58, -74, -85, 21, 92, 40, -18, 7, 71, 61, 48, 80, 46, 8, -35, -14,
59, 78, 58, 61, 50, 4, 17, 21, -3, 51, 17, -36, 11, 51, -1, 38,
38, -44, 1, 39, -50, -84, -16, 13, -46, 6, 29, -42, -68, -49, -84, -72,
-74, -90, -86, -31, -9, -64, -94, -66, -19, 6, 3, -9, 3, -38, -46, 60,
71, 58, -33, -106, -33, 90, 27, -24, -17, 44, 73, 52, 73, 63, 32, -10,
-10, 57, 78, 63, 58, 64, -5, 22, 48, -14, 25, 7, -42, 19, 69, 22,
9, 41, -42, 3, 62, -3, -82, -12, 15, -33, -28, 33, -43, -75, -41, -72,
-90, -71, -90, -87, -27, 6, -33, -83, -71, -17, 7, 4, -18, 3, -43, -45,
37, 67, 67, -38, -106, -29, 82, 66, 4, -15, 36, 77, 60, 70, 63, 31,
-19, -38, 32, 81, 57, 58, 70, 21, -5, 56, -15, 26, 50, -34, -27, 68,
23, 12, 54, -5, -34, 60, -4, -90, -48, 22, -34, -31, 30, 7, -73, -58,
-77, -88, -67, -82, -99, -62, 9, -35, -88, -94, -39, 7, -4, -11, 8, -21,
-68, 46, 76, 71, 14, -80, -77, 76, 66, 8, -16, 7, 72, 55, 67, 73,
46, 6, -33, 36, 77, 61, 58, 75, 20, -1, 54, 19, -3, 51, -31, -25,
50, 46, 9, 52, -9, -32, 42, 38, -65, -45, 24, -13, -48, 6, 2, -80,
-57, -53, -85, -74, -85, -93, -61, 0, -10, -67, -90, -42, -4, 3, -7, 8,
-21, -64, 6, 70, 79, 15, -86, -78, 39, 84, 29, -23, -6, 58, 64, 55,
70, 40, -4, -47, -2, 65, 65, 63, 67, 39, -7, 34, 16, 1, 55, 5,
-38, 48, 40, 15, 52, 22, -42, 51, 30, -73, -83, 1, 9, -49, 8, 37,
-58, -81, -50, -88, -66, -68, -86, -80, 0, 0, -62, -95, -61, -4, -3, -3,
7, 4, -59, -1, 69, 81, 53, -50, -112, 36, 76, 23, -12, -23, 66, 62,
51, 76, 58, 27, -45, -2, 68, 70, 61, 66, 40, -3, 33, 41, -7, 61,
9, -37, 13, 55, 25, 51, 25, -34, 13, 48, -21, -73, 5, 18, -35, -33,
42, -53, -73, -22, -67, -78, -73, -86, -82, -37, 8, -27, -102, -69, -14, -1,
-7, 2, 12, -52, -48, 42, 77, 46, -54, -109, -26, 73, 50, -13, -20, 34,
79, 51, 78, 62, 20, -36, -35, 43, 70, 66, 66, 51, 10, 5, 39, 5,
40, 34, -21, 21, 47, 20, 36, 56, -14, 22, 44, -26, -79, -34, 15, -38,
-29, 38, -5, -88, -25, -68, -79, -67, -81, -88, -40, 11, -30, -100, -100, -36,
2, -6, -7, 15, -23, -45, 51, 79, 67, -3, -94, -32, 75, 54, -11, -28,
41, 82, 58, 72, 73, 40, -38, -29, 53, 79, 71, 70, 45, 11, 9, 44,
23, 39, 36, -19, -12, 36, 34, 39, 51, -20, -12, 51, 14, -83, -28, 17,
-18, -44, 35, -2, -78, -38, -40, -80, -71, -78, -84, -72, -9, 1, -89, -93,
-38, -5, -5, -7, 12, -24, -75, -3, 73, 70, -7, -93, -79, 32, 82, -8,
-28, 5, 76, 70, 72, 73, 37, -18, -52, 15, 79, 65, 58, 55, 36, 6,
41, 20, 19, 46, 10, -8, 35, 31, 22, 58, 18, -6, 46, 1, -73, -52,
11, -30, -44, 14, 33, -57, -27, -40, -82, -70, -85, -91, -68, -7, -6, -66,
-97, -61, -8, -5, -6, 1, 5, -81, -1, 74, 74, 35, -57, -87, 32, 81,
10, -29, -18, 76, 64, 55, 76, 52, -23, -51, 19, 73, 72, 61, 47, 39,
17, 37, 33, 19, 44, 9, -8, 20, 37, 26, 54, 11, -20, 37, 32, -76,
-48, 17, -3, -45, 17, 38, -50, -49, -18, -76, -61, -77, -89, -87, -35, 12,
-70, -92, -53, -11, -5, 1, 6, 11, -61, -53, 50, 80, 44, -57, -112, -32,
78, 10, -24, -11, 46, 80, 63, 76, 53, 8, -46, -17, 73, 69, 60, 51,
46, 19, 31, 25, 1, 39, 32, -3, 25, 27, 17, 48, 45, -19, 36, 29,
-51, -79, -16, -13, -40, -12, 30, -16, -47, -24, -79, -76, -68, -80, -83, -33,
9, -42, -93, -84, -14, -6, 1, -3, 13, -61, -54, 44, 80, 70, -11, -110,
-31, 81, 49, -29, -21, 49, 74, 59, 72, 71, 2, -50, -15, 60, 84, 68,
49, 50, 20, 19, 35, 5, 40, 31, -2, 10, 22, 17, 49, 44, -16, 8,
46, -48, -66, -9, 0, -34, -3, 28, -21, -62, -17, -47, -72, -63, -77, -87,
-63, 7, -48, -94, -75, -33, -21, 2, 2, 14, -24, -83, -10, 88, 69, -21,
-100, -80, 35, 42, -36, -16, 26, 67, 54, 70, 75, 29, -37, -45, 60, 79,
65, 47, 50, 37, 27, 36, 1, 21, 48, -3, 13, 22, 12, 28, 56, -19,
4, 49, -9, -74, -37, -1, -33, -23, 12, 9, -50, -16, -47, -78, -67, -77,
-84, -62, 8, -1, -78, -96, -28, -20, -1, 7, -2, -30, -81, -10, 72, 85,
30, -103, -80, 33, 80, -7, -36, 27, 71, 69, 56, 82, 31, -35, -38, 29,
76, 73, 40, 49, 43, 20, 35, 21, 24, 48, 15, 3, 19, 18, 29, 62,
13, -23, 33, -4, -76, -41, 7, -26, -37, 9, 2, -41, -24, -25, -86, -66,
-72, -83, -85, -29, -4, -76, -92, -49, -19, 4, 5, 1, -2, -72, -58, 77,
81, 29, -69, -106, -25, 79, -10, -35, 11, 53, 69, 60, 80, 62, -5, -48,
30, 76, 71, 46, 42, 52, 20, 39, 28, 3, 39, 21, 4, 21, 26, 17,
48, 10, -20, 38, 33, -56, -74, 7, -29, -43, -8, 19, -45, -34, -23, -72,
-72, -65, -85, -87, -34, 13, -37, -91, -52, -25, -6, 12, 6, -6, -74, -56,
46, 93, 65, -71, -102, -28, 79, 43, -33, 4, 48, 67, 52, 69, 65, -4,
-52, -7, 58, 71, 51, 51, 52, 21, 16, 38, 12, 38, 36, 10, 15, 24,
18, 50, 48, -19, -5, 43, -59, -82, -3, -6, -42, -13, 18, -18, -56, -15,
-75, -75, -54, -71, -96, -75, 19, -34, -92, -72, -33, -25, 9, 6, -3, -42,
-75, 44, 90, 57, -36, -98, -79, 82, 49, -36, -25, 23, 72, 51, 63, 78,
35, -39, -12, 54, 71, 65, 48, 46, 22, 21, 34, 5, 18, 41, 14, 15,
37, 28, 24, 48, -15, -7, 54, 12, -84, -20, -7, -31, -21, 11, -14, -64,
-15, -40, -91, -60, -65, -94, -72, 6, 1, -72, -78, -39, -26, -1, 11, -5,
-45, -84, -5, 82, 83, -44, -100, -79, 29, 79, -6, -19, 24, 72, 67, 47,
79, 32, -40, -43, 26, 72, 67, 44, 49, 33, 5, 34, 0, 15, 52, 29,
2, 46, 31, 17, 57, 19, -19, 54, 4, -87, -54, 6, -15, -9, 11, 12,
-55, -45, -33, -91, -65, -52, -80, -95, 16, 1, -80, -89, -49, -31, -1, 6,
-11, -13, -61, -6, 77, 75, 0, -84, -103, 40, 81, -8, -36, -1, 50, 63,
49, 83, 63, -13, -34, 30, 70, 78, 56, 45, 37, 5, 30, 20, 3, 44,
24, 9, 39, 46, 6, 55, 13, -19, 37, 50, -42, -48, 6, -20, -17, 0,
18, -49, -46, -10, -69, -78, -56, -85, -90, -19, 22, -46, -91, -49, -27, -13,
11, -4, -14, -63, -53, 43, 93, -7, -84, -100, -23, 83, 36, -31, 0, 46,
72, 49, 87, 62, -10, -44, 5, 56, 72, 55, 54, 53, 2, 12, 28, 9,
33, 32, 17, 47, 36, 2, 40, 49, -7, 30, 55, -38, -88, -19, -13, -12,
-3, 16, -13, -64, -9, -65, -68, -50, -83, -99, -10, 18, -56, -101, -72, -34,
-11, 18, -4, -22, -42, -54, 48, 101, 29, -67, -98, -24, 79, 32, -30, -17,
10, 80, 52, 67, 84, 35, -46, -4, 57, 80, 66, 50, 48, -4, 19, 50,
10, 20, 35, 14, 35, 58, 26, 24, 36, 1, 8, 53, 10, -83, -16, -24,
-29, -3, 21, -8, -58, -14, -39, -86, -46, -76, -95, -52, 18, -16, -104, -75,
-39, -20, 13, -7, -21, -38, -83, -15, 96, 20, -72, -99, -73, 41, 66, -30,
-16, 16, 79, 65, 63, 90, 25, -53, -32, 42, 79, 63, 60, 69, 20, -8,
44, 14, 27, 44, 18, 35, 59, 32, 10, 34, 17, 2, 58, 9, -82, -45,
-15, -29, 0, 12, 15, -48, -22, -43, -70, -39, -57, -86, -53, 19, -12, -94,
-91, -41, -25, 6, 11, -18, -24, -76, -6, 93, 58, -46, -89, -68, 49, 58,
-20, -15, 0, 80, 64, 35, 70, 62, -46, -31, 35, 71, 76, 65, 69, 17,
-8, 34, 24, 11, 45, 23, 18, 47, 52, 13, 26, 9, -6, 41, 49, -78,
-38, -16, -42, -18, 6, 9, -53, -30, -19, -72, -36, -58, -86, -71, 1, 17,
-92, -88, -36, -24, -13, 9, -17, -31, -65, -46, 58, 48, -61, -91, -101, -8,
81, -20, -5, 1, 56, 77, 38, 69, 55, -21, -52, 14, 73, 75, 63, 70,
44, -11, 28, 27, 23, 41, 35, 26, 53, 50, 23, 26, 18, -7, 46, 55,
-40, -66, -23, -40, -17, 14, 29, -30, -29, -26, -69, -41, -39, -77, -68, 8,
12, -76, -100, -49, -32, -13, 9, -10, -22, -69, -41, 65, 76, -39, -85, -91,
15, 87, -6, -20, -5, 50, 76, 35, 49, 75, -32, -57, 20, 70, 82, 70,
66, 40, -6, 13, 32, 22, 49, 46, 25, 42, 58, 19, 22, 14, -4, 26,
68, -56, -70, -21, -35, -28, 0, 22, -34, -44, -9, -53, -38, -41, -77, -80,
-21, 25, -87, -95, -40, -38, -31, 12, -22, -27, -63, -69, 25, 67, -42, -82,
-93, -47, 82, -10, -4, 1, 10, 82, 34, 51, 82, 9, -68, -12, 69, 80,
68, 65, 64, 12, 13, 22, 17, 36, 50, 25, 47, 62, 28, 20, 22, -5,
31, 61, -16, -72, -32, -44, -18, 8, 24, -4, -47, -10, -48, -56, -29, -55,
-79, -14, 22, -43, -96, -67, -48, -25, 13, -12, -22, -62, -57, 37, 88, 9,
-70, -97, -42, 82, 34, -8, 17, 14, 81, 49, 26, 77, 2, -66, -1, 53,
69, 73, 64, 69, 12, -4, 23, 11, 29, 53, 43, 37, 53, 25, 22, 22,
-2, 7, 56, -21, -65, -29, -42, -40, -5, 26, -5, -55, -18, -24, -61, -30,
-54, -87, -42, 25, -59, -94, -59, -47, -40, 12, -15, -32, -46, -68, -12, 91,
1, -81, -84, -80, 32, 24, -14, 9, -7, 59, 76, 19, 75, 49, -56, -44,
61, 75, 71, 53, 67, 42, -1, 23, 11, 15, 47, 31, 29, 57, 43, 22,
26, -1, 7, 49, 20, -58, -37, -38, -41, -7, 19, 19, -55, -11, -29, -70,
-36, -30, -92, -39, 21, -31, -88, -71, -43, -32, 15, 9, -34, -50, -67, -12,
82, 50, -65, -85, -85, 35, 72, -9, 6, -6, 53, 59, 12, 56, 41, -64,
-42, 44, 72, 75, 56, 72, 43, -11, 9, 26, 8, 48, 49, 30, 53, 37,
18, 25, 14, 2, 34, 24, -55, -27, -18, -56, -28, 20, 21, -42, -29, -1,
-72, -33, -29, -82, -74, 3, -40, -82, -65, -44, -36, 0, 11, -43, -47, -61,
-51, 90, 38, -75, -80, -94, -27, 65, -13, 3, -6, 29, 82, 7, 56, 74,
-33, -70, 48, 70, 73, 53, 64, 68, -8, 14, 25, 10, 34, 48, 35, 55,
46, 21, 26, 14, -2, 38, 53, -33, -48, -20, -60, -21, 7, 19, -42, -25,
-9, -63, -50, -20, -88, -66, 13, -11, -69, -70, -44, -30, -1, 15, -38, -42,
-50, -43, 59, 80, -46, -86, -96, -14, 75, 12, 1, -6, 39, 80, 23, 25,
69, -37, -59, 24, 59, 69, 56, 65, 60, 4, 4, 33, 9, 29, 42, 36,
51, 45, 15, 24, 26, -1, 13, 50, -26, -32, -4, -52, -43, 10, 21, -22,
-44, -3, -66, -53, -24, -64, -81, -6, -20, -74, -63, -51, -41, -16, 20, -46,
-67, -41, -42, 66, 69, -57, -94, -96, -60, 81, 8, 4, -4, 7, 83, 8,
33, 83, 12, -59, 21, 62, 65, 55, 58, 70, -3, -1, 23, 10, 24, 35,
41, 57, 51, 23, 16, 31, 2, 16, 58, 8, -42, -7, -59, -41, 2, 8,
-9, -35, -2, -39, -59, -31, -79, -74, 11, 12, -63, -70, -39, -31, -5, 25,
-19, -70, -45, -24, 37, 86, -16, -93, -96, -46, 80, 40, 4, -7, 13, 86,
25, 9, 81, 0, -53, -14, 49, 74, 57, 60, 65, 22, -10, 13, 15, 24,
34, 35, 49, 46, 13, 13, 37, 25, 3, 42, -12, -35, 1, -55, -62, 9,
3, -15, -37, -5, -41, -49, -31, -67, -87, -22, -5, -69, -72, -50, -37, -18,
21, -26, -75, -61, -30, 47, 75, -38, -86, -84, -85, 79, 17, 18, 18, -4,
80, 3, 13, 79, 34, -39, -9, 46, 72, 55, 48, 72, 14, -5, 14, 13,
19, 27, 31, 54, 53, 26, 13, 32, 36, 11, 30, 10, -41, 1, -62, -56,
4, 13, -14, -28, 1, -27, -45, -33, -72, -76, -7, 15, -52, -81, -45, -37,
-10, 22, -5, -62, -55, -20, 29, 86, -2, -90, -89, -73, 61, 49, 8, 18,
8, 80, 36, -7, 80, 24, -47, -19, 30, 54, 49, 56, 79, 35, -10, 4,
20, 21, 22, 24, 48, 41, 21, 15, 13, 40, 23, 36, 4, -39, 7, -33,
-74, 0, 5, -14, -25, -13, -36, -35, -33, -59, -79, -32, 8, -59, -82, -52,
-37, -19, 21, -14, -64, -68, -35, 41, 84, -32, -100, -81, -93, 73, 29, 19,
44, 2, 61, 33, 1, 63, 51, -27, -2, 21, 48, 58, 53, 73, 20, -3,
6, 14, 23, 32, 19, 47, 55, 22, 8, 12, 36, 17, 28, 29, -32, 1,
-57, -70, -5, 0, -17, -10, -21, -44, -33, -18, -68, -74, -14, 9, -43, -70,
-51, -38, 0, 11, -15, -51, -65, -27, 21, 77, 3, -87, -89, -76, 47, 47,
14, 44, 12, 63, 44, 3, 56, 30, -28, -16, 2, 40, 54, 49, 69, 40,
7, 1, 11, 22, 30, 21, 43, 49, 10, -3, -4, 39, 34, 35, 13, -37,
-3, -35, -70, 3, -12, -26, -16, -16, -43, -22, -10, -49, -84, -39, -4, -53,
-56, -46, -46, -7, 1, -28, -58, -69, -34, 40, 71, -36, -96, -80, -88, 49,
33, 27, 55, 25, 46, 27, 6, 65, 48, -17, 1, 6, 45, 62, 41, 59,
39, 10, 4, 1, 9, 30, 24, 44, 51, 23, -3, 4, 44, 26, 40, 28,
-38, 11, -59, -69, 4, -4, -33, -5, -30, -48, -16, -3, -64, -72, -18, -6,
-47, -47, -43, -41, 1, 10, -20, -56, -58, -32, 36, 84, -27, -84, -81, -85,
25, 49, 18, 62, 33, 31, 33, 21, 42, 26, -6, -10, -9, 36, 55, 42,
61, 42, 19, 13, 6, 19, 28, 26, 39, 52, 18, -18, -1, 33, 10, 63,
8, -33, 10, -46, -72, 7, -18, -23, -2, -33, -43, -2, -9, -53, -71, -19,
-36, -70, -35, -24, -33, -10, -22, -35, -43, -50, -41, 71, 51, -82, -93, -79,
-92, 26, 22, 31, 67, 51, 33, 33, 33, 34, 13, 2, -2, 2, 51, 43,
29, 57, 35, 39, 12, -13, 10, 26, 28, 52, 54, 24, -18, 7, 31, 22,
56, 32, -17, 0, -71, -49, 16, -8, -23, -8, -44, -42, -12, -11, -57, -48,
0, -20, -69, -44, -12, -28, -21, -15, -18, -40, -59, -4, 76, 37, -83, -86,
-89, -77, -8, 17, 15, 77, 40, 17, 45, 46, 24, 5, 24, 7, -11, 35,
35, 42, 54, 45, 43, 11, 2, 31, 28, 21, 39, 56, 15, -33, 3, 32,
9, 54, 15, 7, 7, -65, -62, 13, -20, -25, -17, -53, -53, -4, -37, -55,
-32, 0, -54, -71, -22, -3, -18, -33, -25, -21, -44, -50, 5, 73, -42, -109,
-68, -76, -83, 23, 7, 25, 88, 54, 14, 61, 30, -4, 21, 38, -14, 7,
36, 28, 35, 44, 53, 47, 5, 1, 39, 35, 32, 54, 42, 7, -25, 9,
-4, 22, 78, 42, 13, -30, -81, -24, 16, -17, -12, -32, -59, -24, 1, -28,
-31, -6, -18, -41, -62, -40, 0, -37, -48, -33, -22, -39, -13, 66, 33, -79,
-97, -30, -88, -53, 35, 9, 22, 67, 11, 20, 60, 26, -27, 44, 30, -22,
2, 27, 32, 33, 42, 66, 53, 17, 9, 33, 32, 23, 39, 43, 3, -1,
-2, -9, 30, 63, 18, 11, -13, -54, -22, -14, -8, -6, -38, -33, -19, -23,
-28, -22, -16, -23, -46, -49, -25, -18, -18, -27, -39, -20, -42, 4, 73, -4,
-100, -20, -21, -103, -36, 25, 1, 56, 70, 35, 18, 57, -1, -20, 27, 17,
-6, 19, 32, 43, 36, 29, 68, 52, 13, 6, 43, 36, 23, 44, 8, 9,
21, -30, 16, 61, 54, 24, 2, -24, -36, -27, -22, 3, -8, -49, -7, -24,
-37, -19, -22, -25, -27, -33, -52, -51, -12, -14, -43, -41, -18, 2, 54, -10,
-99, -60, 12, -97, -41, 21, -16, 23, 48, 56, 47, 31, 54, 8, -20, 11,
14, 13, 2, 29, 39, 35, 53, 54, 44, 24, 27, 35, 18, 38, 33, 4,
33, -15, -33, 19, 45, 45, 19, -9, -6, -22, -47, -13, -6, -33, -20, -19,
-58, -11, -17, -39, -32, -27, -21, -54, -42, 0, -17, -43, -38, 19, 45, -5,
-63, -92, 0, -50, -86, 5, 15, 13, 30, 30, 57, 34, 23, 37, -14, -17,
17, 39, 15, 0, 44, 43, 34, 50, 46, 27, 21, 43, 34, 23, 37, 11,
14, 20, -10, -9, 16, 24, 42, 24, -12, 18, -24, -53, -25, -18, -21, -14,
-49, -38, -7, -23, -40, -35, -11, -22, -66, -40, -3, -43, -51, -11, 27, 7,
-76, -88, -29, -38, -91, -6, 7, 19, 15, 1, 42, 30, 20, 46, 27, -19,
-8, 54, 28, -12, 4, 41, 38, 46, 48, 30, 27, 43, 35, 35, 35, 34,
26, 4, 7, 0, -1, 5, 16, 42, 10, 6, 27, -14, -48, -24, -7, 1,
-28, -40, -25, -25, -26, -29, -28, -12, -44, -55, -18, -17, -39, -27, -1, -10,
-42, -71, -45, -31, -68, -18, -11, -7, 25, 7, 38, 48, 12, 13, 41, 2,
-20, 28, 51, 17, -5, 10, 38, 45, 46, 45, 24, 37, 38, 31, 37, 28,
17, 6, 5, 12, -1, -5, 5, 19, 35, 19, 19, 18, -34, -48, -31, -19,
-15, -16, -28, -40, -29, -14, -37, -25, -5, -39, -50, -10, -24, -25, -16, -21,
-24, -45, -38, -30, -52, -35, -5, -10, 13, 21, 14, 30, 36, 7, 25, 37,
11, 7, 27, 23, 12, -3, 3, 35, 52, 39, 30, 32, 42, 46, 36, 35,
26, 8, 3, 16, 3, -10, -10, -11, 11, 28, 19, 28, 7, -33, -42, -35,
-15, -2, -20, -39, -37, -16, -13, -35, -34, -14, -54, -31, 1, -25, -32, -12,
-30, -31, -34, -42, -36, -31, -9, 6, -1, 7, 19, 19, 42, 25, -2, 19,
36, 9, 11, 26, 25, 23, 21, 6, 48, 55, 21, 28, 31, 31, 39, 34,
30, 20, 2, 8, 16, 1, -16, -11, -2, 17, 26, 20, 21, -19, -36, -36,
-41, -17, 6, -41, -32, -8, -11, -14, -23, -32, -28, -37, -28, -12, -27, -21,
-25, -36, -25, -30, -38, -20, -16, 1, 14, -1, 14, 18, 15, 24, 20, 8,
24, 33, 18, 7, 17, 24, 21, 15, 9, 36, 32, 16, 42, 45, 28, 34,
39, 21, 15, 3, -3, 12, -12, -19, -12, -3, 23, 24, 17, 9, -16, -28,
-41, -32, 0, -11, -42, -35, -10, -23, -28, -31, -38, -33, -23, -16, -22, -27,
-23, -36, -33, -25, -26, -22, -18, -1, 3, 5, 16, 19, 22, 12, 12, 17,
13, 19, 28, 12, 5, 18, 33, 32, 19, 14, 33, 33, 23, 40, 38, 19,
35, 42, 26, 16, -12, -8, 4, -7, -9, -2, 6, 20, 18, 12, 3, -16,
-33, -39, -19, -6, -10, -32, -25, -14, -26, -31, -31, -46, -36, -24, -13, -15,
-16, -30, -47, -33, -19, -14, -12, 4, 9, -5, 4, 20, 19, 22, 14, 11,
19, 20, 16, 17, 13, 5, 18, 43, 32, 14, 10, 14, 25, 37, 43, 34,
18, 25, 31, 24, 9, -14, -11, -1, -9, -6, -8, 1, 14, 5, 5, 1,
-11, -33, -34, -14, -4, -6, -27, -22, -18, -31, -21, -39, -48, -32, -16, -10,
-18, -20, -26, -38, -23, -9, -11, -11, 4, 10, 7, 21, 23, 16, 17, 9,
17, 27, 17, 4, 13, 12, 4, 23, 43, 34, 15, 12, 10, 25, 37, 36,
31, 24, 24, 26, 22, 0, -23, -11, -5, 0, -1, -10, 2, 7, 5, -1,
-10, -18, -26, -22, -13, -7, -11, -17, -15, -35, -32, -23, -43, -39, -25, -14,
-7, -11, -29, -31, -22, -16, -10, -9, 3, 7, 9, 16, 13, 12, 16, 7,
11, 23, 26, 8, 1, 13, 16, 9, 22, 34, 23, 20, 20, 14, 17, 25,
34, 42, 30, 17, 19, 14, -10, -16, -6, -6, 0, -7, -17, -8, 4, 0,
-11, -13, -6, -15, -24, -14, -18, -19, -9, -16, -43, -34, -29, -40, -32, -23,
-21, -19, -20, -22, -21, -13, -13, -13, 6, 12, 6, 13, 5, 8, 23, 19,
8, 21, 22, 19, 12, 7, 14, 10, 17, 30, 30, 29, 27, 14, 9, 17,
23, 31, 34, 16, 8, 12, 11, -7, -18, -10, -11, -1, 2, -18, -15, -2,
-4, -7, -6, -13, -24, -17, -15, -18, -8, -11, -27, -46, -39, -19, -25, -32,
-27, -24, -16, -7, -14, -11, -4, -9, -7, 2, 1, 8, 15, 8, 9, 20,
17, 7, 12, 17, 14, 16, 6, 5, 14, 19, 22, 28, 28, 18, 11, 13,
14, 30, 34, 23, 18, 9, 6, 9, -8, -14, -9, -7, 4, -4, -23, -22,
-6, -7, 0, 4, -13, -22, -17, -19, -17, -15, -16, -26, -50, -34, -14, -23,
-32, -29, -16, -10, -9, -8, -7, -3, 6, 5, 2, 7, 12, 13, 10, 8,
19, 23, 13, 26, 20, 15, 19, 4, 6, 20, 16, 23, 21, 18, 24, 15,
10, 14, 17, 19, 24, 17, 6, -1, -4, -4, -13, -16, -6, -4, -6, -13,
-22, -18, -12, -7, -7, -18, -16, -12, -21, -28, -20, -14, -34, -43, -36, -20,
-14, -36, -16, -7, -13, 0, 4, 0, 5, 0, -5, 6, 17, 22, 26, 11,
10, 21, 19, 20, 14, 19, 28, 4, 5, 16, 12, 17, 21, 6, 23, 20,
6, 13, 14, 6, 13, 11, 14, 9, -8, -1, -2, -14, -20, -18, -13, -2,
-16, -31, -16, -10, -4, -6, -15, -12, -10, -29, -23, -3, -11, -23, -30, -29,
-6, -18, -32, -17, -17, -3, 14, 6, 0, 2, 3, 4, 0, 1, 15, 17,
6, 19, 24, 22, 21, 6, 19, 18, 0, 10, 17, 18, 26, 10, 7, 21,
13, 23, 21, 3, 14, 14, 4, 19, 10, -7, 0, -4, -18, -12, -23, -18,
-5, -21, -23, -14, -16, -10, -9, -11, -7, -21, -30, -24, -20, -18, -25, -34,
-29, -20, -21, -8, -13, -14, 0, 0, 13, 4, -7, 12, 9, -5, 25, 19,
10, 17, 11, 17, 36, 13, 11, 18, 9, 18, 22, 12, 21, 23, 7, 23,
13, 12, 21, 11, 3, 11, -5, -3, 18, 10, -4, -10, -21, -21, -28, -30,
-11, -11, -15, -24, -31, -19, -18, -16, -6, -15, -23, -16, -20, -18, -13, -23,
-29, -20, -17, 0, 0, -17, -8, 12, 13, 20, 12, 1, 16, -1, -3, 12,
20, 23, 6, 19, 27, 16, 10, 14, 12, 13, 15, 10, 13, 12, 15, 16,
3, 6, 17, 10, 2, -3, -2, -6, -1, 15, 6, -8, -6, -8, -26, -21,
-15, -16, -10, -7, -20, -23, -15, -9, -13, -4, -15, -30, -19, -15, -17, -2,
-27, -21, -12, -19, 4, -3, -14, -3, 1, 2, 20, 8, -2, 5, -2, -4,
14, 11, 7, 8, 12, 21, 14, -1, 17, 16, 8, 20, 9, 14, 10, 14,
23, 5, 12, 18, 12, 9, 6, -11, 4, 11, 2, 17, -5, -20, -8, -22,
-30, -11, -22, -10, 0, -31, -38, -15, -21, -15, -11, -16, -17, -25, -18, -9,
-19, -26, -15, -19, -1, 4, -12, -4, -9, 0, 19, 7, 15, 24, -4, -2,
7, 14, 17, 15, 18, 26, 25, 18, 25, 15, 13, 22, 5, 13, 25, 15,
19, 14, 0, 4, 15, -4, 5, 0, -8, 2, -1, -8, 8, -1, -23, -13,
-35, -26, -16, -34, -16, -10, -32, -29, -27, -6, -3, -15, -9, -16, -21, -13,
-5, -14, -8, -8, -4, 12, 6, 8, 6, -12, 0, 22, 24, 20, 9, -1,
0, 1, 15, 21, 0, 4, 24, 19, 16, 17, 12, 15, 17, 6, 12, 4,
2, 18, 14, -7, -5, -3, -1, -6, -13, 0, -7, -11, 4, 13, -3, -9,
-18, -23, -12, -12, -10, -8, -17, -18, -22, -17, -9, -7, -10, -14, -9, -14,
-12, -10, -9, -10, -4, 0, -1, 6, -7, -8, -3, 3, 16, 12, 15, 11,
-8, -3, 0, -2, 13, 12, 7, 22, 5, 7, 26, 24, 19, 21, 16, 10,
14, 19, 13, 12, 12, 5, 3, 1, -7, -5, -5, -5, 4, 6, 2, -5,
-15, -14, -32, -38, -25, -26, -24, -8, -24, -34, -21, -15, -20, -7, -8, -13,
-10, -8, -3, -14, -14, -31, -13, 21, 2, 14, 2, -5, 14, 19, 19, 16,
15, 14, 15, 6, 11, 21, 14, 14, 17, 10, 21, 20, 15, 23, 8, 7,
12, 3, 15, 13, -3, -7, 1, 5, -10, -23, -15, -9, -5, 8, -2, 11,
3, -19, -23, -44, -44, -39, -41, -24, -6, -10, -24, -13, -3, 2, 4, -5,
3, 4, 0, 4, 5, 2, 4, 12, 24, 15, -6, 4, 9, -8, 9, 13,
-3, 1, 13, -7, -4, 9, 7, 9, 3, 1, 8, 6, 14, 22, 24, 26,
15, 15, 1, -26, -20, -13, -9, -14, -4, 11, -3, -3, -3, -9, 0, 9,
4, 7, -5, -31, -18, -15, -23, -8, 2, -9, -14, -19, -16, -20, -17, 2,
-6, 3, -8, -18, -2, -2, -4, -14, 6, 15, -6, 11, -1, -2, 10, 27,
45, 32, 6, -40, -50, -29, -9, 12, 8, 15, 24, 21, 24, 17, 18, 15,
16, 18, 6, 3, 6, 8, 13, 6, 6, 1, -7, -5, -7, -15, -5, 10,
-3, -12, -7, -29, -27, -15, -20, -30, -30, -24, -12, -11, -19, -13, 9, 3,
16, 45, 26, -42, -76, -62, -33, -36, -12, 29, 14, 23, 38, 12, -8, 8,
10, 28, 35, 18, 5, 5, 3, 19, 36, 21, 3, 3, 5, 13, 18, 31,
16, 1, -4, -13, -9, -5, 8, 12, -6, -17, -18, -15, -11, -7, 1, 24,
21, 42, 53, -20, -74, -90, -57, -53, -50, -15, -12, -10, 8, 2, -8, 2,
9, 1, 31, 13, -9, -4, 3, 14, 22, 19, 4, -5, -3, 3, 9, 21,
17, 6, 18, -23, -22, 12, -3, -9, 27, 14, -8, -17, -1, 12, 24, 47,
53, 27, 34, 66, -28, -70, -82, -64, -40, -39, 2, 10, -3, -1, 12, 1,
4, 16, 11, 21, -5, -31, -21, -11, -13, -6, 14, -14, -36, -21, -21, -19,
23, -4, -2, 23, -38, -28, 23, -9, -5, 36, 24, -17, -9, -2, 12, 38,
52, 30, 12, 36, 76, 24, -72, -87, -67, -29, -31, -1, 32, 4, 10, 45,
40, 12, 23, 30, 29, 18, 4, -1, 2, -1, 6, 22, 16, -50, -34, -2,
-1, 13, 9, -6, 1, -73, -84, 21, -16, -40, 15, 6, -39, -38, -28, 6,
42, 46, 45, 24, 24, 72, 19, -62, -85, -72, -43, -40, -17, 20, 19, 29,
57, 36, -6, 10, 36, 28, 41, 18, -32, -23, 17, 27, 54, 34, -19, -24,
6, 19, 33, 16, 11, 27, -87, -66, 49, 32, -42, 39, 20, -31, -29, -33,
-6, 39, 28, 31, 16, -19, 18, 41, -61, -94, -91, -79, -88, -63, 10, 16,
-14, 14, 52, 5, 17, 35, 18, 43, 17, -33, -20, 7, -4, 59, 68, -23,
-55, 2, 14, 29, 19, 13, 54, -6, -98, 24, 65, -18, -6, 61, -6, -21,
-35, -5, 54, 56, 60, 21, -21, 7, 62, -21, -83, -94, -86, -67, -88, -23,
36, -5, -27, 40, 59, 21, 34, 12, 3, 12, -43, -68, -28, -10, -2, 43,
1, -43, -18, -6, 1, 25, 10, 37, -16, -110, -40, 63, -16, -18, 39, 42,
20, -28, -17, 43, 43, 47, 38, -13, 35, 73, 53, -31, -92, -81, -43, -67,
-74, 15, 6, -13, 42, 77, 44, 34, 30, -8, 6, 11, -54, -30, 14, 0,
39, 58, -16, -23, -15, -10, 38, -2, -19, 6, -100, -84, 35, 43, -51, 0,
23, 17, -6, -67, 28, 63, 42, 53, -5, -16, 63, 63, 17, -66, -102, -60,
-45, -83, -5, 67, -4, 24, 81, 51, 25, 48, 2, -8, 39, -6, -76, -10,
35, 38, 70, 31, -22, -13, -8, 20, 23, -1, 26, -61, -105, -11, 63, -8,
-50, 31, 17, -2, -63, -79, 27, 33, 40, 36, -10, 2, 42, 40, -63, -107,
-87, -83, -97, -58, 34, 18, 0, 51, 62, 14, 22, 35, -18, 35, 15, -67,
-33, 37, 46, 56, 72, 35, -21, -29, -28, 54, 17, -7, 29, -49, -47, 58,
28, -43, -3, 43, 32, -31, -91, -5, 63, 30, 60, 2, -24, 11, 44, -3,
-91, -87, -81, -98, -103, -15, 17, 2, 40, 75, 51, -5, 1, -23, -32, 27,
-44, -66, 0, 19, 24, 48, 57, 5, 0, -30, -19, 59, -41, 30, 16, -101,
-52, 50, -5, -7, 38, 59, 45, -89, -55, 38, 44, 56, 61, -1, 14, 6,
45, 30, -102, -94, -70, -77, -100, -6, 43, 24, 67, 76, 36, -1, -22, -63,
4, 42, -44, -26, 19, 19, 27, 59, 56, -16, -40, -58, 18, 21, -26, 51,
-48, -112, -21, 32, -18, 2, 41, 60, -1, -106, 25, 59, 10, 64, 56, -18,
9, 32, 57, -28, -101, -79, -72, -88, -71, 32, 58, 47, 83, 63, 5, 0,
-16, -26, 44, 18, -65, -37, 33, 32, 47, 67, 46, -6, -84, -21, 48, -30,
-5, 11, -107, -61, 19, 13, -11, 13, 43, 29, -74, -100, 11, 34, 47, 69,
9, -12, -23, 41, 34, -83, -103, -84, -86, -87, -4, 77, 54, 42, 78, 27,
-16, 8, -19, 16, 70, -18, -61, 4, 28, 47, 76, 54, 1, -35, -77, 45,
55, -36, 44, 35, -116, -32, 46, 22, -28, 25, 77, -30, -111, -42, 36, 22,
66, 38, -10, -24, -36, 67, -23, -107, -93, -88, -88, -71, 46, 75, 43, 68,
51, 4, -4, -18, -42, 18, 23, -65, -40, 12, 15, 48, 78, 32, -21, -70,
-82, 81, 4, -26, 63, -14, -106, 11, 68, 1, -23, 56, 74, -67, -82, 7,
46, 35, 57, 25, -19, -61, -8, 76, -85, -99, -88, -93, -85, -57, 69, 44,
39, 73, 60, -2, -8, -25, -15, 46, 28, -83, -29, 18, 29, 50, 63, 15,
-47, -86, -24, 69, -51, 13, 32, -88, -93, 12, 34, -26, 19, 83, 43, -70,
-44, 38, 30, 41, 62, 6, -27, -35, 47, 48, -68, -84, -95, -95, -96, -20,
83, 36, 54, 80, 50, 9, -5, -22, 10, 60, -12, -91, 16, 26, 27, 65,
68, 20, -76, -88, 21, 47, -46, 51, -20, -121, -49, 63, 38, -32, 53, 73,
-22, -97, -42, 32, 28, 59, 51, -3, -62, -22, 77, 13, -93, -83, -87, -94,
-75, 38, 85, 24, 66, 70, 24, 2, 14, -2, 40, 50, -59, -75, 20, 19,
57, 76, 49, 8, -93, -44, 56, -7, -35, 63, -72, -98, 9, 62, -4, -26,
68, 28, -69, -92, -7, 21, 41, 76, 20, -33, -65, 8, 64, -49, -87, -75,
-102, -85, -30, 70, 62, 25, 62, 45, -1, 5, 28, -5, 60, 22, -87, -36,
32, 18, 63, 71, 43, -22, -88, 3, 57, -30, 9, 68, -61, -55, 50, 40,
-23, 0, 66, 6, -87, -60, 29, 33, 67, 64, -13, -48, -67, 0, 35, -81,
-85, -85, -95, -96, 10, 84, 37, 19, 56, 32, -9, 16, 24, 11, 44, -49,
-78, -3, 17, 23, 60, 60, 3, -45, -85, -32, 20, -41, 58, 31, -110, -73,
69, 13, -35, 32, 74, 7, -83, -18, 37, 39, 69, 32, -28, -54, -46, 57,
45, -95, -71, -85, -99, -88, 61, 71, 23, 37, 66, 41, 4, 25, 19, 31,
37, -38, -53, 5, 22, 32, 60, 50, -30, -77, -78, 11, 16, -5, 73, -36,
-107, -22, 57, -25, -23, 64, 63, -41, -61, 16, 29, 47, 87, 33, -51, -43,
4, 68, -9, -86, -78, -83, -94, -59, 63, 50, 23, 63, 62, 13, 6, 41,
19, 36, 15, -73, -62, 26, 35, 51, 80, 52, -57, -83, -55, 39, -2, -16,
49, -80, -91, 12, 46, -15, 20, 80, 27, -74, -60, 28, 33, 63, 67, -15,
-57, -34, 28, 57, -54, -102, -72, -80, -99, -7, 97, 58, 30, 69, 46, -2,
26, 55, 17, 33, -19, -87, -31, 32, 40, 70, 82, 3, -53, -76, -21, 36,
-17, 39, 48, -115, -52, 33, 23, -16, 26, 80, -17, -88, -30, 28, 45, 77,
39, -49, -58, -39, 66, 15, -92, -78, -70, -103, -74, 51, 84, 19, 31, 65,
15, 11, 49, 33, 18, 22, -72, -78, 10, 33, 47, 82, 57, -28, -55, -68,
21, 15, -5, 67, -10, -110, -3, 40, -1, -5, 58, 51, -50, -65, 12, 39,
38, 75, -1, -61, -48, -8, 67, -42, -92, -80, -81, -90, -20, 82, 43, 3,
58, 71, 8, 44, 47, 8, 19, 10, -88, -38, 25, 35, 52, 77, 9, -41,
-50, -67, 13, -11, 18, 57, -65, -105, -11, 30, -17, 25, 74, 37, -58, -26,
28, 34, 57, 72, -40, -44, -27, 29, 64, -41, -87, -68, -71, -90, -20, 72,
6, 29, 77, 49, 23, 46, 17, 17, 20, -32, -76, -6, 37, 46, 58, 73,
-16, -41, -68, -44, 34, -16, 60, 16, -106, -64, 30, 27, -7, 57, 60, -7,
-65, 11, 42, 28, 63, 49, -29, -36, -7, 62, 18, -86, -87, -66, -71, -73,
36, 73, 4, 64, 76, 24, 30, 59, 10, 13, -9, -66, -67, 21, 47, 54,
76, 65, -14, -54, -65, 12, 20, -35, 57, -50, -114, -10, 51, 0, 30, 78,
27, -56, -62, 11, 26, 47, 79, 8, -58, -49, 33, 48, -47, -92, -85, -67,
-89, -23, 83, 40, 8, 84, 45, 13, 51, 42, 13, 21, -33, -79, -48, 16,
58, 65, 77, 36, -32, -56, -39, 33, -20, -9, 63, -49, -70, 50, 36, -29,
22, 69, -15, -77, -28, 35, 19, 61, 50, -34, -59, -28, 36, 0, -75, -88,
-77, -59, -77, 43, 73, -3, 23, 77, 22, 31, 57, 32, 25, 12, -48, -59,
-22, 31, 55, 69, 71, 6, -50, -55, -20, 6, -29, 45, 24, -102, -73, 56,
-5, -14, 53, 62, -60, -66, 24, 32, 9, 62, -3, -64, -48, 8, 58, -50,
-88, -89, -63, -77, -82, 84, 30, 0, 55, 62, 19, 43, 46, 26, 29, -8,
-60, -48, 2, 49, 58, 66, 49, -22, -57, -42, 8, -1, 8, 53, -50, -103,
-6, 24, -27, 17, 76, 42, -57, -18, 52, 18, 34, 60, -15, -55, -18, 46,
34, -61, -97, -76, -58, -87, -13, 81, -1, 31, 72, 43, 3, 33, 32, 27,
24, -33, -65, -23, 35, 63, 59, 70, 44, -43, -56, -20, 18, -21, 8, 10,
-104, -65, 36, 32, -20, 51, 78, -14, -94, -27, 43, 15, 62, 37, -55, -61,
26, 51, -29, -92, -90, -59, -77, -65, 56, 65, 9, 57, 59, 16, 3, 43,
34, 41, -7, -68, -57, -24, 50, 55, 65, 62, 9, -28, -55, 11, 7, -29,
51, 13, -103, 0, 51, -3, -20, 76, 36, -68, -77, 28, 46, 32, 77, 1,
-66, -40, 37, -1, -77, -95, -88, -57, -88, -14, 82, 42, 25, 56, 43, -9,
13, 43, 40, 27, -45, -60, -47, -7, 51, 67, 75, 44, 0, -52, -65, 39,
-31, -3, 54, -64, -57, 56, 36, -35, 10, 73, -22, -98, -26, 64, 19, 27,
48, -51, -58, 3, 34, -63, -95, -98, -75, -56, -81, 58, 61, 11, 37, 65,
46, -1, 24, 34, 49, 20, -60, -51, -31, 22, 62, 64, 66, 34, -15, -65,
-20, 34, -44, 43, 8, -107, -46, 63, -15, -21, 57, 63, -20, -77, 36, 45,
7, 64, 37, -73, -24, 30, -3, -69, -92, -88, -50, -88, -58, 68, 23, 31,
63, 55, 13, 1, 27, 35, 41, -19, -54, -38, -12, 52, 67, 60, 60, 19,
-37, -56, 34, 3, -52, 55, -70, -90, 30, 52, -35, 19, 71, 31, -64, -71,
52, 13, 30, 67, -15, -56, 28, 19, -60, -79, -94, -56, -68, -98, 19, 71,
25, 67, 73, 14, -22, 13, 24, 56, 27, -44, -45, -34, 18, 70, 69, 58,
45, 28, -72, -12, 41, -50, 6, -16, -114, -21, 51, 14, -14, 57, 51, -33,
-88, -17, 50, 15, 54, 37, -58, -46, 44, -47, -82, -85, -97, -48, -98, -36,
62, 45, 33, 63, 43, -18, 7, 29, 23, 55, -15, -46, -24, -21, 16, 66,
67, 55, 40, 3, -70, 31, -12, -31, 51, -38, -70, 33, 36, -8, 5, 62,
3, -83, -57, 24, 35, 26, 55, -22, -79, 7, 34, -89, -80, -100, -72, -52,
-97, 27, 53, 32, 49, 73, 39, -21, 16, 27, 51, 49, -50, -40, -12, 8,
44, 55, 60, 42, 28, -35, -48, 30, -36, 29, 22, -101, -66, 51, 19, -3,
32, 64, -4, -83, 3, 39, 25, 35, 26, -58, -43, 47, -21, -103, -90, -92,
-49, -87, -73, 42, 41, 31, 62, 65, -1, -9, 19, 30, 47, 9, -46, -26,
-6, 27, 51, 56, 58, 36, -6, -57, 6, 19, -5, 46, -58, -102, -3, 42,
7, 17, 59, 47, -66, -88, 34, 33, 37, 48, 19, -63, 19, 29, -79, -92,
-87, -57, -64, -94, 2, 66, 41, 42, 69, 36, -24, -11, 23, 48, 31, -29,
-47, -27, 13, 39, 46, 49, 43, 41, -40, -21, 32, -27, -2, -15, -105, -39,
21, 19, 16, 31, 65, -19, -100, -25, 36, 33, 40, 33, -25, -49, 41, -50,
-97, -83, -79, -50, -99, -31, 53, 50, 46, 58, 51, -7, -13, 5, 23, 53,
1, -33, -34, -9, 28, 22, 48, 51, 27, 10, -44, 37, 2, -36, 37, -37,
-70, 14, 12, 10, 12, 40, 20, -86, -55, 30, 43, 31, 29, 2, -52, 6,
39, -97, -96, -100, -67, -68, -96, 36, 48, 40, 56, 68, 6, -19, -2, 11,
55, 47, -31, -20, -16, 17, 34, 16, 61, 41, 30, -15, -36, 34, -35, 18,
18, -102, -63, 19, 4, 17, 34, 58, 0, -89, -1, 46, 45, 36, 24, -35,
-20, 43, -36, -99, -97, -85, -53, -96, -54, 47, 35, 45, 69, 55, -8, -11,
-6, 30, 68, -4, -47, -12, 6, 36, 11, 17, 56, 42, 18, -41, 6, 20,
-12, 38, -71, -100, 2, 14, 4, 30, 56, 43, -60, -78, 44, 48, 38, 34,
20, -35, 39, 7, -87, -80, -93, -52, -75, -88, 11, 48, 30, 63, 74, 10,
-36, -9, -4, 50, 25, -51, -30, -5, 19, 29, 7, 34, 52, 47, -34, -25,
28, -29, 1, -14, -109, -37, 20, 1, 9, 44, 62, -17, -92, -25, 47, 51,
42, 30, -24, -26, 39, -70, -93, -91, -88, -41, -97, -26, 57, 49, 39, 79,
38, -27, -10, -4, 3, 60, -16, -43, -8, 5, 24, 8, 11, 40, 59, 34,
-53, 14, -8, -29, 31, -46, -70, 7, -1, 2, 29, 61, 24, -88, -72, 10,
45, 47, 41, 8, -29, 38, 19, -97, -78, -97, -55, -61, -96, 41, 60, 39,
61, 82, -15, -27, -7, -6, 40, 49, -31, -13, 4, 22, 32, 5, 23, 51,
54, -14, -33, 14, -33, 28, 1, -100, -49, 4, -5, 18, 40, 66, 11, -83,
-22, 30, 62, 45, 14, -30, 6, 43, -67, -101, -96, -73, -34, -86, -51, 55,
40, 38, 76, 45, -21, -11, -8, 28, 57, 9, -29, -3, 18, 33, 10, -10,
18, 65, 19, -37, 5, -3, 0, 24, -81, -77, 10, 4, 15, 42, 64, 50,
-43, -48, 7, 61, 67, 29, 14, -5, 51, -27, -102, -77, -103, -48, -70, -77,
18, 65, 37, 63, 63, -9, -42, -22, 11, 46, 22, -19, -18, 6, 33, 17,
-8, -3, 34, 42, -21, -8, 11, -40, 10, -43, -100, -3, 13, -15, 24, 45,
65, 6, -65, -38, 38, 74, 38, 11, -5, 12, 10, -93, -84, -88, -89, -43,
-85, -21, 52, 53, 49, 80, 23, -31, -21, -13, 14, 38, -4, -22, 2, 29,
33, 3, -7, 19, 54, 28, -24, 5, -40, -20, 30, -71, -30, 32, -11, 3,
37, 52, 29, -53, -58, -10, 45, 55, 20, -6, 4, 52, -16, -89, -78, -99,
-58, -65, -82, 38, 67, 52, 68, 76, -24, -29, -14, -2, 34, 38, -23, -12,
32, 40, 21, -3, 5, 45, 45, -5, -4, -20, -37, 26, -32, -101, -9, 5,
-9, 21, 45, 73, -34, -68, -26, 20, 62, 45, -10, -18, 38, 16, -84, -79,
-89, -67, -58, -87, -38, 63, 62, 61, 82, 35, -36, -21, -2, 32, 44, 13,
-21, 15, 46, 33, 4, -14, 32, 49, 12, -6, 15, -29, -1, 1, -94, -49,
33, 8, 19, 40, 70, 45, -45, -33, 1, 49, 61, 23, -11, 30, 46, -57,
-86, -76, -100, -57, -82, -61, 12, 59, 57, 73, 56, -19, -43, -29, 19, 43,
14, -16, -10, 31, 50, 14, -18, -4, 38, 32, -4, 11, -10, -49, 3, -70,
-77, 16, 23, 6, 22, 60, 67, -14, -54, -24, 31, 63, 35, -6, -13, 50,
-27, -88, -68, -92, -71, -55, -81, -10, 52, 64, 59, 70, 2, -46, -31, -9,
26, 25, -10, -18, 7, 51, 53, -20, -13, 28, 46, 17, 8, 5, -54, -19,
-4, -92, -10, 34, 17, 25, 31, 69, 20, -42, -25, 0, 38, 58, 10, -29,
29, 60, -53, -75, -86, -85, -48, -73, -39, 35, 61, 58, 74, 60, -39, -42,
-14, 19, 36, 14, -3, 2, 20, 55, 27, -26, 24, 57, 33, -9, 14, -38,
-41, 7, -67, -92, 1, 20, 29, 28, 39, 68, -34, -39, -5, 24, 56, 48,
-25, -8, 63, -13, -94, -74, -89, -54, -67, -83, -17, 66, 54, 67, 78, 17,
-45, -20, 15, 33, 20, -4, 3, 12, 44, 56, -13, -28, 52, 45, -5, 9,
27, -49, 4, -34, -106, -22, 34, 21, 37, 24, 59, 37, -36, -4, 15, 47,
55, 19, -31, 52, 24, -86, -81, -87, -88, -62, -88, -44, 32, 65, 55, 76,
49, -26, -54, -27, 23, 28, 0, -1, 20, 22, 57, 19, -32, 5, 56, 15,
-6, 27, -23, -47, 9, -96, -48, 30, 18, 34, 19, 35, 59, -9, -30, -3,
41, 62, 34, -25, -17, 65, -60, -86, -80, -97, -59, -82, -63, 9, 59, 59,
60, 72, -4, -57, -35, -3, 16, 7, -4, 14, 19, 32, 38, -28, -19, 41,
45, 1, 23, -5, -64, -4, -19, -102, 20, 25, 16, 44, 22, 53, 18, -23,
0, 15, 43, 51, -3, -35, 43, 38, -77, -72, -90, -73, -58, -79, -9, 52,
58, 50, 78, 67, -47, -48, -10, 21, 26, 0, 1, 21, 31, 52, 28, -37,
22, 54, 11, -3, 29, -52, -25, -3, -87, -61, 29, 9, 37, 34, 19, 39,
-19, -16, 6, 35, 58, 39, -41, 13, 59, -51, -96, -79, -79, -42, -65, -64,
8, 72, 49, 65, 81, 15, -47, -22, 8, 28, 12, -13, 0, 30, 46, 36,
-25, -33, 51, 24, -8, 27, 5, -57, 11, -66, -90, 11, 27, 35, 57, 28,
29, 10, -14, 3, 21, 56, 49, -3, -38, 57, -18, -97, -79, -96, -56, -58,
-75, -25, 50, 68, 56, 81, 36, -34, -45, -19, 25, 18, -4, -5, 22, 48,
38, -6, -29, 15, 49, 8, 21, 20, -49, -27, 5, -105, -23, 28, 4, 45,
42, 26, 14, -10, 5, 6, 48, 55, 6, -35, 17, 56, -85, -79, -88, -84,
-46, -76, -50, 30, 78, 49, 54, 61, -9, -51, -40, 7, 22, -6, -5, 8,
34, 48, -1, -33, -4, 44, 35, -3, 25, -21, -40, 6, -55, -97, 25, 6,
22, 68, 45, 21, -6, 2, 16, 23, 58, 20, -33, -6, 59, -16, -94, -85,
-90, -51, -59, -75, 4, 72, 57, 46, 80, 49, -35, -41, 2, 27, -2, -6,
12, 27, 49, 39, -6, -17, 28, 46, 6, -5, 16, -43, -2, -30, -106, -41,
17, 7, 57, 52, 22, 13, 2, 11, 10, 50, 69, 12, -31, 54, 25, -86,
-95, -97, -61, -54, -73, -51, 14, 69, 44, 72, 67, 7, -34, -16, 19, 1,
-11, 5, 24, 45, 48, 3, -32, -3, 48, 21, -10, 16, -14, -40, -4, -93,
-67, 19, 1, 37, 73, 41, 15, -1, 12, 15, 26, 59, 37, -28, -18, 47,
-61, -99, -91, -89, -54, -74, -57, -13, 50, 64, 65, 83, 28, -28, -40, -8,
7, -16, -9, 11, 28, 54, 22, -30, -15, 35, 49, -4, 11, 0, -38, 5,
-19, -95, 1, 13, -9, 42, 51, 25, 0, 7, 22, 11, 54, 51, -13, -43,
42, 33, -99, -88, -95, -55, -45, -62, -30, 32, 72, 50, 66, 52, -10, -42,
-30, 7, 2, -16, 2, 13, 38, 55, -21, -39, 11, 55, 30, -9, 8, -33,
-10, 7, -84, -28, 23, -8, 22, 63, 53, 7, -1, 20, 17, 36, 61, 9,
-51, 14, 61, -61, -90, -93, -70, -43, -66, -48, 2, 57, 67, 61, 73, 41,
-31, -28, 3, 6, -14, -3, 17, 35, 51, 29, -28, -12, 45, 48, -4, 0,
3, -40, 13, -55, -106, -14, -5, 4, 49, 50, 32, 0, 14, 20, 27, 58,
53, 2, -19, 61, -15, -102, -92, -89, -42, -57, -49, -20, 9, 74, 64, 67,
56, 7, -34, -2, 2, -15, -14, -8, 35, 46, 35, -10, -46, -3, 60, 19,
-1, 11, -38, -30, -19, -107, -49, 17, -3, 35, 52, 41, 16, -1, 9, 31,
55, 47, 17, -37, 1, 20, -95, -101, -103, -80, -52, -49, -24, -2, 56, 69,
65, 64, 26, -24, -29, 9, -22, -16, -10, 8, 45, 40, 8, -44, -21, 48,
55, -1, 17, -21, -54, 8, -92, -85, 4, -1, 0, 38, 39, 27, 12, 9,
12, 38, 52, 25, -28, -22, 60, -67, -98, -91, -93, -57, -54, -21, -12, 35,
68, 61, 72, 39, -14, -36, 3, -4, -33, -13, -2, 35, 49, 35, -31, -43,
24, 63, 20, 2, -5, -63, -7, -4, -105, -12, 7, -12, 34, 46, 30, 24,
14, 14, 33, 56, 44, -18, -38, 44, 28, -89, -88, -92, -68, -66, -49, -16,
19, 59, 57, 67, 71, 37, -34, -2, 15, -26, -22, -6, 27, 58, 43, 11,
-40, 0, 64, 36, -7, 17, -16, -40, 9, -84, -99, 3, -22, 11, 43, 26,
29, 22, 15, 26, 53, 55, 28, -25, 19, 53, -58, -98, -93, -73, -66, -57,
-12, -12, 27, 60, 56, 68, 50, -4, -39, 21, -17, -31, -9, -7, 51, 49,
19, -31, -49, 12, 54, 7, 11, 8, -56, 5, -43, -109, -26, 9, -20, 40,
25, 24, 30, 16, 20, 40, 50, 43, -7, -44, 60, -32, -107, -91, -96, -73,
-67, -15, -6, 12, 67, 61, 66, 60, 20, -35, -8, 3, -32, -10, -8, 23,
57, 30, -16, -55, -11, 52, 39, 8, 25, -46, -50, 9, -112, -60, 18, -17,
-3, 42, 16, 34, 28, 18, 24, 41, 52, 11, -42, 10, 51, -93, -91, -105,
-84, -66, -64, 3, -1, 49, 64, 56, 64, 33, -22, -27, 24, -11, -25, -9,
7, 49, 51, 23, -48, -27, 33, 40, 7, 26, -24, -59, 7, -39, -111, 5,
-4, -14, 36, 24, 21, 33, 15, 27, 34, 50, 48, -30, -16, 52, -23, -102,
-98, -100, -68, -69, -22, 2, 33, 66, 56, 69, 63, 29, -28, 20, 12, -40,
-24, 3, 36, 52, 36, -13, -50, 10, 37, 9, 14, 36, -68, -22, -19, -107,
-75, 8, -16, 18, 33, 22, 41, 27, 25, 29, 52, 68, 22, -29, 47, 17,
-88, -92, -102, -74, -71, -44, 3, 1, 40, 59, 66, 67, 42, -8, -2, 31,
-24, -42, -14, 13, 47, 51, 10, -51, -29, 30, 16, 8, 44, -4, -59, -12,
-90, -97, -7, 3, -13, 35, 18, 32, 30, 15, 29, 39, 56, 36, -25, -24,
45, -68, -100, -92, -99, -71, -64, -2, 6, 33, 72, 59, 74, 52, 7, -21,
15, -3, -38, -21, -1, 27, 45, 27, -40, -47, 16, 30, 6, 34, 21, -47,
-33, -25, -105, -37, 5, -6, 24, 34, 22, 34, 24, 28, 30, 45, 50, -3,
-36, 35, 22, -104, -83, -104, -76, -70, -54, 3, 19, 69, 60, 66, 70, 14,
-16, -4, 27, -14, -31, -10, 16, 42, 46, 9, -55, 4, 36, 11, 4, 42,
-23, -44, -15, -77, -92, 6, -5, 13, 32, 16, 28, 24, 22, 25, 41, 62,
15, -41, 10, 50, -63, -104, -100, -82, -63, -63, -8, 0, 61, 70, 63, 72,
43, -9, -17, 27, 8, -37, -29, 6, 36, 48, 25, -46, -51, 39, 22, -3,
28, 35, -57, -14, -52, -107, -36, 1, 10, 29, 14, 24, 28, 20, 24, 28,
50, 56, 11, -10, 58, -24, -103, -91, -98, -67, -68, -10, 5, 11, 66, 60,
74, 50, 19, -11, 18, 25, -28, -35, -12, 18, 42, 39, -23, -65, -1, 40,
4, 20, 48, -15, -56, -27, -101, -61, -1, -8, 24, 15, 19, 29, 11, 22,
28, 41, 55, 28, -33, 7, 8, -98, -92, -97, -86, -71, -37, 3, -1, 50,
68, 65, 64, 31, -4, -14, 27, -7, -30, -15, 10, 36, 50, 0, -68, -29,
36, 24, 11, 43, 8, -47, -20, -45, -83, -8, -8, 12, 44, 10, 30, 19,
23, 37, 32, 56, 44, -14, -16, 52, -23, -97, -89, -96, -76, -79, -27, -4,
34, 72, 59, 70, 42, 2, -20, 13, 26, -13, -21, -6, 27, 52, 47, -18,
-51, 18, 29, 1, 10, 26, -29, -28, -29, -92, -64, -2, -5, 38, 21, 8,
26, 19, 37, 37, 48, 57, 9, -26, 42, 14, -97, -90, -93, -72, -80, -45,
4, -2, 73, 67, 65, 67, 35, -17, -3, 26, -6, -32, -19, 9, 48, 58,
2, -61, -33, 31, 6, 1, 29, 17, -36, -24, -77, -87, -10, -2, 26, 28,
2, 19, 14, 20, 38, 46, 54, 50, -3, 20, 39, -75, -94, -85, -89, -76,
-62, 0, -4, 27, 75, 66, 71, 45, 8, -17, 24, 14, -31, -21, -8, 9,
72, 24, -54, -47, 18, 19, -1, 17, 30, -16, -31, -57, -111, -40, 8, -5,
31, 7, 15, 18, 8, 29, 44, 51, 50, 19, -16, 43, -49, -102, -81, -96,
-72, -78, -16, -4, 10, 72, 68, 65, 58, 24, -13, -5, 29, -22, -22, -4,
-6, 35, 67, -35, -60, -3, 30, 13, 15, 34, 6, -25, -23, -74, -74, -2,
-7, 19, 40, 14, 21, 6, 18, 29, 47, 49, 25, -4, 31, 36, -76, -88,
-95, -84, -72, -53, -8, -8, 58, 76, 68, 66, 35, 1, -15, 19, 12, -33,
-7, -3, 20, 60, 24, -53, -23, 32, 23, 5, 27, 16, -15, -19, -60, -107,
-51, -4, 7, 42, 23, 14, 15, 14, 26, 43, 58, 44, 3, 27, 52, -49,
-105, -89, -85, -75, -67, -9, -14, 2, 75, 68, 69, 49, 31, -14, 4, 21,
-20, -26, -4, 4, 56, 42, -41, -62, 21, 28, 8, 23, 31, -2, -17, -45,
-100, -67, -4, -14, 38, 30, 5, 15, 9, 20, 40, 57, 46, 26, 1, 61,
-8, -104, -92, -95, -78, -74, -28, -6, -14, 49, 70, 65, 54, 39, 12, -2,
27, -13, -25, -1, -11, 12, 59, -16, -66, -35, 25, 12, 13, 32, 1, -15,
-11, -90, -85, -17, -3, 3, 37, 9, 7, 8, 14, 20, 57, 52, 27, 6,
23, 60, -92, -98, -91, -88, -67, -63, -7, -26, 31, 76, 66, 56, 35, 23,
2, 20, 22, -30, 0, -8, -10, 56, 51, -63, -48, 11, 32, 8, 40, 20,
-17, -7, -37, -97, -31, 4, -4, 33, 32, 6, 6, 12, 17, 24, 60, 27,
7, 16, 56, -4, -98, -91, -93, -66, -67, -26, -12, 10, 76, 69, 68, 51,
24, 4, 12, 31, -11, -33, -3, -13, 34, 65, -11, -63, 1, 32, 10, 17,
41, -17, -7, -13, -86, -91, -15, -9, 17, 42, 16, 7, 7, 17, 19, 54,
53, 15, 11, 49, 28, -77, -94, -94, -76, -65, -38, -14, -30, 68, 74, 67,
56, 35, 20, 10, 34, -5, -32, -5, -7, 19, 64, 16, -63, -50, 25, 11,
3, 40, 22, -25, 2, -69, -107, -36, 0, -6, 46, 24, 7, 5, 10, 15,
40, 62, 29, 6, 18, 50, -55, -97, -94, -98, -62, -53, -15, -32, 7, 75,
66, 65, 39, 22, 5, 23, 9, -35, -7, 2, -9, 33, 39, -40, -65, -12,
28, 2, 30, 38, -20, -14, -4, -104, -62, -3, -4, 17, 43, 7, 1, 7,
13, 15, 63, 44, 10, 3, 49, 32, -101, -90, -96, -73, -63, -44, -30, -12,
65, 72, 71, 43, 25, 8, 11, 46, -1, -23, 6, -8, 20, 55, -21, -60,
-28, 19, 24, 4, 43, -3, -27, 11, -53, -110, -14, -2, 10, 36, 22, 4,
2, 13, 14, 37, 63, 20, 1, 33, 57, -51, -107, -89, -86, -64, -54, -21,
-27, 45, 84, 70, 62, 42, 13, 1, 43, 27, -35, -18, -5, 10, 46, 31,
-30, -39, 7, 22, 4, 20, 45, -31, 6, -18, -105, -75, -9, 6, 26, 27,
17, 6, 17, 15, 21, 56, 53, 24, 11, 63, -12, -108, -87, -92, -68, -66,
-35, -29, -21, 78, 67, 64, 48, 28, 9, 32, 49, -22, -33, -2, -7, 46,
42, -12, -49, -34, 22, 7, 7, 44, 1, -34, 4, -81, -94, -34, -8, 13,
28, 16, 10, 9, 20, 12, 52, 63, 32, -3, 19, 25, -86, -87, -88, -88,
-60, -49, -23, -27, 33, 76, 70, 52, 31, 20, 1, 42, 6, -39, -9, -8,
11, 49, 0, -46, -40, -1, 18, 0, 32, 25, -31, -4, -8, -102, -41, -12,
-4, 33, 15, 11, 10, 21, 20, 15, 59, 40, 4, -1, 58, 3, -98, -84,
-93, -62, -65, -28, -24, 12, 69, 74, 68, 41, 29, -3, 26, 61, -8, -15,
-13, -10, 43, 43, -42, -45, -10, 13, 12, 12, 32, -18, -15, 4, -74, -96,
-14, -16, 22, 38, 15, 11, 13, 25, 13, 36, 61, 16, -8, 45, 32, -80,
-88, -97, -70, -64, -61, -21, -8, 54, 78, 75, 62, 43, 9, 11, 54, 15,
-32, -7, -14, 31, 52, 0, -48, -22, 14, 19, 10, 28, 25, -26, 3, -50,
-104, -49, -18, 6, 45, 27, 10, 1, 24, 18, 27, 62, 48, 7, 26, 52,
-52, -97, -84, -95, -61, -76, -25, -10, 1, 76, 77, 72, 51, 34, 8, 37,
42, -23, -17, -2, 7, 60, 20, -43, -49, -15, 23, 10, 19, 27, -13, -17,
-28, -97, -67, -13, -22, 38, 42, 16, 5, 4, 22, 16, 50, 57, 21, -12,
38, -17, -104, -85, -100, -71, -77, -43, -4, -12, 50, 79, 73, 58, 35, 20,
12, 48, -5, -24, -2, -22, 18, 44, -25, -55, -31, 12, 12, 21, 35, -5,
-16, 0, -51, -87, -23, -18, -12, 41, 25, 6, -2, 16, 13, 18, 63, 34,
-5, 15, 53, -39, -86, -91, -85, -60, -73, -5, -19, 29, 77, 69, 71, 39,
30, 11, 34, 42, -24, -5, -12, -4, 56, 36, -63, -40, 9, 16, 9, 30,
7, -21, -2, -28, -97, -75, -12, -26, 25, 47, 20, 2, 10, 15, 16, 48,
56, 8, -2, 57, -5, -96, -75, -92, -58, -74, -40, -5, 3, 78, 75, 66,
51, 36, 20, 24, 51, 0, -30, -10, -19, 37, 55, -13, -62, 3, 19, -5,
23, 40, -7, -9, -18, -84, -96, -24, -19, 0, 45, 27, 7, 10, 15, 11,
39, 51, 37, 1, 48, 30, -84, -86, -90, -65, -71, -55, -4, -31, 17, 82,
72, 55, 33, 37, 22, 54, 22, -29, -6, -11, 16, 62, 13, -57, -46, 16,
0, 9, 43, 8, -25, -6, -64, -107, -46, 3, -27, 38, 43, 13, 9, 12,
6, 27, 54, 49, 12, 0, 58, -61, -88, -83, -88, -57, -77, -6, -23, -3,
74, 74, 67, 39, 40, 32, 30, 53, -23, -16, -3, -18, 29, 36, -42, -64,
-3, 26, -6, 38, 27, -16, -13, -21, -74, -72, -2, -12, -14, 36, 23, 10,
8, 5, 5, 44, 51, 19, -3, 44, 28, -75, -79, -95, -59, -76, -62, -6,
-27, 56, 83, 69, 57, 37, 40, 26, 50, 29, -28, 0, -23, 7, 62, 16,
-68, -24, 27, -1, -5, 44, -4, -20, -14, -58, -101, -12, 1, -19, 14, 32,
25, 11, 9, -5, 27, 65, 43, 5, 33, 46, -57, -82, -93, -72, -63, -83,
-4, -14, 22, 88, 72, 63, 35, 31, 35, 47, 46, -14, -19, -14, -5, 59,
40, -46, -71, 19, 6, -11, 41, 40, -10, -12, -39, -94, -72, -3, -19, 6,
30, 31, 17, 6, -5, 11, 60, 44, 21, 11, 55, -28, -84, -70, -100, -51,
-91, -30, 1, -39, 40, 77, 64, 47, 30, 39, 37, 54, 1, -29, -3, -18,
42, 55, -23, -72, -32, 21, -16, 24, 51, 4, -13, -9, -82, -89, -17, 2,
-16, 24, 33, 23, 5, 3, -9, 55, 50, 29, 14, 32, 47, -84, -64, -97,
-77, -51, -52, 10, -45, 5, 86, 72, 57, 32, 33, 37, 50, 27, -27, -13,
-14, -16, 48, 7, -61, -47, 5, 7, -12, 50, 19, -18, -8, -38, -94, -37,
4, -6, -2, 17, 35, 5, 7, -5, 6, 59, 31, 25, 24, 49, -24, -71,
-82, -88, -49, -84, -28, -36, -22, 73, 79, 67, 49, 30, 31, 48, 62, 16,
-23, -13, -14, 28, 50, -9, -58, -4, 14, -10, 19, 46, -12, -11, -26, -79,
-89, 1, 1, -11, 8, 37, 30, 7, 1, -8, 40, 48, 32, 22, 55, 8,
-85, -64, -95, -54, -76, -50, 8, -48, 56, 83, 67, 56, 34, 32, 34, 68,
40, -22, -21, -14, 12, 49, 14, -57, -52, 16, -11, 3, 49, 19, -18, -13,
-60, -98, -48, 13, -15, -1, 28, 34, 14, 14, -13, 21, 50, 37, 27, 27,
34, -74, -75, -79, -88, -63, -69, 8, -39, -29, 73, 66, 60, 41, 35, 27,
59, 55, -5, -30, -12, -2, 42, 36, -42, -65, -6, 6, -8, 45, 34, -16,
-12, -41, -90, -73, 0, 12, -16, 18, 30, 21, 16, 0, -12, 45, 49, 38,
20, 57, -51, -83, -70, -102, -52, -72, -2, -17, -55, 47, 79, 62, 45, 35,
27, 33, 67, 19, -30, -18, -2, 18, 50, -22, -65, -21, 9, -16, 4, 46,
-8, -16, -11, -55, -87, -22, 20, -9, -8, 17, 22, 13, 3, -8, 12, 43,
51, 24, 40, 36, -66, -71, -99, -69, -66, -69, 7, -58, 18, 79, 62, 55,
37, 33, 27, 54, 74, 9, -21, -3, 3, 46, 37, -39, -35, 4, -9, -9,
37, 34, -18, -5, -35, -87, -82, 18, 8, -9, 9, 23, 23, 4, -6, 1,
31, 52, 46, 33, 50, -41, -80, -81, -82, -54, -85, -6, -17, -58, 73, 70,
58, 34, 34, 30, 34, 76, 37, -32, -18, -1, 31, 50, -15, -59, -16, -10,
-19, 30, 44, -7, -1, -16, -76, -92, -35, 19, -6, 9, 20, 20, 18, 4,
-4, 19, 41, 53, 25, 60, -8, -86, -72, -102, -63, -82, -28, 8, -66, 6,
77, 62, 39, 26, 43, 22, 63, 55, -19, -26, -8, 3, 53, 2, -55, -25,
10, -18, 16, 47, 7, -20, -2, -52, -96, -63, 12, 11, -7, 25, 13, 16,
16, -3, -1, 38, 47, 22, 34, 61, -79, -69, -92, -80, -41, -82, 20, -53,
-31, 68, 70, 63, 19, 47, 33, 17, 70, 2, -30, -10, -2, 35, 48, -48,
-36, 8, -15, -21, 25, 22, -23, -10, -5, -68, -78, -6, 14, 0, 20, 25,
14, 25, 8, -9, 19, 44, 24, 29, 63, -10, -82, -82, -101, -48, -81, -30,
19, -62, 54, 73, 66, 49, 37, 40, 15, 64, 63, -12, -10, -9, 23, 55,
0, -60, 3, -3, -30, 12, 43, -16, -15, -2, -50, -98, -68, 16, 5, 15,
31, 9, 11, 26, -5, 5, 38, 42, 18, 58, 20, -86, -71, -90, -59, -68,
-62, 31, -47, -42, 78, 62, 65, 28, 34, 16, 41, 73, 10, -21, -10, 9,
60, 23, -50, -42, 12, -20, -10, 45, 20, -26, 0, -35, -91, -87, -19, 11,
4, 36, 11, -8, 31, 26, -6, 41, 44, 15, 25, 50, -66, -86, -75, -95,
-46, -71, 20, -12, -62, 46, 74, 63, 32, 25, 31, 12, 70, 31, -20, -8,
-10, 21, 50, -35, -60, 7, 20, -29, 33, 33, -20, -16, -4, -79, -98, -36,
7, -10, 15, 23, -14, 17, 38, -9, 0, 49, 13, 13, 66, 24, -88, -69,
-99, -51, -62, -54, 19, -68, 17, 75, 61, 39, 21, 31, 10, 39, 73, -8,
-2, -8, 3, 63, 34, -68, -13, 26, -15, -14, 37, -4, -23, -9, -30, -86,
-61, 5, -9, 1, 42, 11, 1, 38, 8, -10, 40, 18, 8, 60, 50, -63,
-80, -95, -71, -52, -72, 29, -2, -16, 71, 64, 59, 32, 32, 12, 26, 74,
36, -6, -3, -11, 46, 50, -36, -61, 20, 7, -21, 16, 41, -31, -17, -13,
-70, -98, -42, -2, -6, 37, 28, -10, 13, 22, -12, 25, 41, 6, 43, 68,
-32, -90, -70, -98, -54, -81, 2, 31, -56, 16, 72, 61, 50, 31, 23, 14,
72, 53, -1, 9, -15, 26, 59, -11, -64, -26, 25, -18, 2, 41, 1, -39,
-7, -54, -105, -59, 5, -14, 31, 45, -2, 1, 36, 15, 14, 41, 7, -3,
53, 2, -90, -73, -98, -82, -59, -26, 43, -41, -10, 76, 62, 57, 40, 29,
-2, 25, 70, 5, 10, -4, -26, 43, 16, -54, -41, 16, 14, -10, 34, 11,
-36, -17, -13, -99, -76, 0, -12, -17, 47, 7, -8, 29, 23, -10, 45, 13,
-17, 33, 67, -27, -81, -88, -91, -54, -78, 8, -18, -35, 63, 72, 66, 41,
35, 5, 8, 72, 49, 14, 8, -36, 27, 65, -6, -49, 2, 22, -20, -2,
27, -27, -25, -10, -51, -102, -14, 0, -27, 25, 46, 6, 6, 28, -1, 16,
45, -18, 12, 68, 8, -92, -77, -102, -62, -72, -25, 47, -37, 41, 78, 67,
56, 38, 15, -7, 58, 66, 6, 26, -33, -1, 75, 15, -49, -34, 21, -10,
-13, 37, 16, -28, -6, -34, -95, -78, 2, -29, -2, 41, 25, -2, 5, 12,
8, 43, 20, -12, 60, 38, -77, -88, -82, -95, -66, -45, 46, -14, -35, 80,
66, 53, 35, 45, 4, 30, 75, 9, 19, 26, -41, 64, 40, -38, -42, 0,
5, -17, 31, 35, -24, -22, -19, -84, -98, -14, 5, -33, 34, 32, 9, 1,
12, 6, 34, 35, -3, 8, 62, -43, -94, -80, -96, -64, -70, 28, 14, -45,
43, 82, 60, 31, 41, 24, -18, 51, 22, -2, 42, -22, -18, 69, -18, -43,
-16, 14, -1, 8, 39, -11, -27, -9, -39, -99, -41, 12, -25, -12, 33, 16,
12, 12, 2, 7, 42, 15, -7, 38, 43, -66, -83, -95, -71, -65, -53, 49,
-39, 10, 81, 73, 54, 36, 39, -15, 28, 80, 8, 42, 5, -32, 55, 44,
-34, -22, 7, 11, -8, 20, 6, -31, -16, -23, -79, -97, 9, -8, -27, 20,
34, 19, 13, 5, 0, 25, 34, -7, 19, 53, -36, -90, -79, -83, -54, -70,
19, 26, -6, 70, 72, 60, 28, 39, -2, 4, 79, 29, -1, 43, -37, 26,
60, -7, -38, 0, 13, -13, 4, 36, -5, -19, -13, -64, -103, -48, 18, -26,
7, 27, 22, 20, 6, -2, 15, 37, 21, -1, 51, -6, -82, -80, -107, -72,
-70, -15, 44, -27, 11, 77, 62, 29, 27, 35, -9, 61, 52, 1, 41, 13,
-33, 66, 10, -36, -19, 8, -9, -11, 37, 11, -33, -10, -51, -97, -76, -3,
6, -19, 17, 25, 28, 16, 3, 5, 29, 30, 3, 25, 51, -76, -69, -92,
-90, -46, -69, 43, -6, -11, 68, 77, 37, 23, 35, 6, 15, 66, 13, 24,
25, -28, 19, 60, -31, -27, 6, 12, -26, 28, 32, -32, -24, -15, -64, -93,
-19, 19, -15, -7, 12, 28, 27, 8, 0, 15, 31, 12, 13, 60, -7, -93,
-75, -103, -49, -64, -22, 15, -23, 54, 77, 60, 26, 31, 17, 1, 55, 51,
7, 40, -17, -4, 62, 18, -35, 3, 30, -16, -21, 49, -22, -36, -7, -42,
-93, -80, 14, -6, -14, 1, 14, 34, 17, -6, 1, 27, 27, 9, 54, 20,
-90, -76, -83, -65, -57, -41, 46, -4, 35, 79, 64, 34, 14, 32, -1, 47,
61, 6, 26, 27, -20, 55, 38, -31, -33, 28, -4, -36, 33, 40, -35, -15,
-30, -82, -92, -25, 12, -6, -1, 4, 31, 35, 4, -6, 22, 33, 9, 17,
43, -69, -89, -74, -98, -55, -61, 31, 19, -19, 56, 70, 47, 11, 24, 20,
11, 66, 19, 14, 36, -19, -1, 58, -17, -41, -6, 29, -43, 3, 58, -18,
-47, -14, -69, -104, -46, 12, -5, -3, -4, 23, 37, 23, 1, 10, 34, 14,
12, 54, 17, -94, -73, -102, -65, -57, 6, 41, -24, 33, 80, 67, 18, 12,
22, 6, 47, 61, 4, 38, -3, -17, 59, 6, -37, -22, 26, 6, -46, 59,
19, -51, -26, -18, -81, -70, 13, -3, -12, 2, 3, 28, 31, 14, -15, 9,
22, 4, 43, 39, -67, -83, -98, -81, -47, -62, 31, -11, 16, 78, 67, 51,
14, 21, 3, 32, 73, 19, 9, 16, -30, 37, 62, -6, -32, 15, 22, -39,
-5, 63, -36, -38, -16, -64, -109, -44, 5, -15, 6, -8, 6, 37, 29, -9,
-10, 33, 19, 30, 55, -37, -88, -68, -104, -45, -66, -4, 38, -19, 73, 69,
57, 25, 8, 11, 17, 69, 32, 2, 39, 0, 15, 74, 13, -38, -16, 28,
-23, -24, 53, 30, -37, -22, -47, -104, -73, 10, 0, -1, -7, -7, 26, 39,
3, -21, 20, 30, 7, 43, -11, -90, -67, -93, -79, -62, -33, 46, -10, 16,
83, 59, 36, 9, 16, -4, 28, 52, -1, 28, 16, -29, 68, 35, -32, -28,
17, 20, -37, 35, 48, -22, -35, -24, -87, -92, -11, 11, -13, 7, -12, 11,
38, 32, -4, 2, 34, 10, 21, 53, -34, -77, -78, -97, -46, -66, 33, 13,
-9, 67, 72, 62, 13, 21, 5, 3, 70, 41, 10, 29, -27, 10, 73, -19,
-39, 1, 33, -20, -28, 53, 0, -29, -29, -54, -94, -36, 21, -8, -3, 5,
-7, 33, 41, 6, -18, 16, 22, 11, 54, -1, -90, -69, -102, -56, -53, -42,
39, -5, 43, 79, 76, 43, 10, 14, -7, 45, 58, 6, 21, -17, -9, 65,
37, -32, -18, 34, 0, -38, 28, 42, -20, -23, -41, -84, -97, -19, 2, -13,
4, -14, -4, 36, 19, -15, 3, 30, 2, 52, 26, -79, -76, -80, -73, -53,
-60, 31, 26, -3, 86, 79, 56, 16, 24, 8, 23, 70, 21, 11, 18, -21,
54, 56, -14, -50, -9, 19, -40, 9, 45, 10, -12, -37, -68, -105, -54, 18,
-11, -6, -5, -4, 19, 35, 0, -7, 26, 11, 6, 59, -57, -85, -67, -103,
-57, -75, 3, 48, -9, 44, 81, 66, 25, 22, 28, -10, 35, 40, 4, 22,
-18, -9, 66, 9, -42, -32, 31, 9, -10, 42, 17, -7, -29, -54, -97, -82,
9, 16, -15, -1, -15, 10, 33, 24, 0, 19, 14, -4, 51, 39, -69, -68,
-102, -76, -52, -74, 57, 4, 24, 84, 73, 58, 15, 33, -2, 13, 70, 27,
26, 1, -25, 49, 62, -34, -42, 22, 23, -37, 11, 23, -3, -15, -51, -75,
-107, -9, 30, -16, -10, -1, 1, 31, 30, 5, 6, 25, -11, 32, 62, -42,
-86, -88, -96, -51, -79, -2, 61, 0, 73, 78, 60, 26, 27, 8, -8, 69,
50, 5, 17, -28, 26, 78, 19, -47, 8, 36, -30, -8, 42, 8, -4, -45,
-68, -93, -90, 35, -2, -20, 4, -9, 2, 27, 12, 11, 27, 7, -14, 68,
-9, -94, -73, -100, -51, -68, -42, 62, 17, 13, 80, 62, 36, 25, 42, -5,
51, 71, 6, 15, 4, 0, 73, 44, -32, -47, 26, -6, -30, 34, 15, 0,
-7, -70, -78, -98, -20, 37, -17, 7, -9, -12, 21, 19, 8, 27, 17, -15,
20, 62, -77, -78, -87, -98, -48, -70, 40, 43, 5, 67, 81, 50, 27, 37,
4, -12, 69, 15, -2, 19, -27, 13, 70, -11, -58, 2, 50, -24, 17, 33,
-2, -2, -44, -65, -102, -59, 36, 3, -20, 4, -19, 14, 32, 11, 15, 15,
-15, 4, 63, 6, -82, -71, -99, -51, -63, -54, 55, 6, 47, 80, 66, 44,
44, 28, -18, 40, 73, -8, 16, -19, -13, 71, 60, -47, -20, 46, 5, -36,
23, 8, -9, -35, -62, -72, -80, 20, 24, -24, -4, -3, 6, 23, 11, 14,
32, 10, -5, 53, 28, -72, -76, -103, -69, -47, -72, 23, 43, 23, 74, 72,
52, 33, 52, -5, 15, 76, 25, -1, -2, -25, 48, 74, 6, -47, 35, 26,
-35, 7, 34, 0, -33, -60, -65, -93, -56, 39, -14, -13, 0, -7, 17, 14,
9, 30, 22, -13, 6, 52, -51, -95, -80, -98, -46, -71, -7, 52, 7, 33,
70, 54, 40, 49, 35, -11, 67, 48, 1, 27, -10, 18, 84, 29, -41, -21,
44, -24, -19, 31, 15, -13, -41, -56, -87, -82, 13, 30, -24, -4, -11, 0,
20, 8, 28, 33, -5, -11, 50, -18, -99, -82, -103, -70, -43, -35, 60, 19,
18, 77, 72, 33, 38, 43, -2, 15, 63, -2, 19, 14, -33, 40, 51, -24,
-32, 27, 27, -30, 28, 30, -3, -34, -48, -75, -98, -17, 34, -14, -22, -7,
-8, 18, 13, 3, 31, 6, -15, 31, 58, -45, -82, -93, -89, -37, -70, 0,
34, 5, 65, 73, 55, 44, 47, 4, -4, 65, 46, -2, 20, -32, 14, 84,
30, -34, 15, 39, -14, -14, 31, 2, -36, -46, -43, -93, -40, 37, 2, -22,
-8, -13, 10, 16, -3, 19, 33, -4, 13, 68, -6, -93, -76, -98, -44, -67,
-38, 61, 23, 54, 82, 63, 43, 49, 46, -9, 48, 56, -9, 10, -17, -13,
69, 50, -25, -29, 38, -1, -22, 22, 36, -6, -53, -35, -71, -101, -18, 14,
-23, -11, -9, -7, 16, 2, 6, 31, 9, -20, 56, 28, -83, -87, -89, -89,
-60, -63, 45, 44, 9, 62, 67, 50, 49, 50, 10, 29, 69, 11, 0, 24,
-23, 47, 65, -8, -38, 10, 31, -20, 10, 40, 15, -39, -39, -53, -106, -55,
31, 6, -15, -6, -9, 12, 17, 0, 26, 19, -6, 4, 56, -53, -97, -80,
-96, -58, -73, 12, 51, 4, 49, 83, 62, 48, 52, 21, -7, 44, 23, -8,
28, -7, -13, 59, 14, -30, -2, 27, -8, -20, 37, 31, -21, -56, -38, -95,
-79, 15, 12, -24, -12, -12, 6, 19, 1, 4, 24, 5, -9, 38, 37, -73,
-80, -93, -74, -70, -66, 38, 11, 33, 83, 67, 53, 54, 31, -3, 31, 63,
9, 18, 4, -19, 44, 63, 4, -16, 24, 4, -25, 11, 40, -2, -51, -46,
-47, -102, -3, 25, -20, -14, -17, -17, 28, 6, -6, 12, 21, -7, 23, 51,
-44, -99, -83, -85, -63, -75, 11, 51, 2, 76, 75, 52, 52, 54, 3, 13,
64, 30, -9, 24, -24, 21, 70, 20, -26, -3, 17, -25, 0, 41, 29, -42,
-56, -40, -87, -80, 16, -13, -20, -13, -29, 6, 29, -7, 6, 24, 16, -7,
56, -10, -99, -85, -94, -82, -78, -20, 55, 19, 28, 79, 58, 44, 54, 43,
1, 53, 51, -9, 15, 14, -24, 69, 38, -26, -13, 31, 5, -12, 45, 30,
-13, -48, -50, -70, -94, -8, 32, -22, -11, -28, -8, 33, 14, -11, 19, 22,
-4, 22, 55, -87, -93, -86, -93, -76, -80, 47, 34, 10, 66, 79, 53, 53,
54, 12, 9, 64, 3, 10, 29, -24, 19, 79, -19, -26, 30, 24, -36, -4,
47, -6, -40, -54, -46, -100, -40, 40, -6, -21, -10, -24, 22, 23, -5, -3,
33, 4, -1, 55, 0, -97, -85, -89, -70, -93, -39, 56, 3, 54, 82, 62,
54, 52, 25, 2, 52, 52, -6, 37, -12, -9, 71, 47, -28, 13, 39, -24,
-26, 49, 8, -35, -54, -56, -73, -91, 33, 9, -26, -7, -30, -18, 32, 6,
-10, 14, 32, -11, 44, 29, -79, -90, -91, -75, -77, -66, 40, 37, 4, 82,
71, 61, 58, 49, -6, 34, 66, 2, 7, 38, -22, 51, 66, -10, -32, 28,
-4, -44, 31, 53, -6, -52, -56, -68, -100, -38, 38, -24, -13, -21, -26, 20,
31, -10, -1, 28, 7, 0, 49, -60, -92, -78, -100, -70, -82, 12, 52, 6,
50, 82, 63, 66, 59, 16, -4, 71, 17, -8, 36, -1, -10, 76, 21, -32,
2, 43, -16, 3, 60, 18, -35, -64, -58, -91, -69, 26, 17, -26, -13, -28,
8, 35, 10, -5, 19, 16, -8, 46, 33, -100, -77, -98, -77, -74, -74, 58,
15, 35, 84, 73, 65, 62, 31, -3, 42, 67, -9, 25, 12, -16, 46, 75,
-15, -20, 36, 9, -46, 53, 41, -20, -63, -67, -59, -93, 1, 43, -18, -21,
-16, -11, 34, 20, -8, -4, 17, -4, 26, 54, -53, -103, -90, -93, -74, -92,
1, 57, 17, 75, 78, 64, 62, 46, -4, 17, 68, 21, -4, 23, -6, 31,
75, 41, -23, 23, 28, -41, -4, 62, -3, -48, -63, -52, -86, -80, 49, -5,
-29, -3, -27, -7, 35, -2, -8, 5, 9, 16, 59, -13, -101, -85, -97, -70,
-93, -38, 53, 19, 34, 76, 66, 63, 60, 31, -3, 60, 35, -10, 23, 12,
21, 72, 55, -8, -26, 30, -23, -18, 49, 37, -7, -72, -57, -70, -97, -3,
53, -42, -14, -16, -22, 30, 11, -9, -2, 8, 5, 26, 22, -82, -93, -96,
-89, -67, -63, 43, 30, 16, 67, 72, 69, 64, 46, -10, 6, 63, 0, 10,
25, -4, 30, 67, 15, -31, 12, 32, -32, 31, 44, 13, -38, -77, -63, -103,
-44, 59, 14, -44, -3, -30, 11, 43, 4, -2, 3, 2, 14, 47, -11, -92,
-85, -97, -74, -92, -41, 44, 11, 53, 74, 73, 65, 57, 13, -12, 53, 61,
-1, 21, -1, 15, 65, 55, -22, -8, 30, -14, -13, 45, 23, -15, -78, -72,
-66, -82, 39, 48, -41, -26, -6, -5, 41, 14, -2, 5, -8, 3, 47, 13,
-84, -90, -95, -77, -83, -64, 28, 27, 37, 76, 74, 70, 64, 32, -8, 25,
65, 23, 9, 4, 4, 56, 63, 18, -23, 29, -1, -16, 38, 37, 4, -63,
-82, -58, -97, -67, 68, -18, -49, -5, -23, 32, 26, 2, 11, -2, -13, 40,
36, -63, -93, -83, -97, -78, -79, 4, 37, 10, 71, 73, 67, 65, 52, 19,
8, 59, 39, 9, 17, -1, 45, 67, 31, -16, -6, 13, -19, 27, 38, 17,
-2, -92, -62, -79, -96, 17, 61, -50, -16, -13, -7, 35, 10, 12, 7, -11,
3, 52, -36, -94, -81, -96, -81, -82, -28, 33, 12, 37, 77, 70, 63, 52,
29, -6, 15, 56, 20, 15, 2, 7, 53, 49, -3, -21, 18, 1, 9, 40,
20, 11, -51, -87, -66, -105, -20, 71, -1, -51, -11, -18, 25, 30, 7, 7,
-13, -11, 37, 37, -63, -81, -89, -88, -76, -84, -9, 15, 22, 75, 77, 68,
57, 41, 8, 4, 46, 46, 19, 6, 2, 42, 64, 38, -22, 6, 9, -17,
19, 20, 13, -32, -87, -63, -77, -62, 54, 31, -49, -24, -17, 10, 31, 8,
9, 2, -16, 27, 55, -34, -96, -76, -92, -73, -87, -34, 32, 4, 62, 79,
67, 65, 56, 23, 1, 35, 54, 29, 19, 6, 26, 62, 54, 4, -2, 10,
-12, 12, 30, 19, -15, -79, -72, -69, -105, -37, 57, -30, -31, -9, -20, 35,
14, 9, 9, -16, -18, 58, 6, -93, -84, -86, -86, -89, -68, 26, 9, 8,
80, 65, 60, 54, 50, 20, 20, 53, 37, 19, 21, 15, 51, 65, 22, -17,
-1, -2, 9, 34, 27, 18, -31, -73, -61, -104, -67, 46, 32, -31, -12, -35,
6, 35, 6, 12, -9, -25, 7, 57, -68, -90, -77, -89, -67, -89, 9, 25,
2, 67, 80, 60, 48, 48, 33, 2, 30, 35, 13, 23, 14, 17, 57, 33,
-16, -14, 0, 0, 27, 28, 27, -7, -66, -66, -91, -93, 20, 52, -19, -13,
-45, -16, 38, 15, 7, -4, -21, -8, 44, 16, -80, -77, -92, -69, -79, -69,
32, -3, 45, 84, 70, 57, 42, 47, 6, 14, 49, 25, 27, 24, 12, 48,
73, -5, -19, -4, -2, 18, 29, 28, 9, -55, -69, -55, -100, -18, 61, 2,
-24, -22, -31, 29, 24, 11, 7, -13, -14, 36, 38, -58, -81, -80, -77, -65,
-84, 0, 27, 15, 72, 79, 65, 31, 41, 21, 4, 46, 35, 15, 31, 11,
32, 74, 48, -9, -8, 2, 14, 26, 26, 29, -39, -74, -53, -85, -97, 11,
24, -21, -13, -45, -20, 39, 8, 0, -9, -21, -5, 45, -38, -82, -71, -98,
-72, -83, -34, 34, 5, 26, 79, 72, 37, 31, 56, 17, 37, 51, 15, 24,
26, 6, 66, 68, 6, -24, -9, 7, 20, 27, 37, 10, -61, -57, -75, -109,
-19, 60, -13, -12, -39, -34, 32, 32, 3, -3, -20, -20, 35, 33, -83, -65,
-90, -82, -61, -56, 26, 18, 13, 61, 82, 48, 23, 50, 30, 5, 48, 23,
16, 31, 8, 17, 77, 22, -28, -11, 6, 10, 24, 37, 25, -43, -74, -52,
-108, -52, 53, 23, -16, -27, -45, 21, 40, 5, -3, -14, -27, 15, 50, -39,
-84, -77, -96, -65, -79, -39, 30, 12, 49, 79, 76, 40, 45, 40, 3, 36,
56, 19, 36, 21, 5, 54, 75, -18, -21, 6, 10, 13, 23, 34, -21, -69,
-53, -71, -111, 31, 34, -16, 2, -37, -3, 47, 7, -6, 1, -14, -3, 53,
-10, -88, -65, -90, -70, -68, -63, 18, 26, 31, 72, 78, 45, 21, 50, 7,
20, 59, 22, 13, 41, 4, 33, 78, 37, -27, -3, 4, 0, 18, 45, 33,
-62, -63, -63, -106, -57, 52, -2, 2, -23, -58, 21, 25, -4, 5, -6, -30,
6, 18, -79, -75, -79, -100, -67, -77, 1, 33, 10, 41, 72, 58, 22, 36,
47, 13, 54, 35, 6, 32, 24, 23, 72, 54, -9, -23, -2, 4, 6, 34,
51, -9, -78, -56, -90, -88, 23, 49, -3, -10, -59, -12, 51, 17, -1, 1,
-26, -11, 48, -8, -83, -71, -101, -72, -73, -24, 35, 14, 35, 70, 76, 33,
27, 48, 19, 22, 54, 1, 24, 38, 10, 43, 61, 6, -18, -7, 6, 2,
16, 53, 23, -60, -76, -58, -105, -16, 53, 3, -7, -40, -31, 43, 33, -7,
1, -18, -19, 41, 15, -80, -73, -96, -82, -66, -82, 0, 19, 20, 67, 74,
59, 35, 48, 28, 17, 54, 35, -1, 38, 13, 30, 79, 49, -14, -12, -1,
1, -2, 25, 39, -32, -79, -65, -86, -55, 47, 22, -18, -9, -42, 24, 45,
2, -6, -3, -24, 26, 35, -62, -84, -68, -95, -63, -86, -24, 43, 11, 60,
77, 65, 40, 36, 47, 17, 45, 41, 4, 17, 21, 19, 68, 60, 3, -10,
-5, 1, -2, 14, 55, 31, -69, -69, -76, -106, -34, 43, -16, -13, -29, -26,
40, 9, -7, 1, -16, -16, 37, -28, -89, -68, -90, -83, -84, -49, 39, 18,
15, 66, 69, 52, 36, 41, 24, 20, 49, 16, 10, 27, 16, 57, 72, 19,
-14, -2, 2, -10, 10, 44, 41, -22, -71, -68, -99, -64, 36, 31, -20, -19,
-29, 22, 44, 5, 1, -9, -21, 28, 40, -54, -80, -84, -88, -69, -86, 24,
26, 2, 58, 80, 61, 42, 45, 24, 14, 48, 47, 6, 24, 17, 23, 67,
36, -5, -4, 6, -7, -17, 40, 51, -8, -61, -65, -95, -78, 18, 43, -14,
-19, -28, 5, 46, 15, -5, 2, -27, 14, 52, -28, -94, -86, -100, -68, -81,
-46, 42, -2, 34, 82, 71, 43, 43, 28, 8, 40, 52, 22, 25, 18, 17,
61, 67, 22, -8, 11, 1, -22, 4, 50, 11, -59, -65, -69, -103, -7, 48,
1, -25, -20, -21, 40, 26, -8, -3, -12, -28, 51, 6, -93, -91, -90, -76,
-78, -69, 26, 25, -6, 77, 77, 51, 42, 50, 16, 26, 59, 29, 12, 28,
18, 52, 71, 41, -2, -8, 9, -18, -7, 34, 56, 3, -69, -56, -92, -79,
16, 13, -19, -18, -26, 11, 49, -5, -6, -2, -32, -7, 51, -76, -100, -82,
-91, -65, -85, 8, 37, -10, 41, 84, 57, 38, 48, 30, 1, 41, 41, 12,
20, 5, 17, 72, 53, 16, -16, 8, 10, -22, 24, 59, 23, -56, -55, -83,
-100, -7, 45, -3, -17, -27, -4, 46, 28, -15, 4, -20, -25, 47, 18, -103,
-82, -91, -68, -83, -71, 45, -3, 24, 73, 75, 54, 43, 42, 5, 26, 56,
15, 18, 8, 8, 57, 73, 39, -13, -9, 22, -17, -23, 59, 42, -38, -72,
-56, -105, -36, 47, 13, -18, -19, -22, 38, 47, -3, -11, 5, -35, 21, 36,
-68, -101, -95, -73, -74, -90, 8, 34, 11, 66, 78, 66, 38, 43, 12, 19,
56, 33, 13, 14, -1, 43, 72, 60, 29, -24, 17, -3, -35, 11, 62, -14,
-78, -57, -75, -102, 35, 32, -13, -13, -27, -11, 56, 13, -20, 2, -8, -30,
45, -34, -104, -90, -91, -67, -93, -18, 41, -7, 24, 78, 74, 46, 33, 32,
3, 52, 40, 11, 27, 4, 26, 74, 67, 41, -17, -19, 11, -31, -5, 53,
49, -65, -64, -63, -103, -44, 46, -4, -17, -22, -22, 35, 58, -14, -9, -4,
-32, 12, 0, -94, -85, -95, -85, -71, -51, 41, 4, 4, 65, 72, 62, 31,
30, 13, 14, 52, 14, 28, 22, -10, 41, 68, 53, 6, -27, 12, 0, -21,
30, 55, -6, -70, -59, -106, -81, 19, 35, -6, -18, -24, 14, 59, 25, -18,
6, -27, -7, 56, -25, -92, -82, -91, -72, -91, -24, 14, -16, 51, 72, 69,
54, 19, 19, 11, 44, 44, 17, 27, -10, 25, 77, 64, 30, -22, -9, 8,
-11, -5, 56, 25, -68, -70, -60, -100, -6, 49, 3, -21, -18, -3, 57, 49,
-10, -10, -2, -32, 48, 16, -92, -87, -98, -78, -94, -57, 42, 5, 33, 76,
66, 63, 30, 18, 21, 34, 48, 19, 27, 1, 8, 69, 70, 58, 16, -15,
8, -6, -9, 16, 42, -50, -77, -48, -95, -91, 45, 16, -22, -12, -21, 3,
60, 4, -18, 6, -25, 22, 40, -72, -100, -86, -92, -82, -83, 23, 31, -19,
47, 72, 64, 40, 15, 18, 22, 51, 28, 18, 33, -5, 52, 75, 66, 32,
-19, -2, -5, -8, 10, 45, 28, -81, -48, -71, -109, -25, 48, -23, -21, -19,
-15, 42, 52, -16, -1, -14, -33, 34, -40, -103, -83, -87, -73, -90, -4, 49,
-9, 28, 80, 67, 49, 17, 13, 15, 37, 36, 13, 39, 8, -1, 63, 67,
38, -3, -1, 1, -9, 11, 31, 45, -37, -86, -50, -99, -67, 33, 26, -31,
-11, -14, 23, 58, 17, -13, -8, -35, 19, 40, -67, -89, -86, -78, -77, -77,
17, 4, 8, 70, 69, 65, 46, 10, 13, 29, 55, 27, 35, 23, -12, 45,
80, 58, 3, -3, 2, -8, 10, 18, 45, -13, -94, -59, -51, -93, 3, 41,
-20, -31, -10, 15, 57, 35, -5, -7, -34, 0, 53, -32, -104, -87, -85, -70,
-84, -15, 45, 2, 55, 72, 68, 56, 19, 19, 20, 47, 40, 8, 34, -14,
16, 76, 66, 31, -2, 5, -8, 4, 19, 27, 6, -75, -70, -45, -93, -79,
46, 2, -31, -15, -9, 28, 44, 4, -4, -13, -33, 47, -5, -101, -92, -84,
-80, -89, -44, 42, 16, 12, 66, 69, 66, 28, 14, 20, 36, 55, 12, 18,
20, -14, 66, 77, 42, 3, 7, 10, -1, 26, 28, 35, -14, -79, -47, -78,
-90, -1, 42, -34, -23, -12, 13, 57, 37, -8, -6, -37, -2, 51, -87, -102,
-88, -87, -81, -88, 23, 30, 13, 53, 70, 73, 34, 15, 27, 15, 40, 27,
14, 25, -11, 14, 69, 53, 16, 12, 13, -11, 25, 29, 38, 9, -75, -74,
-68, -102, -23, 50, 4, -32, -12, 1, 49, 50, 6, 10, -27, -22, 49, -5,
-97, -91, -95, -85, -93, -47, 32, 11, 36, 70, 74, 64, 15, 30, 22, 29,
55, 21, 31, 0, -1, 57, 67, 44, 10, 13, -6, -1, 25, 38, 18, -66,
-84, -44, -81, -56, 40, 21, -30, -17, -9, 36, 57, 18, 5, 4, -38, 37,
25, -84, -101, -92, -87, -90, -71, 10, 34, 22, 64, 72, 72, 33, 18, 29,
14, 49, 32, 15, 24, -7, 41, 66, 52, 24, 15, -1, -12, 19, 32, 35,
-38, -95, -54, -58, -106, -31, 25, -22, -11, -14, -2, 51, 29, 7, 15, -29,
-33, 52, -54, -103, -87, -98, -84, -80, -14, 34, 26, 44, 66, 80, 47, 12,
31, 22, 35, 38, 14, 24, -1, -5, 66, 61, 25, 14, 17, -16, 10, 31,
35, 25, -55, -69, -41, -105, -64, 39, 11, -17, -16, -16, 40, 58, 12, 12,
-17, -41, 31, 36, -98, -81, -91, -90, -85, -70, 29, 27, 38, 66, 74, 66,
18, 16, 28, 17, 35, 19, 24, 7, -10, 37, 66, 42, 18, 15, 1, -15,
29, 36, 36, -27, -102, -54, -83, -89, 22, 21, -25, -9, -26, 28, 63, 27,
12, -2, -43, 4, 52, -48, -103, -85, -95, -85, -81, -20, 27, 28, 63, 76,
80, 62, 6, 24, 22, 27, 33, 18, 13, -11, 19, 59, 59, 35, 13, 14,
-7, 1, 26, 43, 2, -88, -70, -32, -96, -2, 35, -23, -12, -16, -23, 62,
34, 9, 19, -9, -17, 56, -16, -105, -84, -91, -87, -87, -44, 20, 28, 42,
71, 75, 68, 24, 11, 28, 19, 28, 23, 25, 6, 2, 54, 65, 47, 19,
16, 0, -4, 25, 40, 44, -68, -93, -33, -80, -92, 25, -12, -25, -7, -24,
21, 47, 15, 17, 5, -38, 5, 16, -95, -97, -89, -96, -89, -62, 8, 29,
31, 60, 76, 69, 43, 10, 23, 28, 20, 31, 24, 10, -10, 17, 67, 49,
33, 16, 6, 0, 13, 37, 57, 13, -86, -50, -62, -108, -2, 53, -30, -9,
-17, -6, 54, 46, 10, 14, -32, -13, 56, -20, -105, -85, -93, -89, -91, -47,
26, 25, 46, 71, 72, 53, 17, 12, 28, 14, 25, 28, 11, -7, 2, 59,
63, 39, 28, 6, 6, 2, 26, 55, 34, -58, -94, -49, -103, -37, 55, -11,
-48, -6, -17, 39, 57, 12, 13, -23, -27, 53, 10, -96, -96, -96, -93, -89,
-64, 2, 30, 32, 62, 72, 62, 46, 7, 23, 18, 16, 33, 22, -4, -13,
47, 65, 36, 41, 8, 10, 8, 3, 32, 48, -29, -92, -65, -69, -104, 45,
22, -48, -13, -12, 20, 60, 25, 10, 13, -29, 36, 44, -70, -103, -86, -94,
-88, -78, -17, 27, 23, 56, 69, 61, 50, 21, 15, 22, 15, 28, 23, 11,
-13, 31, 67, 35, 41, 29, 4, 16, 1, 16, 54, 35, -90, -76, -63, -105,
-42, 63, -39, -33, -7, -19, 35, 40, 9, 18, -21, -30, 51, -40, -107, -86,
-88, -92, -93, -33, 25, 27, 34, 64, 63, 49, 31, 23, 27, 21, 32, 20,
17, -7, -26, 48, 40, 34, 41, 4, 13, 6, 7, 47, 57, -27, -98, -59,
-101, -73, 45, 36, -43, -15, -18, 20, 62, 24, 23, -5, -45, 31, 44, -70,
-93, -92, -92, -90, -83, -18, 31, 36, 62, 71, 61, 32, 20, 22, 22, 33,
31, 16, 11, -34, 20, 79, 32, 43, 10, 9, 27, 4, 30, 67, 5, -93,
-77, -65, -97, 15, 50, -19, -37, -17, 8, 54, 37, 5, 20, -40, 7, 61,
-42, -106, -86, -95, -86, -91, -38, 20, 32, 58, 67, 62, 43, 24, 23, 17,
31, 38, 12, 19, -26, -2, 74, 50, 40, 16, 4, 29, 12, -1, 36, 39,
-72, -94, -57, -101, -80, 52, 2, -38, -28, -13, 37, 44, 13, 19, 6, -36,
61, -3, -96, -87, -93, -95, -95, -57, 9, 19, 35, 68, 69, 49, 24, 25,
26, 25, 39, 16, 12, 9, -34, 61, 62, 38, 39, 5, 29, 23, 2, 18,
59, 17, -106, -65, -83, -100, 2, 48, -30, -34, -20, 13, 46, 19, 11, 20,
-28, 0, 63, -85, -92, -85, -101, -90, -90, -4, 20, 26, 61, 75, 60, 28,
21, 35, 27, 28, 26, 12, 13, -34, -5, 68, 39, 47, 13, 5, 32, 12,
7, 47, 45, -61, -101, -70, -103, -27, 47, 8, -30, -26, 1, 34, 40, 8,
22, -10, -23, 57, 3, -102, -82, -103, -95, -92, -59, 16, 8, 46, 77, 73,
54, 14, 27, 34, 25, 33, 19, 17, -22, -30, 53, 58, 46, 17, -2, 35,
36, 14, 35, 55, -30, -102, -69, -77, -52, 36, 23, -16, -31, -7, 34, 47,
15, 1, 23, -30, 43, 42, -85, -99, -85, -98, -87, -76, -7, 13, 33, 71,
72, 64, 26, 7, 41, 29, 29, 20, 14, 22, -44, 28, 64, 45, 47, -7,
30, 40, 20, 17, 37, -3, -91, -80, -69, -99, -30, 35, -7, -22, -27, -2,
50, 31, -6, 18, 3, -16, 61, -53, -106, -84, -100, -89, -85, -24, 14, 5,
46, 71, 63, 36, 4, 22, 42, 33, 25, 13, 28, -12, -1, 64, 54, 55,
12, -10, 49, 24, 12, 35, 45, -36, -92, -66, -102, -62, 37, 5, -18, -30,
-19, 28, 54, 4, 10, 10, -23, 42, 44, -105, -81, -91, -91, -88, -48, 13,
4, 31, 74, 73, 43, 6, 12, 39, 44, 37, 12, 26, 5, -42, 15, 57,
59, 32, -17, 26, 49, 14, 33, 51, -12, -98, -81, -91, -90, 10, 38, -3,
-21, -30, 10, 55, 34, -2, 19, -16, 16, 61, -42, -105, -81, -90, -84, -92,
-35, 18, 14, 61, 81, 61, 32, 11, 32, 45, 36, 23, 19, 22, -37, -8,
56, 53, 41, -15, 9, 53, 32, 23, 51, 14, -78, -93, -63, -94, -27, 36,
10, -17, -26, -8, 48, 51, 3, 5, 12, -2, 59, -6, -99, -88, -88, -81,
-97, -62, 9, 15, 47, 75, 74, 42, 10, 12, 42, 46, 30, 17, 38, -29,
-35, 41, 61, 63, 25, -4, 42, 37, 27, 31, 48, -53, -103, -60, -78, -93,
26, 18, -16, -21, -19, 6, 53, 10, -13, 16, -3, 20, 30, -92, -100, -86,
-93, -93, -76, -2, 18, 21, 52, 77, 50, 12, 8, 27, 48, 31, 12, 33,
23, -40, 30, 61, 63, 40, -13, 10, 43, 35, 26, 45, 32, -73, -68, -63,
-99, -28, 37, -6, -18, -23, -6, 40, 51, -9, 7, 3, 8, 66, 1, -102,
-82, -93, -82, -95, -27, 14, 19, 43, 68, 74, 17, 3, 17, 48, 54, 20,
27, 24, -34, -28, 39, 65, 55, -4, -3, 36, 36, 30, 34, 44, -42, -108,
-61, -93, -57, 32, 23, -16, -18, -12, 29, 59, 24, -13, 13, 5, 51, 38,
-77, -98, -91, -85, -93, -83, -13, 11, 37, 65, 77, 50, 13, 10, 34, 63,
35, 7, 32, -21, -47, 19, 61, 70, 12, -12, 26, 34, 36, 29, 45, -8,
-99, -77, -66, -81, 10, 34, -7, -21, -21, 18, 55, 42, -5, 0, 12, 31,
56, -47, -103, -84, -92, -90, -93, -29, 11, 15, 59, 72, 57, 22, 14, 16,
60, 52, 10, 19, 23, -57, -6, 57, 66, 54, 4, 17, 34, 40, 38, 30,
40, -80, -90, -56, -93, -71, 39, 10, -20, -18, -5, 25, 46, 4, -8, 16,
9, 44, -14, -105, -90, -93, -88, -94, -55, 3, 6, 33, 70, 69, 35, 13,
13, 36, 65, 22, 13, 32, -18, -59, 49, 65, 61, 23, -7, 21, 37, 46,
29, 36, 1, -89, -63, -79, -94, -12, 38, -21, -21, -8, 16, 48, 43, -16,
9, 10, 26, 57, -34, -89, -90, -103, -90, -91, -11, 15, 25, 52, 74, 62,
12, 6, 29, 64, 53, 13, 33, 6, -61, -19, 56, 68, 36, -8, 17, 27,
34, 41, 31, 24, -61, -99, -70, -100, -47, 34, 12, -25, -14, 5, 40, 49,
4, -23, 19, 23, 61, -1, -95, -80, -101, -89, -88, -60, -1, 25, 46, 76,
73, 38, 18, 17, 56, 65, 26, 12, 20, -46, -42, 43, 68, 61, -2, 7,
28, 26, 51, 32, 30, -24, -96, -78, -77, -73, 11, 23, -14, -21, -17, 33,
50, 17, -24, 1, 21, 48, 30, -80, -96, -85, -96, -87, -69, -17, 15, 31,
67, 80, 48, 23, 7, 19, 67, 28, 13, 34, 11, -59, 23, 67, 55, 39,
2, 26, 25, 48, 41, 22, 33, -86, -90, -73, -97, -50, 28, -3, -19, -21,
4, 43, 31, -13, -12, 16, 26, 61, -54, -97, -79, -97, -94, -80, -33, 3,
31, 50, 67, 54, 25, 10, 12, 57, 30, 13, 29, 20, -40, -47, 63, 59,
51, 12, 5, 26, 38, 48, 20, 37, -16, -87, -67, -105, -72, 12, 21, -14,
-23, -10, 32, 51, 20, -18, 12, 26, 60, 35, -102, -84, -90, -92, -90, -73,
-6, 20, 43, 62, 75, 48, 18, 4, 42, 58, 22, 30, 20, -22, -53, 12,
64, 52, 25, 3, 24, 20, 41, 32, 37, 14, -81, -84, -92, -88, -2, 24,
-5, -13, -18, 22, 56, 34, -16, -12, 23, 45, 57, -44, -103, -87, -94, -93,
-86, -44, -8, 42, 54, 70, 58, 31, 11, 27, 67, 31, 25, 35, -19, -51,
-8, 62, 62, 49, 0, 20, 31, 33, 45, 35, 31, -62, -91, -71, -106, -21,
24, -4, -14, -22, -16, 51, 41, -4, -17, 10, 21, 67, -11, -97, -89, -92,
-92, -90, -52, -16, 16, 49, 65, 69, 45, 23, 1, 68, 42, 18, 45, 17,
-34, -24, 49, 53, 42, 32, 5, 31, 32, 33, 30, 52, -40, -93, -70, -94,
-83, -1, 5, -17, -19, -17, 23, 52, 11, -18, -1, 17, 44, 25, -81, -100,
-93, -92, -92, -64, -26, -2, 46, 60, 66, 52, 28, 7, 28, 66, 22, 43,
33, -20, -59, -11, 59, 37, 40, 15, 13, 34, 34, 24, 46, 36, -57, -68,
-78, -95, -24, 22, -5, -15, -29, 6, 54, 41, -2, -12, 12, 32, 64, -5,
-101, -93, -94, -85, -91, -61, -13, 40, 64, 63, 63, 38, 14, 15, 61, 49,
20, 45, -1, -62, -35, 51, 50, 35, 24, 7, 30, 46, 31, 42, 55, -39,
-93, -59, -97, -45, 26, 2, -17, -22, -3, 46, 47, 11, -26, -4, 22, 60,
31, -75, -97, -97, -84, -90, -70, -32, -6, 62, 65, 71, 48, 22, 8, 51,
61, 21, 37, 40, -50, -50, 34, 60, 29, 31, 12, 19, 39, 35, 16, 66,
-6, -92, -67, -72, -100, 13, 20, -19, -26, -24, 9, 54, 26, -22, -13, 14,
50, 56, -55, -105, -94, -94, -88, -79, -39, -22, 27, 68, 66, 55, 26, 6,
19, 62, 25, 30, 49, 4, -60, 13, 62, 29, 27, 27, 10, 42, 45, 15,
37, 61, -79, -79, -61, -99, -62, 23, -7, -27, -27, -4, 37, 48, -6, -21,
6, 14, 59, -23, -98, -95, -106, -88, -88, -48, -22, 7, 61, 74, 73, 34,
7, 8, 51, 60, 22, 47, 24, -47, -54, 33, 41, 21, 25, 10, 20, 48,
24, 30, 67, -2, -89, -60, -93, -91, 5, 38, -14, -34, -14, 27, 44, 34,
-8, 2, 15, 44, 56, -54, -97, -100, -95, -85, -77, -38, -8, 48, 73, 78,
63, 5, 1, 42, 66, 32, 24, 42, -25, -69, 10, 67, 25, 23, 15, 9,
45, 55, 20, 65, 32, -71, -80, -60, -104, -32, 43, 10, -39, -33, 25, 39,
39, 11, -19, 12, 34, 62, -20, -96, -90, -99, -87, -89, -50, -20, 1, 56,
75, 73, 28, 0, 32, 65, 51, 20, 29, 34, -67, -19, 67, 38, 11, 23,
3, 33, 60, 28, 31, 51, -51, -87, -59, -83, -95, 25, 21, -35, -47, -9,
39, 42, 20, -12, -6, 13, 66, 12, -91, -95, -91, -91, -91, -64, -19, -3,
30, 60, 79, 40, 1, 6, 38, 64, 30, 21, 44, -6, -75, 56, 55, 8,
22, 12, 4, 60, 45, 25, 57, 35, -85, -62, -68, -105, -44, 34, -17, -48,
-22, 29, 46, 43, 1, -14, 1, 38, 66, -74, -99, -91, -92, -88, -96, -24,
-1, 25, 50, 69, 49, 2, -6, 22, 64, 60, 15, 36, 22, -64, -34, 69,
12, 20, 14, -1, 36, 46, 33, 49, 53, -27, -83, -59, -99, -65, 16, 27,
-14, -42, 14, 50, 42, 26, 0, -4, 19, 66, 3, -90, -88, -100, -89, -96,
-74, -27, 25, 47, 59, 78, 39, -11, 10, 52, 69, 39, 15, 31, -39, -60,
45, 55, 8, 22, -5, 24, 53, 42, 41, 55, 0, -82, -72, -71, -91, -5,
29, -2, -40, -35, 50, 51, 33, 16, 3, 8, 61, 34, -74, -91, -87, -90,
-91, -83, -37, -3, 35, 54, 80, 62, 4, -12, 36, 65, 48, 21, 28, 16,
-71, 16, 66, 15, 22, 20, 16, 52, 44, 38, 49, 26, -62, -84, -66, -102,
-72, 36, 14, -33, -47, 7, 53, 35, 24, 7, -12, 12, 54, -51, -96, -84,
-97, -91, -93, -50, -12, 26, 51, 71, 71, 18, -11, 4, 50, 52, 26, 33,
28, -38, -52, 67, 28, 13, 18, -8, 44, 45, 41, 49, 49, 5, -81, -64,
-94, -93, -10, 30, -15, -48, -17, 42, 50, 31, 15, -10, -8, 54, 39, -98,
-88, -92, -89, -94, -84, -25, 7, 45, 59, 81, 34, -1, -4, 35, 73, 43,
33, 44, -16, -58, 18, 60, 12, 21, -6, 10, 42, 44, 51, 51, 28, -54,
-82, -72, -95, -37, 18, 16, -23, -29, 32, 51, 42, 31, 3, -11, 38, 58,
-48, -103, -96, -96, -90, -86, -49, -23, 38, 48, 70, 68, 19, -13, 6, 64,
52, 22, 45, 1, -54, -7, 55, 28, 21, 0, 3, 44, 45, 53, 59, 43,
-31, -81, -61, -86, -53, 18, 17, -16, -41, -22, 44, 50, 40, 16, -8, 23,
67, -9, -96, -93, -95, -89, -91, -58, -26, 7, 50, 69, 75, 24, -1, -12,
48, 65, 17, 30, 45, -17, -28, 44, 34, 12, 19, -3, 28, 45, 52, 57,
57, -8, -78, -65, -72, -102, -38, 25, -20, -34, -17, 17, 47, 48, 31, 3,
-3, 43, 20, -86, -94, -85, -90, -89, -74, -36, -6, 31, 48, 78, 39, 7,
-10, -5, 60, 32, 25, 52, -2, -64, -15, 47, 20, 26, 8, -1, 37, 53,
61, 59, 45, -29, -70, -64, -100, -62, 22, 13, -37, -23, -2, 33, 54, 44,
13, -7, 27, 68, -9, -102, -89, -95, -87, -92, -68, -6, 24, 43, 68, 71,
12, 2, -13, 42, 76, 26, 53, 26, -54, -37, 39, 34, 20, 13, -1, 22,
36, 65, 63, 54, -6, -76, -65, -93, -76, 8, 20, -28, -31, -5, 23, 47,
51, 35, -5, 18, 71, 24, -84, -96, -95, -90, -94, -80, -27, 18, 31, 56,
78, 35, 11, -16, 8, 70, 36, 22, 63, -35, -54, 26, 40, 9, 17, -2,
12, 30, 58, 68, 56, 26, -63, -72, -61, -100, -18, 27, -21, -39, -12, 10,
38, 59, 47, 6, -8, 62, 50, -60, -100, -86, -93, -89, -86, -35, 6, 21,
45, 76, 48, 12, 9, -19, 63, 56, 16, 56, 38, -49, 4, 46, 13, 11,
11, 7, 22, 49, 68, 49, 54, -44, -81, -58, -90, -83, 5, -8, -49, -22,
0, 19, 54, 51, 16, -8, 20, 71, -32, -104, -89, -89, -88, -93, -50, 2,
22, 27, 53, 57, 14, 16, -12, 5, 72, 17, 43, 55, -25, -54, 16, 22,
7, 19, 6, 7, 38, 68, 52, 54, 35, -59, -58, -76, -95, -19, 30, -21,
-40, 1, 16, 28, 55, 25, -11, 12, 67, 47, -63, -94, -89, -86, -87, -86,
-10, 24, 23, 37, 80, 46, 21, 3, -14, 57, 53, 14, 64, -4, -65, -8,
42, 2, 19, 11, 1, 12, 46, 64, 50, 52, -31, -80, -50, -99, -42, 27,
-2, -48, -16, 19, 24, 40, 59, 22, -1, 54, 65, -32, -100, -90, -87, -84,
-91, -57, -3, 30, 28, 71, 67, 13, 22, -12, 41, 63, 12, 43, 59, -61,
-32, 37, 19, 4, 12, -3, 7, 36, 69, 57, 57, -9, -79, -50, -69, -100,
11, 12, -39, -51, -8, 31, 33, 51, 35, 1, 13, 74, -1, -92, -90, -86,
-88, -92, -70, -19, 24, 33, 54, 73, 22, 23, 11, -12, 65, 14, 23, 67,
13, -60, 16, 36, 2, 13, 9, 0, 29, 66, 65, 57, 55, -66, -62, -59,
-103, -53, 21, -18, -51, -34, 27, 41, 36, 43, 9, 1, 49, 65, -78, -98,
-84, -91, -92, -78, -28, 10, 29, 35, 69, 32, 21, 23, -18, 37, 59, 7,
62, 42, -37, -44, 37, 7, 6, 14, -6, 1, 57, 71, 62, 66, 3, -75,
-53, -93, -71, 10, 16, -42, -52, 18, 59, 33, 40, 15, 1, 34, 74, 10,
-91, -90, -91, -86, -95, -66, 0, 17, 32, 62, 68, 15, 31, -12, 12, 68,
11, 12, 69, -8, -60, -2, 31, 1, 24, 4, -9, 26, 67, 63, 71, 26,
-66, -66, -62, -86, -13, 12, -12, -49, -11, 53, 36, 31, 31, 8, 21, 69,
37, -71, -96, -92, -84, -93, -78, -16, 2, 29, 61, 72, 22, 18, 24, -6,
67, 30, -1, 60, 57, -58, -25, 29, 4, 7, 10, -17, 24, 69, 57, 57,
54, -45, -69, -57, -97, -73, 12, -6, -36, -53, 5, 48, 29, 25, 5, 2,
37, 61, -54, -102, -87, -97, -88, -90, -30, 0, 4, 37, 79, 34, 9, 34,
-5, 16, 44, -8, 39, 73, 7, -47, 17, 12, 2, 30, -1, 1, 62, 62,
47, 74, 31, -72, -48, -87, -94, -14, -1, -24, -48, -20, 48, 51, 28, 8,
1, 23, 73, 42, -105, -86, -92, -91, -92, -46, 2, -1, 27, 70, 70, 10,
29, 9, 11, 64, 28, 15, 64, 30, -43, -26, 17, -3, 27, 9, -28, 17,
68, 41, 65, 50, -49, -62, -70, -102, -32, 8, -12, -39, -36, 25, 61, 49,
20, -3, 18, 60, 65, -42, -109, -93, -89, -91, -89, -19, -4, 11, 66, 74,
31, 13, 10, 7, 57, 40, -2, 30, 46, -26, -41, 17, 7, 18, 27, -19,
2, 61, 56, 54, 71, -26, -72, -34, -86, -58, 8, -6, -28, -38, 7, 41,
56, 40, 0, 1, 46, 75, -9, -101, -95, -92, -86, -94, -33, 13, -13, 54,
84, 42, 11, 21, -4, 52, 52, -3, 18, 55, -4, -46, 4, 16, -12, 24,
-12, -18, 46, 63, 36, 60, 8, -67, -39, -66, -109, 0, -2, -28, -38, -23,
18, 55, 59, 5, -13, 17, 54, 28, -87, -102, -93, -92, -88, -56, 9, -5,
0, 63, 59, 17, 24, 0, 2, 72, 5, 5, 49, 42, -17, -12, 18, -15,
16, 28, -27, 31, 65, 42, 52, 71, -15, -47, -42, -112, -62, 9, -27, -39,
-29, 13, 32, 58, 23, -22, 6, 43, 73, -2, -104, -89, -94, -84, -90, -1,
3, -7, 50, 83, 51, 19, 2, -13, 58, 64, -9, 36, 46, -2, -37, 4,
-10, -3, 38, -14, -26, 50, 49, 46, 78, 12, -64, -36, -95, -84, -8, -3,
-28, -32, 9, 27, 40, 64, 12, -12, 34, 72, 25, -86, -88, -90, -86, -95,
-59, 11, -14, 36, 84, 61, 22, 14, -15, 36, 71, 9, -3, 50, 12, -34,
-2, 20, -16, 35, 5, -39, 26, 70, 40, 75, 34, -50, -40, -51, -98, -23,
4, -22, -33, -18, 22, 32, 66, 40, -20, -3, 64, 54, -53, -103, -89, -83,
-90, -80, -3, 2, -5, 75, 67, 34, 14, -7, -4, 74, 25, -10, 34, 56,
-36, -15, 32, -7, -6, 35, -29, -3, 63, 54, 46, 68, -30, -49, -46, -94,
-84, 0, -15, -35, -26, 7, 24, 54, 57, -7, -20, 26, 73, -25, -105, -97,
-92, -78, -93, -20, 13, -10, 41, 80, 42, 20, -2, -9, 48, 69, -3, 21,
59, 14, -49, 36, 4, -26, 30, 15, -34, 52, 66, 45, 66, 29, -45, -39,
-81, -93, -35, 1, -34, -36, 4, 26, 25, 55, 15, -28, 4, 68, 61, -97,
-99, -95, -83, -87, -82, 15, -12, 27, 80, 67, 42, 6, -18, 25, 72, 36,
12, 46, 35, -39, -19, 39, -31, 13, 25, -28, -2, 60, 44, 66, 55, -30,
-49, -68, -100, -57, -5, -6, -43, -6, 29, 20, 43, 56, 1, -12, 51, 72,
-29, -99, -89, -92, -85, -94, -24, 9, 11, 72, 73, 51, 31, 1, 5, 68,
53, 8, 20, 46, -32, -41, 40, 10, -31, 29, -15, -19, 46, 67, 45, 67,
-3, -54, -39, -75, -77, -13, 10, -28, -48, 8, 30, 33, 60, 17, -24, 1,
78, 4, -93, -88, -95, -83, -94, -44, 10, -15, 26, 80, 56, 33, 10, -14,
21, 62, 14, 14, 51, 34, -58, 16, 26, -28, 9, 20, -27, 22, 64, 46,
53, 55, -53, -41, -59, -100, -58, 13, -9, -46, -9, 43, 21, 56, 39, -19,
-11, 49, 38, -77, -89, -85, -97, -88, -64, 6, -15, 7, 79, 75, 40, 15,
-22, -1, 64, 29, 6, 37, 55, -29, -55, 42, -19, -4, 24, -17, -17, 53,
50, 48, 65, 3, -52, -48, -94, -75, -5, 15, -46, -33, 31, 30, 24, 53,
-12, -16, 32, 77, 13, -91, -84, -97, -82, -92, -48, -7, -7, 64, 80, 61,
38, -7, -11, 45, 66, 25, 26, 55, 0, -60, 8, 28, -19, 21, -7, -26,
20, 57, 48, 66, 29, -44, -47, -85, -86, -17, 18, -14, -57, 22, 36, 22,
58, 29, -23, 19, 69, 41, -62, -85, -93, -85, -94, -71, -7, -20, 52, 81,
68, 48, 16, -10, 26, 72, 43, 10, 34, 18, -57, -16, 35, -9, -7, 0,
-27, 10, 57, 54, 54, 50, -34, -57, -43, -89, -46, 16, 3, -51, -35, 40,
20, 55, 47, -20, -10, 57, 65, -37, -89, -82, -98, -88, -88, -25, -18, -6,
64, 76, 61, 19, -8, -2, 63, 51, 12, 32, 56, -12, -38, 31, 11, -10,
4, -13, -7, 45, 60, 52, 70, -19, -65, -42, -79, -102, -29, 17, -39, -50,
32, 44, 19, 67, -9, -18, 23, 64, -2, -88, -81, -91, -86, -91, -42, -12,
-21, 47, 83, 75, 36, 1, -7, 25, 62, 13, 26, 69, 14, -64, -17, 20,
-9, 3, -6, -29, 1, 60, 47, 59, 48, -30, -50, -65, -105, -55, 16, 8,
-59, 10, 50, 16, 61, 54, -31, 8, 49, 68, -28, -85, -83, -91, -88, -91,
-31, -21, 25, 78, 76, 66, 29, -6, 18, 61, 47, 7, 64, 45, -52, -43,
29, 15, -4, -4, -22, -8, 40, 55, 51, 61, -2, -60, -47, -92, -85, -4,
26, -35, -59, 48, 26, 41, 69, -7, -7, 36, 72, 1, -90, -79, -95, -85,
-98, -55, -13, -20, 66, 78, 72, 36, 1, 20, 58, 52, 9, 28, 76, -37,
-61, 19, 25, -11, -2, -18, -15, 29, 58, 51, 56, 19, -44, -52, -61, -96,
-30, 23, -15, -65, -10, 46, 30, 73, 20, -31, 5, 66, 29, -74, -82, -81,
-92, -99, -76, -19, -19, 21, 69, 72, 47, 15, 8, 27, 63, 16, 13, 68,
44, -55, -5, 31, -6, -4, -2, -20, 22, 54, 56, 52, 49, -29, -58, -53,
-83, -87, -18, 1, -57, -32, 38, 26, 42, 49, -26, -14, 37, 77, -51, -85,
-73, -95, -88, -99, -31, -15, 9, 60, 73, 69, 22, 12, 20, 61, 57, 1,
52, 62, -28, -68, 9, 3, -15, 1, -16, -11, 30, 58, 52, 52, 23, -40,
-50, -73, -96, -35, 20, -16, -50, 22, 34, 32, 74, -7, -26, 17, 74, 35,
-76, -74, -91, -89, -96, -79, -24, -6, 47, 74, 77, 50, 17, 18, 50, 71,
19, 11, 67, 1, -62, -15, 26, -16, 6, -10, -29, 22, 53, 50, 54, 37,
-24, -63, -50, -100, -59, 16, -3, -54, -35, 41, 31, 64, 57, -12, 0, 60,
60, -48, -90, -78, -90, -87, -91, -43, -16, 6, 65, 76, 66, 33, 16, 37,
70, 30, 3, 51, 59, -46, -38, 20, -2, -19, 13, -32, 2, 48, 48, 54,
45, -9, -52, -50, -73, -101, 1, 12, -48, -51, 18, 38, 51, 68, 6, -22,
11, 70, -14, -93, -82, -91, -84, -89, -59, -16, 0, 37, 63, 70, 44, 23,
16, 50, 42, -3, 40, 70, 14, -49, 5, 11, -25, 2, 2, -29, 43, 47,
46, 62, 32, -45, -45, -62, -102, -61, 17, -34, -61, -1, 36, 25, 74, 26,
-19, 2, 50, 58, -80, -81, -85, -91, -83, -86, -21, -8, 30, 63, 73, 47,
32, 18, 35, 72, 28, 20, 63, 37, -24, -33, 7, -26, -14, 11, -29, -9,
55, 33, 58, 53, -21, -52, -41, -93, -82, 4, 17, -50, -22, 36, 29, 53,
76, -8, -6, 40, 70, -13, -91, -81, -96, -89, -89, -50, -18, 26, 61, 68,
64, 43, 16, 21, 70, 47, 1, 38, 45, -7, -31, -4, 0, -32, 7, -17,
-24, 47, 54, 48, 72, -3, -66, -42, -53, -93, -14, 28, -25, -62, -11, 38,
38, 70, 40, -12, 17, 72, 18, -87, -84, -81, -89, -93, -64, -26, -14, 36,
73, 65, 48, 36, 14, 55, 59, 6, 23, 63, 41, -25, -13, 5, -27, -21,
6, -33, 24, 58, 37, 62, 29, -60, -50, -38, -91, -79, 22, -4, -55, -31,
31, 35, 59, 56, 7, -14, 28, 48, -70, -90, -79, -98, -88, -71, -24, -22,
14, 70, 64, 52, 47, 21, 14, 64, 19, 8, 60, 62, 8, -27, 9, -21,
-36, 11, -15, -4, 58, 44, 46, 71, 11, -65, -40, -81, -92, -15, 26, -51,
-49, 15, 38, 39, 60, 25, -12, 9, 79, 22, -97, -71, -94, -91, -90, -60,
-17, -2, 58, 77, 60, 46, 31, 7, 50, 63, 11, 47, 68, 31, -19, -18,
3, -45, 3, 1, -42, 15, 55, 47, 70, 32, -58, -61, -63, -100, -36, 23,
-9, -52, -3, 30, 38, 55, 47, -5, -8, 63, 54, -66, -84, -91, -97, -91,
-76, -22, -13, 38, 73, 67, 47, 43, 12, 31, 68, 27, 10, 51, 49, -5,
-27, 5, -24, -46, 9, -36, -7, 52, 47, 64, 54, -37, -73, -37, -79, -64,
21, 8, -53, -47, 28, 38, 49, 53, 30, -9, 42, 72, -41, -92, -71, -91,
-90, -89, -31, -9, 1, 72, 70, 45, 35, 33, 12, 64, 38, 7, 47, 72,
38, -30, 1, -8, -51, -9, -30, -26, 44, 57, 50, 68, -14, -71, -45, -66,
-106, -42, 24, -41, -58, -3, 32, 43, 56, 46, 7, -12, 55, -1, -90, -78,
-87, -86, -93, -49, -4, -8, 36, 71, 61, 38, 29, 11, 28, 64, 9, 32,
67, 52, -4, -23, 4, -47, -29, -2, -42, 20, 63, 48, 68, 61, -36, -56,
-50, -98, -67, 22, 20, -66, -24, 31, 34, 43, 55, 16, -13, 38, 69, -34,
-77, -84, -92, -88, -97, -41, -7, 19, 59, 73, 61, 28, 21, 22, 58, 38,
5, 63, 58, 9, -20, 8, -10, -46, -1, -29, -40, 41, 55, 49, 71, -4,
-73, -48, -83, -94, -11, 37, -27, -46, 25, 35, 33, 56, 47, -8, 22, 75,
-4, -86, -73, -100, -84, -99, -63, -8, 10, 57, 71, 69, 46, 28, 24, 50,
50, 8, 27, 71, 21, -19, 6, 5, -54, -15, -14, -45, 12, 73, 49, 67,
24, -62, -56, -54, -99, -46, 30, -1, -70, -32, 42, 27, 50, 59, 17, -10,
71, 23, -84, -74, -81, -104, -92, -78, -21, -9, 27, 77, 69, 59, 33, 20,
33, 56, 19, 19, 62, 62, 8, 0, 17, -36, -50, -14, -44, -15, 59, 64,
48, 67, -48, -73, -52, -88, -97, -30, 23, -52, -59, 20, 40, 39, 62, 31,
-10, 23, 73, -62, -86, -75, -99, -88, -94, -31, -11, 8, 66, 75, 66, 43,
19, 27, 58, 46, 10, 53, 67, 17, -20, 15, -20, -61, -24, -20, -44, 39,
75, 52, 61, 30, -61, -56, -72, -99, -53, 20, -33, -68, -2, 42, 30, 46,
48, -4, 5, 72, 26, -79, -78, -98, -89, -95, -77, -6, -4, 52, 81, 76,
63, 24, 19, 48, 55, 10, 17, 73, 34, -16, 1, 29, -59, -43, -14, -42,
-25, 47, 59, 57, 44, -34, -72, -63, -97, -71, 3, 18, -39, -25, 30, 36,
36, 62, 40, -5, 64, 54, -61, -84, -79, -99, -94, -89, -28, -11, 42, 76,
74, 69, 43, 20, 38, 64, 24, 4, 54, 68, -3, -12, 30, -3, -67, -19,
-36, -38, 29, 68, 60, 53, -13, -67, -65, -80, -103, -15, 22, -22, -51, -11,
37, 24, 55, 56, -4, 4, 81, -29, -96, -73, -91, -93, -94, -47, -12, 2,
57, 78, 69, 51, 30, 17, 44, 43, 2, 37, 70, 33, -20, 24, 26, -53,
-56, -18, -49, 1, 63, 70, 66, 45, -54, -66, -75, -97, -71, 16, -1, -44,
-28, 31, 33, 36, 59, 11, -12, 56, 66, -91, -85, -85, -89, -87, -67, -19,
-8, 38, 75, 76, 56, 37, 22, 33, 69, 35, 15, 72, 53, -15, -24, 44,
-27, -68, -24, -32, -47, 50, 73, 67, 55, -3, -56, -75, -92, -82, -25, 18,
-40, -41, 21, 38, 19, 53, 30, -11, 39, 74, -22, -94, -84, -91, -84, -96,
-55, -13, 25, 72, 70, 64, 55, 25, 22, 65, 53, -4, 28, 69, 7, -26,
19, 39, -69, -39, -16, -49, -10, 62, 64, 62, 21, -47, -68, -75, -94, -53,
12, 3, -54, 8, 43, 13, 39, 69, 15, 27, 84, 11, -86, -85, -89, -85,
-93, -70, -25, -11, 67, 72, 68, 63, 48, 23, 52, 64, 2, 14, 72, 54,
-23, -1, 38, -16, -67, -14, -41, -34, 44, 72, 60, 37, -29, -66, -75, -90,
-71, -2, 17, -45, -46, 29, 20, 24, 66, 33, -8, 44, 41, -73, -92, -82,
-91, -93, -81, -28, -15, 29, 73, 72, 67, 49, 32, 16, 60, 22, 3, 62,
66, 18, -10, 26, 6, -56, -41, -13, -47, 21, 73, 65, 62, 23, -54, -71,
-92, -97, -61, 25, -24, -56, 15, 46, 13, 56, 44, -7, 24, 83, 14, -97,
-79, -92, -85, -93, -35, -7, 12, 65, 67, 67, 51, 41, 17, 43, 72, 13,
42, 71, 33, -8, -3, 20, -40, -50, -7, -36, -43, 65, 65, 65, 38, -33,
-64, -90, -97, -73, -8, 25, -65, -8, 48, 16, 22, 57, 5, 6, 71, 52,
-65, -94, -88, -90, -92, -83, -19, 0, 51, 71, 65, 66, 48, 22, 27, 67,
26, 1, 60, 48, 7, -4, 18, 10, -52, -14, -27, -58, 19, 71, 63, 62,
-8, -61, -71, -93, -84, -35, 26, -19, -67, 52, 35, 19, 49, 38, 3, 52,
73, -36, -100, -82, -93, -86, -91, -35, -7, 7, 66, 60, 67, 48, 32, 22,
69, 45, 0, 47, 77, 22, -10, 5, 18, -34, -43, -7, -65, -13, 70, 63,
62, 12, -56, -74, -87, -100, -54, 17, 10, -65, -17, 56, 14, 42, 44, 13,
12, 70, -2, -96, -81, -88, -87, -91, -51, -11, -5, 48, 67, 68, 56, 38,
22, 36, 67, 1, 31, 76, 60, 15, -8, 15, -22, -49, -1, -20, -42, 51,
70, 65, 59, -6, -72, -82, -97, -86, -34, 18, -48, -47, 41, 44, 25, 47,
22, 9, 47, 72, -30, -90, -86, -95, -87, -90, -19, -4, 43, 70, 63, 71,
36, 22, 34, 66, 35, 2, 71, 69, 34, -9, -8, -3, -48, -13, 1, -60,
-22, 74, 62, 64, 17, -58, -85, -92, -97, -57, 11, 5, -56, 24, 58, 24,
38, 41, -2, 28, 73, 0, -93, -77, -98, -86, -91, -61, -12, 27, 65, 59,
71, 64, 31, 28, 60, 48, 4, 32, 76, 49, 10, -9, 12, -18, -28, 15,
-48, -52, 43, 67, 66, 38, -37, -74, -80, -95, -73, -4, 14, -40, -39, 51,
37, 37, 49, 18, 2, 69, 30, -80, -97, -90, -91, -95, -83, -24, 0, 40,
69, 67, 72, 40, 10, 30, 57, 11, 20, 71, 76, 31, -2, 4, -5, -46,
-11, -24, -71, 14, 66, 54, 67, -20, -66, -79, -89, -93, -23, 19, -26, -50,
4, 48, 34, 48, 28, -5, 31, 75, -54, -95, -81, -92, -89, -96, -41, -3,
27, 65, 62, 77, 54, 8, 19, 67, 49, 10, 52, 69, 53, 18, -6, 2,
-40, -33, 22, -38, -18, 66, 51, 64, 45, -58, -74, -86, -92, -75, -5, -13,
-54, -15, 39, 44, 41, 35, 0, 15, 68, 33, -93, -79, -88, -85, -93, -87,
-2, 13, 53, 70, 71, 77, 21, 9, 59, 65, 12, 37, 70, 60, 29, 0,
-4, -31, -42, 19, -10, -81, 4, 55, 52, 63, -13, -66, -81, -93, -89, -28,
14, -35, -27, 21, 40, 44, 49, 26, 2, 59, 58, -47, -88, -84, -86, -87,
-98, -32, 8, 37, 72, 69, 77, 63, 16, 37, 71, 25, 7, 52, 60, 38,
11, -7, -11, -43, 4, 15, -73, -31, 64, 50, 69, 10, -59, -72, -82, -93,
-50, 13, -17, -45, -6, 35, 49, 51, 33, -1, 7, 73, -16, -87, -78, -92,
-80, -100, -57, 1, 4, 45, 65, 69, 70, 30, 5, 47, 49, 5, 35, 69,
57, 13, -2, -3, -35, -45, 17, -54, -59, 50, 60, 55, 31, -53, -76, -79,
-87, -93, 2, 0, -49, -22, 20, 39, 52, 41, 9, -3, 55, 16, -80, -79,
-88, -94, -87, -74, -5, 8, 35, 68, 67, 75, 46, 8, 28, 70, 18, 23,
61, 66, 37, 5, 12, -29, -59, 9, 19, -68, 26, 64, 51, 64, 7, -75,
-87, -83, -91, -59, 15, -41, -37, 8, 29, 47, 57, 19, -13, 30, 78, -9,
-85, -83, -98, -82, -96, -56, 13, 22, 61, 68, 67, 68, 14, 15, 63, 58,
18, 53, 68, 49, 15, 5, 6, -65, -14, 34, -47, -52, 45, 50, 66, 25,
-51, -80, -78, -85, -80, -3, 3, -48, 0, 20, 37, 57, 50, 15, 10, 73,
24, -86, -87, -102, -84, -86, -71, 0, 11, 45, 66, 65, 71, 51, 14, 52,
64, 25, 24, 59, 59, 24, 7, 8, -38, -64, 32, -21, -60, 18, 54, 64,
39, -38, -75, -85, -77, -92, -24, 15, -36, -34, 5, 28, 55, 61, 23, -10,
60, 52, -60, -92, -84, -98, -85, -83, -12, 13, 18, 57, 67, 72, 55, 18,
16, 61, 36, 22, 51, 70, 55, 11, 7, -30, -74, -17, 27, -57, 0, 48,
52, 72, -19, -70, -88, -80, -79, -85, 11, -18, -49, -12, 18, 33, 64, 35,
-6, 12, 70, -29, -95, -82, -97, -90, -90, -26, 20, 12, 51, 67, 63, 64,
31, 19, 43, 56, 24, 42, 64, 54, 25, 12, -15, -67, -38, 28, -15, -48,
42, 46, 68, 37, -41, -80, -81, -69, -82, -40, 14, -46, -30, 13, 24, 47,
64, -1, -1, 61, 57, -54, -90, -92, -88, -87, -84, -12, 1, 37, 66, 60,
74, 61, 21, 36, 58, 38, 24, 67, 61, 30, 13, 11, -24, -61, 14, 2,
-51, 6, 42, 64, 62, -26, -73, -82, -79, -82, -63, 4, -5, -50, 9, 30,
42, 67, 42, -11, 40, 67, -28, -93, -84, -95, -85, -95, -30, 9, 1, 64,
60, 68, 69, 35, 29, 58, 42, 20, 44, 71, 42, 24, 16, -11, -61, -47,
18, -38, -11, 46, 35, 71, 0, -72, -69, -79, -81, -73, -19, 6, -46, -38,
18, 32, 62, 53, 3, -3, 76, 4, -89, -83, -94, -93, -97, -54, 9, -5,
27, 69, 66, 74, 48, 16, 33, 56, 24, 38, 68, 59, 39, 22, -2, -49,
-59, 6, 8, -26, 38, 40, 56, 68, -61, -79, -78, -82, -78, -62, 6, -27,
-50, 3, 32, 39, 65, 18, -6, 45, 72, -78, -94, -87, -90, -86, -96, -5,
-10, 8, 63, 65, 66, 64, 22, 20, 59, 47, 27, 61, 65, 40, 31, 29,
-35, -63, -17, 8, -30, 25, 43, 45, 70, 11, -68, -81, -78, -75, -66, -24,
-5, -55, -20, 32, 39, 58, 42, 0, 28, 78, 10, -93, -86, -94, -84, -96,
-56, 3, -4, 57, 71, 60, 72, 33, 10, 50, 60, 23, 35, 75, 43, 27,
36, 0, -53, -31, 1, -19, -13, 38, 42, 64, 33, -47, -82, -86, -79, -77,
-36, -2, -31, -48, 17, 35, 55, 63, 25, 9, 68, 44, -76, -101, -85, -84,
-92, -77, -3, -10, 3, 75, 57, 66, 68, 32, 34, 67, 34, 22, 67, 69,
23, 41, 11, -47, -55, -21, -10, -22, 26, 49, 52, 51, -26, -83, -96, -80,
-75, -47, -6, -25, -46, -17, 18, 52, 65, 35, 3, 20, 66, -40, -103, -88,
-95, -83, -92, -17, 3, -19, 51, 78, 57, 72, 51, 18, 41, 50, 19, 53,
80, 39, 26, 23, -36, -55, -29, 1, -22, 13, 50, 54, 72, 34, -69, -94,
-92, -80, -78, -32, -18, -46, -23, 7, 30, 68, 44, 7, 8, 58, 47, -99,
-90, -93, -87, -90, -76, 12, -25, 26, 82, 60, 70, 63, 24, 27, 61, 47,
32, 73, 57, 25, 40, 14, -60, -42, -4, -12, -25, 44, 50, 66, 51, -23,
-71, -94, -80, -77, -50, -3, -28, -34, 4, 23, 54, 65, 14, 3, 43, 62,
-37, -104, -91, -94, -86, -87, -21, 0, 1, 69, 65, 54, 72, 41, 25, 55,
59, 28, 42, 71, 31, 36, 31, -28, -59, -9, 2, -27, 2, 45, 58, 58,
-7, -60, -87, -93, -73, -64, -9, -14, -53, -25, 14, 45, 72, 48, 11, 29,
71, 1, -95, -91, -92, -83, -86, -37, 6, -18, 17, 67, 58, 60, 63, 39,
44, 65, 35, 33, 71, 57, 31, 36, -15, -59, -45, 3, -22, -15, 33, 52,
66, 11, -52, -78, -92, -79, -75, -28, -6, -48, -39, 5, 35, 64, 54, 16,
3, 46, 26, -85, -97, -91, -95, -86, -59, 9, -9, -4, 51, 68, 66, 66,
48, 25, 48, 45, 27, 63, 66, 34, 44, -1, -48, -45, -8, 0, -34, 18,
52, 67, 60, -7, -73, -92, -82, -76, -68, -15, -35, -48, -7, 16, 40, 66,
28, -3, 31, 75, -7, -100, -89, -92, -81, -95, -41, -2, -15, 36, 67, 71,
66, 60, 28, 39, 61, 32, 54, 67, 32, 40, 43, -16, -54, -21, 4, -27,
-28, 46, 66, 69, 15, -49, -83, -87, -75, -69, -29, -11, -47, -15, 20, 32,
61, 66, 5, 15, 71, 24, -84, -91, -93, -80, -91, -62, 9, -12, 19, 60,
70, 68, 68, 35, 31, 63, 44, 31, 63, 36, 36, 46, -1, -46, -28, 5,
-15, -35, 8, 51, 75, 39, -33, -77, -92, -85, -80, -42, -12, -43, -55, 6,
28, 48, 65, 38, -3, 61, 50, -66, -100, -86, -91, -87, -75, -6, -4, -13,
49, 68, 72, 70, 65, 35, 60, 56, 34, 58, 53, 25, 53, 14, -40, -49,
-16, -4, -40, -14, 42, 69, 72, -10, -69, -91, -89, -82, -75, -11, -35, -60,
-21, 16, 46, 65, 55, 6, 9, 69, -41, -101, -85, -91, -84, -92, -19, 5,
-18, 16, 47, 71, 69, 64, 41, 41, 66, 37, 53, 61, 30, 39, 50, -28,
-46, -30, 7, -7, -31, 25, 56, 69, 47, -22, -86, -95, -86, -82, -45, -5,
-63, -36, 6, 31, 56, 58, 19, -2, 55, 49, -65, -88, -89, -88, -90, -73,
2, -18, 1, 38, 58, 68, 67, 48, 37, 65, 53, 37, 69, 39, 33, 55,
12, -39, -33, -2, 5, -41, -25, 54, 67, 62, 6, -61, -93, -86, -85, -58,
-4, -30, -51, -3, 25, 50, 63, 51, -4, 36, 67, -32, -101, -86, -92, -89,
-87, -16, 13, -10, 29, 50, 62, 67, 68, 36, 56, 55, 32, 55, 66, 25,
57, 34, -32, -44, -13, 11, -29, -39, 22, 55, 68, 31, -45, -87, -90, -86,
-74, -12, -11, -67, -45, 20, 43, 59, 55, 25, 2, 72, -1, -99, -95, -93,
-87, -93, -38, 18, -12, -1, 48, 65, 72, 71, 50, 39, 64, 36, 44, 76,
44, 24, 54, -12, -43, -35, -4, -20, -47, 8, 50, 64, 70, -26, -86, -93,
-84, -90, -59, 2, -57, -59, -4, 29, 51, 54, 39, 2, 35, 70, -86, -94,
-90, -96, -88, -92, 13, -4, -13, 28, 54, 71, 70, 55, 41, 61, 58, 34,
74, 57, 15, 47, 2, -42, -41, -10, 15, -30, -10, 43, 55, 69, 45, -36,
-100, -90, -90, -75, -9, -37, -63, -18, 22, 41, 47, 46, 3, 17, 75, -2,
-96, -83, -95, -86, -94, -38, 10, -17, 14, 51, 67, 65, 65, 38, 54, 66,
29, 35, 71, 24, 31, 47, -6, -47, -24, 13, -20, -48, 8, 53, 68, 64,
-10, -83, -97, -91, -89, -32, 2, -47, -36, 14, 38, 45, 50, 34, 11, 73,
35, -81, -91, -85, -88, -92, -63, 11, 3, 2, 42, 65, 61, 69, 59, 45,
68, 40, 28, 61, 59, 22, 46, 12, -37, -47, 9, -2, -49, -6, 48, 52,
71, 17, -69, -99, -87, -90, -60, -8, -30, -62, -25, 41, 45, 51, 41, 3,
22, 62, -56, -98, -85, -99, -90, -85, -9, 10, -11, 13, 60, 57, 61, 69,
43, 55, 47, 24, 54, 69, 33, 37, 28, -20, -53, -27, 23, -45, -25, 39,
45, 58, 68, -43, -100, -92, -87, -90, -19, -26, -56, -33, 19, 43, 48, 53,
13, 7, 74, 39, -97, -88, -101, -91, -93, -33, 12, -8, 0, 37, 61, 57,
73, 51, 47, 70, 39, 45, 73, 49, 21, 32, 2, -47, -41, 18, 7, -47,
24, 45, 55, 72, 25, -60, -96, -87, -94, -63, -23, -54, -45, 4, 39, 38,
48, 29, -7, 55, 65, -52, -99, -98, -94, -87, -82, -16, -2, -4, 32, 58,
54, 62, 61, 47, 68, 46, 23, 53, 54, 21, 29, 34, -11, -47, 1, 17,
-39, -30, 35, 51, 69, 41, -36, -90, -94, -90, -71, -32, -38, -55, -3, 31,
36, 41, 53, 13, 30, 86, -13, -96, -90, -101, -85, -95, -42, 11, -1, 21,
56, 59, 60, 74, 55, 70, 53, 27, 48, 70, 30, 21, 33, 2, -45, -40,
28, -16, -39, 17, 47, 53, 53, -10, -80, -99, -92, -82, -43, -37, -52, -34,
4, 38, 37, 50, 29, -14, 45, 23, -85, -89, -93, -94, -94, -58, 4, 5,
4, 33, 54, 46, 68, 63, 56, 72, 25, 40, 70, 58, 30, 27, 12, -32,
-48, 3, 22, -37, -1, 40, 60, 71, 45, -57, -97, -93, -90, -72, -38, -55,
-41, -5, 25, 40, 46, 39, -10, 18, 80, -7, -94, -85, -94, -91, -91, -10,
0, -3, 26, 55, 45, 59, 75, 57, 71, 51, 21, 64, 66, 38, 23, 21,
-18, -52, -16, 30, -12, -34, 29, 49, 68, 61, 1, -77, -94, -90, -86, -52,
-45, -51, -17, 20, 43, 38, 47, 5, -2, 73, 28, -83, -94, -92, -90, -96,
-60, -3, -2, 20, 54, 53, 38, 63, 66, 70, 55, 23, 37, 64, 48, 29,
25, 10, -26, -31, 28, 11, -31, 3, 33, 62, 69, 17, -61, -100, -90, -90,
-56, -43, -57, -36, 10, 42, 36, 30, 40, -8, 48, 57, -58, -96, -89, -89,
-91, -74, -15, 1, 2, 48, 58, 39, 58, 77, 66, 62, 25, 29, 64, 67,
32, 26, 15, -19, -47, -11, 24, -26, -10, 25, 41, 70, 35, -44, -95, -95,
-91, -63, -45, -61, -45, -12, 22, 40, 20, 42, 12, -13, 61, -28, -95, -90,
-94, -84, -84, -28, 3, -1, 23, 57, 37, 47, 72, 64, 73, 57, 20, 56,
70, 44, 28, 20, -14, -45, -29, 23, 9, -21, 18, 37, 63, 74, 24, -87,
-95, -84, -82, -54, -63, -55, -19, 15, 53, 34, 37, 38, -13, 40, 61, -51,
-94, -96, -87, -88, -75, 0, -7, 12, 51, 56, 41, 71, 67, 70, 67, 24,
45, 73, 51, 34, 35, 11, -41, -36, 11, 21, -17, -11, 29, 52, 72, 42,
-34, -99, -85, -84, -63, -50, -67, -28, 4, 47, 46, 13, 43, -6, 16, 74,
-21, -94, -93, -90, -87, -89, -28, 1, 2, 44, 61, 44, 49, 74, 65, 73,
42, 16, 51, 59, 33, 40, 24, -27, -48, -1, 19, -13, -19, 15, 34, 69,
58, -11, -85, -98, -82, -72, -50, -67, -59, -18, 35, 63, 23, 30, 37, -16,
71, 12, -80, -87, -98, -87, -100, -46, 3, -8, 12, 61, 47, 41, 72, 73,
66, 55, 16, 32, 71, 53, 35, 40, -9, -51, -36, 8, -1, -21, 9, 35,
47, 70, 13, -71, -96, -78, -80, -55, -59, -72, -32, 5, 45, 36, 17, 40,
-8, 12, 74, -62, -86, -95, -91, -88, -61, -3, -8, 3, 43, 60, 43, 65,
76, 67, 71, 21, 24, 67, 61, 23, 35, 13, -46, -44, -2, 23, -4, -2,
35, 39, 62, 62, -58, -96, -84, -77, -71, -53, -73, -50, -6, 32, 60, 23,
33, 7, -5, 70, 15, -80, -86, -93, -79, -89, -41, -4, -10, 31, 61, 53,
45, 78, 69, 70, 50, 15, 56, 68, 29, 23, 48, 4, -59, -13, 27, 9,
-17, 11, 38, 50, 67, 14, -72, -86, -74, -71, -54, -59, -74, -14, 25, 56,
36, 14, 34, -16, 53, 41, -62, -78, -96, -87, -91, -57, 0, -9, 8, 50,
58, 39, 57, 74, 65, 63, 21, 22, 71, 35, 17, 50, 22, -46, -55, 21,
20, -12, 6, 32, 36, 67, 37, -51, -99, -85, -71, -57, -59, -79, -53, -6,
52, 50, 14, 35, 10, -7, 65, -37, -82, -81, -89, -95, -73, 0, 3, -16,
20, 65, 40, 43, 72, 66, 66, 25, 10, 59, 69, 23, 44, 41, -31, -62,
-21, 25, -5, 1, 28, 33, 51, 58, -21, -96, -91, -70, -65, -60, -76, -64,
-23, 16, 55, 23, 30, 22, -16, 48, -11, -80, -83, -91, -84, -94, -23, 2,
-13, 8, 52, 65, 37, 69, 72, 70, 63, 6, 41, 73, 35, 15, 47, -6,
-56, -41, 19, 28, -7, 26, 29, 40, 68, 45, -79, -99, -73, -67, -58, -58,
-72, -34, 2, 43, 55, 27, 29, -13, 30, 54, -39, -78, -95, -85, -88, -79,
-15, -10, -6, 37, 67, 45, 42, 73, 69, 69, 28, 4, 74, 48, 13, 39,
33, -18, -55, 0, 43, 1, -2, 34, 34, 61, 57, -15, -89, -82, -65, -56,
-53, -74, -64, -2, 26, 55, 40, 35, 14, 15, 61, -19, -71, -78, -89, -86,
-88, -33, -1, -10, 22, 60, 51, 41, 67, 67, 72, 39, 3, 41, 74, 21,
30, 33, -3, -41, -48, 41, 16, -11, 29, 39, 52, 67, 9, -79, -100, -74,
-59, -51, -70, -73, -26, 1, 47, 47, 36, 21, -19, 64, 4, -68, -70, -96,
-86, -95, -53, -6, -5, 2, 29, 61, 37, 59, 72, 67, 56, 5, 25, 71,
48, 22, 32, 5, -28, -59, -14, 47, -10, 16, 42, 36, 58, 32, -60, -98,
-81, -70, -54, -64, -77, -37, -2, 19, 51, 39, 29, -11, 18, 64, -57, -68,
-94, -93, -83, -93, -16, -6, 0, 21, 54, 51, 50, 74, 67, 74, 43, 9,
64, 60, 23, 34, 25, -21, -47, -30, 40, 23, -10, 47, 42, 50, 69, 20,
-98, -88, -75, -61, -51, -74, -43, -11, 8, 46, 50, 43, -2, 2, 63, 0,
-65, -89, -97, -83, -99, -53, -11, 2, 17, 43, 57, 35, 74, 71, 70, 57,
6, 21, 64, 22, 33, 34, -10, -28, -42, 21, 37, -6, 14, 44, 46, 67,
40, -56, -102, -76, -71, -55, -64, -72, -34, 1, 38, 53, 42, 35, -8, 60,
22, -65, -64, -93, -85, -94, -66, -16, -10, 8, 36, 56, 38, 47, 77, 68,
68, 21, 9, 62, 54, 25, 38, -3, -27, -39, -27, 42, 4, 0, 40, 48,
58, 55, -30, -98, -86, -75, -60, -54, -71, -48, -11, 4, 56, 43, 37, 3,
-1, 45, -53, -67, -80, -101, -83, -78, -26, -12, 4, 25, 44, 39, 39, 72,
70, 73, 45, 7, 48, 67, 23, 35, 12, -30, -33, -31, 23, 38, -6, 28,
46, 45, 62, -4, -91, -90, -73, -74, -59, -68, -62, -18, -2, 28, 53, 33,
15, -12, 50, 23, -73, -72, -100, -81, -93, -71, -16, -5, 25, 39, 48, 29,
70, 77, 70, 79, 33, 31, 73, 38, 27, 44, -5, -33, -32, 9, 46, 9,
16, 41, 42, 59, 57, -29, -100, -75, -74, -68, -53, -68, -29, 1, 16, 54,
40, 24, -10, 33, 47, -57, -75, -98, -86, -88, -88, -32, -21, 19, 39, 47,
31, 30, 82, 71, 78, 50, 8, 47, 50, 19, 46, 14, -35, -33, -4, 45,
24, 0, 27, 41, 54, 68, 3, -87, -94, -67, -71, -55, -58, -64, -19, 10,
45, 45, 29, 16, 11, 60, -29, -82, -76, -97, -83, -93, -42, -22, -13, 28,
47, 35, 23, 63, 81, 78, 62, 10, 31, 75, 37, 39, 28, -33, -44, -31,
13, 36, 5, 24, 39, 41, 74, 30, -69, -102, -75, -69, -71, -58, -59, -28,
-2, 13, 47, 29, 26, -10, 26, -2, -86, -75, -91, -86, -89, -54, -15, -17,
16, 44, 44, 17, 44, 78, 71, 76, 21, 20, 78, 58, 23, 49, -17, -43,
-36, -3, 47, 6, 15, 37, 36, 60, 71, -40, -95, -81, -60, -73, -76, -64,
-35, -5, 4, 44, 24, 25, -1, 11, 65, -25, -77, -84, -94, -87, -96, -46,
-21, 3, 34, 53, 38, 28, 77, 76, 76, 60, 11, 66, 73, 23, 40, 30,
-31, -38, -15, 40, 35, 2, 30, 31, 51, 75, 29, -57, -86, -63, -65, -76,
-71, -58, -3, 1, 36, 43, 12, 4, -9, 60, 11, -83, -72, -93, -84, -95,
-57, -21, -18, 28, 49, 48, 8, 40, 82, 78, 72, 26, 25, 75, 30, 27,
45, -17, -49, -41, 23, 41, 6, 17, 28, 45, 76, 50, -30, -90, -83, -58,
-77, -78, -63, -24, -3, 30, 55, 15, 20, 1, 45, 42, -67, -78, -82, -89,
-96, -76, -23, -22, 4, 48, 53, 11, 21, 80, 76, 77, 44, 22, 62, 68,
21, 52, 8, -44, -46, -28, 47, 19, 17, 28, 20, 52, 62, -7, -81, -95,
-60, -59, -83, -71, -35, -3, 0, 62, 25, 14, 12, -6, 58, -46, -79, -71,
-91, -82, -98, -32, -21, -7, 35, 56, 24, 7, 69, 76, 67, 76, 25, 53,
73, 30, 23, 43, -38, -52, -42, 15, 48, 13, 33, 25, 43, 74, 50, -57,
-100, -70, -51, -77, -85, -51, -1, -2, 27, 63, 5, 13, -12, 40, 42, -68,
-71, -91, -85, -93, -78, -23, -13, 30, 59, 54, 12, 47, 80, 67, 74, 51,
29, 73, 41, 18, 52, 15, -50, -40, -5, 42, 25, 21, 31, 33, 71, 62,
6, -72, -86, -51, -70, -86, -84, -41, -4, 8, 66, 28, 7, -8, 25, 61,
-48, -83, -74, -89, -90, -87, -32, -27, 14, 58, 64, 19, 4, 63, 68, 75,
60, 33, 53, 68, 17, 49, 46, -35, -55, -20, 34, 37, 24, 37, 25, 64,
66, 33, -41, -102, -72, -61, -81, -91, -60, -5, -7, 58, 42, 5, 16, -15,
62, -21, -87, -73, -97, -86, -100, -50, -27, -25, 27, 60, 37, 7, 47, 76,
69, 66, 35, 43, 70, 37, 8, 54, -18, -57, -47, -15, 44, 25, 31, 20,
37, 70, 44, -15, -89, -76, -43, -61, -92, -73, -9, -10, 4, 64, 2, 11,
-8, 17, 58, -78, -66, -88, -92, -93, -95, -22, -29, 15, 50, 49, 5, 32,
78, 73, 74, 61, 39, 70, 52, 4, 40, 43, -54, -45, -31, 26, 43, 32,
29, 25, 63, 68, 35, -76, -93, -47, -52, -81, -95, -27, -4, -18, 56, 53,
0, 0, -1, 62, -6, -81, -78, -90, -81, -102, -53, -27, -1, 52, 62, 32,
5, 70, 75, 75, 67, 35, 41, 65, 8, 20, 52, -19, -51, -42, 8, 46,
24, 32, 25, 53, 70, 44, -9, -85, -57, -41, -72, -94, -76, 4, -12, 38,
69, 5, -2, -8, 50, 35, -59, -73, -91, -83, -99, -73, -26, -31, 39, 64,
42, 5, 34, 75, 71, 69, 43, 36, 65, 54, 5, 53, 12, -51, -51, -12,
39, 28, 28, 32, 32, 69, 49, 11, -71, -98, -49, -59, -91, -94, -35, -5,
16, 73, 28, -5, -7, -2, 57, -34, -67, -80, -98, -84, -88, -32, -32, -9,
44, 54, 16, 17, 70, 73, 71, 57, 37, 58, 67, 14, 16, 35, -44, -61,
-44, 3, 33, 24, 30, 30, 56, 64, 25, -46, -94, -60, -39, -59, -97, -56,
-7, -17, 34, 47, -6, -7, -9, 50, 44, -63, -72, -94, -80, -96, -42, -27,
-23, 29, 55, 47, 3, 54, 77, 66, 69, 54, 51, 73, 34, 8, 52, -28,
-65, -55, -11, 38, 24, 31, 35, 48, 61, 47, 13, -85, -71, -44, -57, -84,
-74, -16, -27, 8, 76, 28, -1, -19, 23, 60, -18, -56, -98, -89, -95, -89,
-28, -30, 16, 46, 54, 22, 4, 80, 67, 70, 64, 41, 60, 54, 14, 44,
34, -37, -63, -36, 31, 34, 14, 33, 46, 62, 48, 26, -29, -86, -49, -55,
-78, -98, -58, -21, -16, 67, 45, -1, 3, -3, 59, 5, -45, -60, -100, -87,
-94, -41, -25, -20, 36, 45, 40, 5, 39, 74, 70, 70, 43, 52, 72, 40,
32, 46, -19, -61, -63, 6, 40, 11, 23, 49, 59, 52, 33, -9, -74, -75,
-50, -70, -96, -73, -13, -27, 46, 69, 11, 5, -20, 13, 24, -45, -53, -95,
-90, -100, -58, -20, -30, 19, 38, 53, 14, 20, 73, 66, 73, 51, 46, 75,
53, 21, 58, 1, -60, -68, -50, 16, 18, 6, 41, 58, 58, 46, 7, -58,
-78, -49, -49, -93, -89, -25, -20, -21, 63, 25, 6, -15, -6, 59, 1, -48,
-82, -98, -81, -98, -27, -35, 4, 38, 45, 50, 8, 64, 70, 64, 75, 50,
68, 65, 22, 37, 47, -51, -67, -63, -7, 43, 16, 24, 64, 64, 42, 38,
2, -80, -56, -38, -63, -97, -43, -18, -28, 43, 71, 19, -15, -24, 48, 22,
-48, -47, -104, -86, -97, -69, -29, -6, 30, 41, 51, 9, 15, 78, 70, 78,
59, 47, 68, 39, 38, 59, 0, -61, -69, -38, 34, 33, 0, 31, 68, 40,
33, 23, -46, -80, -34, -58, -90, -88, -34, -28, 13, 79, 33, 5, -21, 28,
42, -46, -41, -75, -87, -83, -82, -34, -29, 4, 37, 54, 22, 1, 60, 73,
76, 67, 44, 65, 67, 29, 59, 22, -52, -69, -72, 12, 43, 4, 9, 60,
68, 29, 33, -27, -82, -51, -50, -86, -101, -51, -9, -26, 68, 54, 18, -6,
-29, 41, -26, -44, -58, -105, -83, -90, -41, -30, -15, 23, 42, 34, -4, 45,
76, 67, 79, 45, 53, 79, 39, 30, 49, -37, -66, -68, -51, 27, 22, 2,
47, 71, 47, 38, -3, -75, -61, -29, -58, -103, -73, -14, -22, -1, 69, 24,
2, -31, 21, 42, -41, -44, -94, -87, -88, -83, -31, -28, 16, 37, 51, 17,
26, 78, 70, 76, 66, 32, 78, 59, 19, 58, 34, -70, -66, -67, -1, 51,
12, 40, 73, 53, 37, 35, -20, -72, -30, -44, -89, -102, -27, -13, -18, 50,
62, 20, -26, 5, 50, -24, -44, -80, -93, -86, -90, -38, -37, 5, 30, 49,
36, -7, 41, 72, 69, 73, 39, 41, 77, 35, 54, 59, -33, -77, -67, -29,
42, 30, 2, 41, 62, 43, 41, 1, -63, -43, -39, -73, -101, -79, -22, -20,
35, 68, 30, 3, -23, 55, -1, -49, -42, -94, -81, -96, -52, -36, -36, 19,
41, 52, -4, 15, 78, 70, 72, 43, 33, 67, 65, 42, 70, 2, -83, -75,
-59, 17, 41, 9, 28, 67, 57, 48, 16, -54, -62, -30, -64, -101, -93, -33,
-14, -13, 68, 39, 15, -16, 2, 49, -49, -34, -79, -99, -87, -68, -24, -40,
9, 31, 39, 17, -5, 67, 75, 70, 75, 27, 61, 70, 35, 45, 40, -58,
-95, -68, -34, 18, 26, 25, 62, 62, 46, 59, -35, -76, -34, -29, -69, -103,
-59, -15, -19, 32, 64, 16, -9, -11, 47, -7, -46, -64, -107, -88, -99, -52,
-45, -16, 38, 35, 49, 9, 46, 77, 60, 79, 48, 42, 70, 40, 38, 69,
19, -92, -75, -42, 3, 34, 21, 50, 71, 56, 60, 29, -69, -40, -19, -49,
-86, -96, -24, -18, 15, 66, 38, 12, -10, 45, 15, -61, -41, -104, -85, -94,
-74, -33, -53, 37, 36, 48, 27, -6, 62, 63, 71, 56, 20, 59, 46, 27,
68, 52, -47, -96, -51, -12, 30, 32, 24, 51, 52, 61, 52, -33, -76, -18,
-40, -80, -98, -64, -20, -2, 64, 50, 9, -7, 6, 38, -55, -50, -69, -108,
-88, -83, -33, -55, -18, 40, 46, 42, -11, 31, 75, 65, 65, 20, 42, 78,
46, 59, 73, -13, -95, -84, -43, 22, 37, 27, 47, 57, 44, 69, -3, -78,
-47, -13, -69, -105, -79, -31, -26, 22, 64, 10, -8, 0, 55, -43, -63, -55,
-103, -87, -96, -42, -48, -39, 33, 40, 52, -4, 13, 71, 65, 73, 31, 30,
73, 59, 36, 66, 22, -77, -97, -63, -19, 29, 29, 41, 59, 42, 54, 30,
-68, -65, -17, -28, -76, -94, -38, -29, 2, 75, 48, -3, -9, 45, 39, -66,
-46, -89, -89, -90, -86, -35, -50, 13, 37, 56, 43, -10, 59, 68, 73, 69,
29, 62, 74, 45, 55, 75, 3, -97, -77, -36, 21, 33, 26, 66, 47, 45,
73, 6, -80, -32, -19, -54, -106, -84, -30, -19, 59, 62, 10, -8, 30, 59,
-44, -69, -56, -99, -85, -98, -46, -49, -41, 32, 44, 57, -1, 11, 69, 67,
70, 33, 29, 69, 56, 56, 79, 28, -67, -93, -54, 5, 38, 28, 46, 60,
37, 74, 39, -68, -74, -18, -37, -89, -96, -38, -32, 38, 76, 19, -10, 0,
65, -16, -76, -53, -95, -90, -98, -56, -38, -59, 5, 29, 65, 17, -7, 60,
69, 68, 44, 30, 63, 75, 59, 72, 56, -41, -100, -75, -40, 34, 34, 31,
61, 50, 68, 66, -45, -83, -33, -19, -73, -105, -50, -32, -25, 57, 35, -2,
-10, 43, 62, -72, -51, -88, -99, -87, -97, -23, -65, -19, 26, 41, 63, -15,
44, 71, 66, 70, 26, 50, 75, 70, 61, 71, -11, -93, -89, -52, -2, 37,
34, 58, 58, 42, 73, -9, -86, -49, -12, -34, -89, -66, -36, -32, 38, 66,
26, -17, 24, 69, -24, -73, -75, -100, -84, -100, -41, -29, -49, 21, 33, 58,
18, -6, 75, 65, 76, 47, 29, 73, 73, 68, 67, 52, -28, -101, -70, -18,
27, 33, 42, 64, 50, 66, 62, -30, -62, -19, -23, -78, -98, -49, -43, 24,
69, 42, 6, 0, 68, 1, -70, -55, -91, -83, -100, -59, -22, -76, -38, 33,
54, 38, -7, 38, 67, 71, 55, 27, 55, 74, 73, 75, 63, -9, -89, -92,
-35, 5, 30, 41, 52, 60, 64, 70, -2, -65, -42, -20, -62, -101, -57, -41,
-32, 69, 48, 23, -20, 14, 32, -62, -49, -75, -98, -83, -72, -12, -66, -67,
12, 36, 47, 6, 27, 67, 66, 63, 31, 45, 68, 73, 71, 67, 11, -80,
-99, -77, -30, 21, 35, 54, 55, 61, 69, 19, -50, -55, -24, -29, -95, -69,
-45, -35, 35, 64, 32, -16, -11, 63, -2, -55, -64, -101, -83, -104, -52, -39,
-81, -10, 36, 50, 28, 23, 63, 67, 76, 53, 43, 67, 74, 77, 67, 58,
-62, -96, -83, -50, 6, 24, 55, 53, 55, 71, 52, -30, -51, -29, -19, -63,
-93, -41, -40, 14, 63, 52, 4, -20, 50, 16, -65, -40, -101, -82, -98, -78,
-4, -55, -35, 28, 42, 28, 2, 58, 67, 73, 60, 30, 57, 74, 68, 63,
66, 16, -76, -90, -56, 0, 18, 32, 51, 50, 71, 60, 5, -49, -30, -14,
-50, -93, -73, -47, -8, 47, 51, 40, -8, 37, 35, -57, -43, -67, -100, -83,
-86, -10, -39, -83, -13, 39, 30, 2, 25, 70, 74, 71, 28, 42, 81, 74,
63, 58, 30, -54, -96, -75, -7, 19, 29, 50, 50, 68, 65, 20, -39, -45,
-17, -45, -86, -81, -53, -43, 12, 40, 40, 8, -9, 52, -50, -49, -60, -102,
-76, -96, -21, -20, -71, -32, 14, 33, -3, 17, 70, 71, 75, 45, 34, 69,
77, 65, 58, 40, -39, -95, -86, -39, 8, 24, 55, 50, 48, 74, 39, -33,
-49, -15, -20, -63, -87, -54, -44, 4, 48, 46, 24, -6, 49, 9, -64, -55,
-103, -84, -97, -76, -1, -59, -39, 10, 34, 17, 0, 57, 72, 72, 66, 31,
61, 79, 67, 59, 59, 23, -86, -92, -51, 1, 14, 42, 53, 38, 63, 76,
16, -45, -22, -7, -45, -102, -80, -51, -7, 42, 41, 41, -1, 47, 17, -62,
-46, -74, -90, -87, -87, -16, -16, -58, 3, 28, 14, -11, 23, 72, 70, 71,
38, 34, 65, 70, 62, 58, 35, -39, -91, -66, -12, 21, 23, 42, 48, 54,
76, 38, -37, -40, -5, -32, -90, -83, -45, -44, 36, 46, 39, 6, 19, 25,
-58, -44, -71, -105, -82, -90, -21, -8, -55, -32, 18, 10, -20, 12, 59, 66,
74, 43, 38, 63, 72, 68, 53, 40, -21, -82, -87, -55, 17, 24, 30, 47,
50, 73, 50, -15, -41, -19, 0, -85, -90, -50, -56, -5, 50, 41, 11, 17,
62, -19, -49, -60, -106, -80, -93, -77, -3, -46, -39, 10, 18, -18, 6, 55,
70, 71, 59, 38, 59, 71, 71, 55, 52, -8, -77, -87, -64, -9, 30, 27,
34, 49, 63, 64, 9, -43, -30, 4, -30, -91, -60, -57, -21, 38, 47, 9,
16, 68, -8, -67, -44, -111, -83, -91, -83, -11, -13, -45, 3, 20, -2, -16,
45, 74, 75, 66, 36, 39, 71, 74, 58, 51, 33, -35, -78, -59, -14, 14,
30, 32, 45, 69, 61, 47, 0, -40, 3, -18, -91, -77, -51, -29, 33, 47,
37, 3, 67, 1, -70, -52, -95, -99, -90, -90, -18, -2, -42, -25, 21, -6,
-25, 5, 58, 69, 60, 36, 33, 61, 78, 55, 51, 41, -21, -72, -81, -19,
12, 34, 36, 22, 72, 63, 52, 14, -40, -27, -17, -83, -76, -49, -49, 22,
49, 50, 8, 41, 56, -66, -52, -93, -105, -84, -97, -23, 5, -33, -33, 17,
0, -33, -9, 46, 70, 69, 40, 29, 56, 83, 71, 52, 38, -13, -59, -82,
-52, 6, 29, 37, 14, 52, 72, 43, 23, -31, -29, -5, -46, -80, -52, -42,
-7, 27, 52, 16, 45, 55, -48, -65, -86, -103, -88, -95, -62, -11, -30, -38,
19, 26, -24, -16, 46, 79, 75, 64, 34, 58, 84, 72, 57, 44, 14, -42,
-82, -64, -6, 19, 47, 13, 41, 71, 41, 34, -23, -25, -1, -42, -83, -54,
-42, -6, 19, 40, 41, 50, 63, -47, -72, -65, -102, -89, -96, -61, -14, -8,
-43, 10, 23, -17, -32, 1, 75, 69, 73, 48, 34, 68, 71, 57, 40, 8,
-21, -54, -69, -6, 27, 43, 31, 38, 69, 45, 28, 0, -29, 2, -42, -88,
-51, -35, -6, 11, 39, 48, 32, 72, -47, -72, -66, -99, -88, -90, -52, -14,
-12, -48, -26, 25, -15, -32, -13, 50, 72, 68, 48, 34, 64, 79, 68, 31,
7, -17, -47, -80, -9, 38, 54, 34, 15, 59, 42, 26, 9, -28, -6, 4,
-91, -55, -26, -13, 0, 34, 47, 39, 77, 7, -71, -73, -101, -87, -86, -60,
-24, -5, -37, -34, 11, 2, -25, -24, 31, 71, 65, 58, 36, 62, 79, 68,
49, 24, -19, -44, -69, -54, 4, 58, 34, 22, 66, 69, 32, 16, -26, -19,
-1, -68, -81, -19, -4, 2, 7, 42, 43, 79, 1, -74, -65, -92, -92, -90,
-52, -12, -2, -16, -28, -2, -11, -11, -19, 17, 69, 67, 58, 49, 58, 80,
66, 60, 27, -12, -27, -78, -53, 9, 47, 53, 23, 59, 65, 28, 28, 0,
-21, -1, -65, -83, -43, 9, 3, 1, 36, 34, 66, 0, -62, -66, -98, -96,
-88, -40, -7, 3, -21, -45, -7, -31, -5, -2, -19, 41, 64, 58, 48, 51,
81, 70, 62, 26, -9, -21, -67, -49, -1, 38, 57, 33, 36, 69, 27, 20,
9, -28, -10, -52, -80, -50, -3, 11, -6, 28, 35, 73, 46, -35, -74, -101,
-92, -92, -56, -13, 1, -17, -43, -10, -30, -5, 20, -18, 26, 64, 58, 50,
55, 83, 76, 66, 47, -7, -26, -62, -66, -21, 33, 44, 38, 36, 67, 52,
2, 13, -20, -21, -29, -66, -53, 1, 20, -9, 12, 32, 75, 34, -35, -52,
-92, -83, -90, -54, -12, 5, 4, -50, -9, -36, -49, 21, -11, 16, 48, 48,
56, 53, 74, 72, 69, 41, 5, -10, -64, -55, -12, 21, 29, 39, 46, 65,
48, 0, 11, -10, -29, -36, -53, -67, 14, 37, -12, 4, 31, 57, 29, -12,
-50, -96, -86, -95, -52, -9, 14, 10, -38, -12, -44, -44, 13, 9, 7, 31,
35, 47, 55, 66, 69, 79, 43, 11, -3, -53, -60, -13, 17, 14, 34, 62,
61, 38, -3, 8, 3, -25, -46, -50, -61, -20, 40, -3, 6, 30, 67, 41,
2, -46, -103, -89, -95, -67, -13, 19, 18, -23, -20, -42, -43, 9, 7, 17,
19, 16, 49, 61, 73, 70, 78, 53, 11, -3, -64, -68, -33, 18, 10, 33,
68, 60, 51, -7, 2, 6, -30, -55, -42, -66, -6, 47, 9, -3, 42, 68,
11, 4, -18, -97, -80, -100, -57, -11, 16, 34, -9, -15, -78, -67, 1, 1,
29, 13, 4, 32, 54, 76, 67, 79, 45, 8, 16, -63, -57, -25, 9, 10,
33, 69, 75, 50, -2, 5, -2, -38, -55, -39, -55, 5, 43, 9, 3, 24,
60, -7, 12, -37, -110, -81, -90, -46, -21, 22, 38, -3, -11, -88, -50, 11,
-7, 21, -4, -8, 21, 57, 83, 64, 80, 45, 15, 5, -44, -49, -22, 9,
-3, 10, 58, 72, 51, -5, 1, 7, -21, -45, -40, -49, -9, 39, 17, 17,
34, 48, 0, 10, -71, -105, -76, -96, -51, -20, 26, 37, 9, 8, -67, -36,
-5, -17, 39, 17, -27, 25, 51, 72, 74, 77, 59, 25, 3, -49, -60, -29,
6, -8, 15, 52, 61, 60, -5, 12, -5, -42, -39, -44, -41, 14, 38, 17,
16, 46, 22, 0, 20, -49, -107, -95, -96, -30, -18, -1, 39, 11, 8, -74,
-59, 6, -21, 38, 1, -26, 7, 34, 76, 72, 77, 62, 53, 27, -56, -53,
-23, 2, -16, 40, 47, 55, 63, -2, 6, -12, -52, -30, -44, -52, 27, 25,
12, 32, 58, 13, 14, 23, -89, -101, -79, -107, -26, -19, 4, 31, 19, -6,
-91, -41, 14, -29, 17, -7, -33, 6, 45, 72, 69, 76, 66, 65, 14, -54,
-47, -16, -5, -24, 32, 49, 55, 57, -5, 23, 0, -57, -18, -60, -35, 25,
31, 17, 55, 55, -35, 4, 38, -107, -85, -97, -94, -45, -16, 7, 22, 33,
4, -80, -19, 15, -26, 12, 15, -37, 16, 59, 58, 69, 82, 67, 67, -6,
-58, -46, -26, -20, -9, 54, 36, 31, 69, -1, 29, -22, -50, -6, -62, -2,
38, 17, 13, 55, 23, -62, 32, -6, -115, -86, -105, -80, -44, -7, 13, 12,
32, -15, -80, -46, 10, -19, 4, 6, -35, -2, 56, 51, 80, 81, 65, 71,
30, -58, -46, -20, -19, -7, 55, 20, 37, 58, 23, 27, -40, -29, -16, -71,
-25, 30, 13, 26, 79, 31, -55, 30, -67, -110, -84, -96, -91, -41, 3, 25,
21, 16, -25, -69, -28, 13, -12, -21, -8, -24, 21, 45, 37, 72, 73, 69,
71, 27, -39, -40, -20, -23, 14, 51, 31, 46, 44, 37, 15, -42, -20, -40,
-57, 5, 24, 17, 57, 64, -29, -22, 16, -62, -77, -87, -94, -83, -56, -13,
34, 12, 2, 0, -42, -15, 13, -14, -23, -20, -16, 36, 16, 35, 79, 70,
67, 71, 21, -31, -45, -36, -10, 22, 40, 34, 40, 38, 44, -17, -48, 14,
-31, -62, 21, 8, 27, 70, 54, -41, 7, -31, -76, -56, -74, -86, -81, -48,
-6, 26, 18, 5, 3, -28, -14, 9, -15, -26, -45, 4, 45, 1, 60, 79,
69, 78, 70, 37, -24, -45, -41, -2, 15, 36, 57, 31, 25, 45, -12, -21,
18, -48, -36, 26, -2, 43, 82, 3, -42, -4, -60, -57, -54, -62, -74, -84,
-39, 3, 20, -5, -4, -1, -13, 5, 7, -11, -23, -46, 30, 30, -11, 51,
81, 75, 76, 64, 34, -15, -38, -27, 5, 7, 30, 72, 21, 22, 20, -38,
-27, 23, -33, -16, 17, 7, 38, 48, -30, -29, -29, -47, -43, -43, -44, -83,
-82, -44, -5, -11, -21, 4, 2, -13, 15, 7, -19, -35, -37, 12, 3, 17,
60, 63, 75, 78, 55, 18, -6, -30, -27, 6, 1, 51, 68, 32, 15, -11,
-29, -8, 21, -3, -21, 18, 23, 52, 44, -11, -48, -34, -18, -48, -36, -23,
-88, -67, -33, -10, -23, -24, 8, -4, -9, 11, 20, -27, -43, -14, 7, -11,
17, 57, 54, 68, 73, 62, 21, 2, -23, -15, 6, -9, 64, 53, 21, 9,
-16, -24, -3, 24, 5, -12, 12, 33, 40, 10, -25, -42, -27, -29, -44, -19,
-44, -70, -58, -40, -19, -27, -17, 7, -6, 2, 21, 21, -15, -41, -3, -21,
-12, 41, 55, 48, 59, 69, 48, 23, 17, -25, -8, 0, 6, 48, 48, 17,
6, -25, -33, -1, 29, 1, -1, 15, 24, 25, -10, -35, -31, -9, -29, -39,
-22, -52, -46, -53, -59, -25, -32, -12, 15, -1, 1, 26, 11, -24, -24, -11,
-39, 5, 43, 47, 45, 48, 60, 39, 39, 11, -25, -6, 0, 23, 35, 20,
17, 12, -26, -29, 17, 35, 3, -2, 16, 13, 12, -8, -29, -7, -10, -35,
-24, -22, -49, -38, -69, -61, -19, -26, -17, 12, 0, 11, 22, 6, -23, -4,
-23, -39, 4, 30, 46, 49, 50, 45, 35, 50, -17, -21, 16, 2, 14, 18,
1, 27, 18, -21, -21, 20, 20, -7, 3, 22, -2, 5, -7, -20, -5, -9,
-32, -19, -39, -47, -39, -65, -39, -24, -28, -2, 5, 9, 15, 12, -2, -16,
-4, -39, -23, 14, 19, 37, 53, 47, 31, 43, 45, -13, 8, 26, 0, 12,
17, -3, 27, 14, -13, 1, 13, 2, 0, 13, 18, 6, -3, -2, -8, -8,
-18, -24, -16, -40, -38, -53, -63, -37, -37, -10, 7, -8, 10, 19, -3, -6,
-2, -7, -37, -25, 11, 11, 36, 49, 40, 26, 40, 21, -15, 8, 27, 2,
7, 5, 9, 17, 21, 4, 2, 5, -9, -3, 16, 18, 4, -7, 3, 1,
-16, -13, -14, -18, -28, -38, -67, -54, -30, -34, -12, 6, -7, 21, 13, -8,
-6, 1, -16, -31, -9, 6, 1, 34, 46, 34, 23, 26, 19, -7, 16, 30,
18, 8, 12, 17, 10, 11, 12, -4, -14, -7, -4, 10, 23, -7, -6, 2,
-15, -18, -8, -17, -16, -21, -38, -61, -57, -25, -22, -4, -2, -10, 15, 5,
-8, -7, -1, 1, -17, -5, -1, 2, 27, 42, 26, 23, 22, 8, 1, 20,
28, 20, 8, 7, 12, 13, 13, 3, -12, -14, -5, 1, 14, 24, 3, -11,
-6, -22, -14, -1, -6, -11, -23, -38, -61, -57, -29, -13, -9, -8, -4, 3,
3, -4, -13, -1, 10, -5, -13, -9, -2, 19, 31, 27, 23, 17, 11, 4,
10, 27, 18, 7, 16, 18, 11, 12, -6, -13, -4, 2, -1, 6, 20, 1,
-12, -14, -14, -4, -3, 0, -11, -24, -31, -64, -52, -13, -2, -16, -12, 0,
-7, -2, -2, -14, 10, 14, -2, -8, -12, -10, 17, 21, 24, 20, 14, 16,
1, 16, 32, 21, 11, 22, 12, 7, 6, -12, -17, 8, 5, 0, 10, 18,
0, -23, -24, -6, 1, -5, -3, -13, -29, -36, -50, -58, -6, -7, -23, -8,
2, -5, -5, -7, -10, 3, 19, 1, -5, -6, 3, 10, 13, 33, 15, 10,
26, 10, 18, 35, 19, 19, 25, 15, 2, -6, -13, -11, 0, 8, -2, 2,
4, 1, -13, -28, -9, 0, -1, -3, -10, -33, -39, -42, -43, -14, 2, -14,
-2, 2, -7, -13, 2, 6, 9, 19, 12, -8, -2, 7, 3, 14, 28, 12,
17, 25, 2, 7, 23, 7, 13, 17, 10, 2, -7, -9, -11, -2, 5, 1,
1, 1, 1, -3, -8, -3, 0, -2, -3, -3, -5, -7, -5, -4, -1, 0, };
|
51dcae297eab74b205649a038f885fecb97572df
|
50e95229b9a1161ac294137120aaba94c9eb06bc
|
/sources/ippcp/pcprsa_setpublickey.c
|
f3030deed526ea80e37a4d3d5307091cad592935
|
[
"Apache-2.0",
"Intel"
] |
permissive
|
intel/ipp-crypto
|
f0f05b87203705e82603db67bed5f8def13a5ee8
|
36e76e2388f3dd10cc440e213dfcf6ef59a0dfb8
|
refs/heads/develop
| 2023-09-04T08:15:06.851373
| 2023-07-27T12:47:12
| 2023-07-27T12:47:12
| 140,034,345
| 304
| 81
|
Apache-2.0
| 2023-08-30T17:18:36
| 2018-07-06T22:16:28
|
C
|
UTF-8
|
C
| false
| false
| 3,309
|
c
|
pcprsa_setpublickey.c
|
/*******************************************************************************
* Copyright (C) 2013 Intel Corporation
*
* 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.
*
*******************************************************************************/
/*
//
// Purpose:
// Cryptography Primitive.
// RSA Functions
//
// Contents:
// ippsRSA_SetPublicKey()
//
*/
#include "owncp.h"
#include "pcpbn.h"
#include "pcpngrsa.h"
/*F*
// Name: ippsRSA_SetPublicKey
//
// Purpose: Set up the RSA public key
//
// Returns: Reason:
// ippStsNullPtrErr NULL == pKey
// NULL == pPublicExp
// NULL == pKey
//
// ippStsContextMatchErr !BN_VALID_ID(pModulus)
// !BN_VALID_ID(pPublicExp)
// !RSA_PUB_KEY_VALID_ID()
//
// ippStsOutOfRangeErr 0 >= pModulus
// 0 >= pPublicExp
//
// ippStsSizeErr bitsize(pModulus) exceeds requested value
// bitsize(pPublicExp) exceeds requested value
//
// ippStsNoErr no error
//
// Parameters:
// pModulus pointer to modulus (N)
// pPublicExp pointer to public exponent (E)
// pKey pointer to the key context
*F*/
IPPFUN(IppStatus, ippsRSA_SetPublicKey,(const IppsBigNumState* pModulus,
const IppsBigNumState* pPublicExp,
IppsRSAPublicKeyState* pKey))
{
IPP_BAD_PTR1_RET(pKey);
IPP_BADARG_RET(!RSA_PUB_KEY_VALID_ID(pKey), ippStsContextMatchErr);
IPP_BAD_PTR1_RET(pModulus);
IPP_BADARG_RET(!BN_VALID_ID(pModulus), ippStsContextMatchErr);
IPP_BADARG_RET(!(0 < cpBN_tst(pModulus)), ippStsOutOfRangeErr);
IPP_BADARG_RET(BITSIZE_BNU(BN_NUMBER(pModulus), BN_SIZE(pModulus)) > RSA_PUB_KEY_MAXSIZE_N(pKey), ippStsSizeErr);
IPP_BAD_PTR1_RET(pPublicExp);
IPP_BADARG_RET(!BN_VALID_ID(pPublicExp), ippStsContextMatchErr);
IPP_BADARG_RET(!(0 < cpBN_tst(pPublicExp)), ippStsOutOfRangeErr);
IPP_BADARG_RET(BITSIZE_BNU(BN_NUMBER(pPublicExp), BN_SIZE(pPublicExp)) > RSA_PUB_KEY_MAXSIZE_E(pKey), ippStsSizeErr);
{
RSA_PUB_KEY_BITSIZE_N(pKey) = 0;
RSA_PUB_KEY_BITSIZE_E(pKey) = 0;
/* store E */
ZEXPAND_COPY_BNU(RSA_PUB_KEY_E(pKey), BITS_BNU_CHUNK(RSA_PUB_KEY_MAXSIZE_E(pKey)), BN_NUMBER(pPublicExp), BN_SIZE(pPublicExp));
/* setup montgomery engine */
gsModEngineInit(RSA_PUB_KEY_NMONT(pKey), (Ipp32u*)BN_NUMBER(pModulus), cpBN_bitsize(pModulus), MOD_ENGINE_RSA_POOL_SIZE, gsModArithRSA());
RSA_PUB_KEY_BITSIZE_N(pKey) = cpBN_bitsize(pModulus);
RSA_PUB_KEY_BITSIZE_E(pKey) = cpBN_bitsize(pPublicExp);
return ippStsNoErr;
}
}
|
d95d1d4a8f1bee17337be73b1fa55d550dc77b1c
|
a4c45cc2ce9fc90e0ba27f647136b3a69ce0bf09
|
/test/Common/Define_IdName.h
|
79f48ff0caa5543e7b8ba87d3083b5d4c670b994
|
[] |
no_license
|
AhJo53589/leetcode-cn
|
fd8cb65a2d86f25d2e32553f6b32dbfc9cb7bae7
|
7acba71548c41e276003682833e04b8fab8bc8f8
|
refs/heads/master
| 2023-01-29T19:35:13.816866
| 2023-01-15T03:21:37
| 2023-01-15T03:21:37
| 182,630,154
| 268
| 47
| null | null | null | null |
UTF-8
|
C
| false
| false
| 83,307
|
h
|
Define_IdName.h
|
#pragma once
#define SOLUTION_CPP_FOLDER_NAME_ID_417 pacific-atlantic-water-flow
#define SOLUTION_CPP_FOLDER_NAME_ID_427 construct-quad-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_515 find-largest-value-in-each-tree-row
#define SOLUTION_CPP_FOLDER_NAME_ID_729 my-calendar-i
#define SOLUTION_CPP_FOLDER_NAME_ID_883 projection-area-of-3d-shapes
#define SOLUTION_CPP_FOLDER_NAME_ID_2293 min-max-game
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 60 WInSav
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 60 WInSav
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 59 NfY1m5
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 58 De4qBB
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 57 ZbAuEH
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 56 6UEx57
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 55 PTXy4P
#define SOLUTION_CPP_FOLDER_NAME_ID_388 longest-absolute-file-path
#define SOLUTION_CPP_FOLDER_NAME_ID_396 rotate-function
#define SOLUTION_CPP_FOLDER_NAME_ID_821 shortest-distance-to-a-character
#define SOLUTION_CPP_FOLDER_NAME_ID_824 goat-latin
#define SOLUTION_CPP_FOLDER_NAME_ID_6041 intersection-of-multiple-arrays
#define SOLUTION_CPP_FOLDER_NAME_ID_6042 count-lattice-points-inside-a-circle
#define SOLUTION_CPP_FOLDER_NAME_ID_6043 count-number-of-rectangles-containing-each-point
#define SOLUTION_CPP_FOLDER_NAME_ID_6044 number-of-flowers-in-full-bloom
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 54 s5kipK
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 53 EJvmW4
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 52 QO5KpG
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 51 UEcfPD
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP 50 WHnhjV
#define SOLUTION_CPP_FOLDER_NAME_ID_1 two-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_2 add-two-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_3 longest-substring-without-repeating-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_4 median-of-two-sorted-arrays
#define SOLUTION_CPP_FOLDER_NAME_ID_5 longest-palindromic-substring
#define SOLUTION_CPP_FOLDER_NAME_ID_6 zigzag-conversion
#define SOLUTION_CPP_FOLDER_NAME_ID_7 reverse-integer
#define SOLUTION_CPP_FOLDER_NAME_ID_8 string-to-integer-atoi
#define SOLUTION_CPP_FOLDER_NAME_ID_9 palindrome-number
#define SOLUTION_CPP_FOLDER_NAME_ID_10 regular-expression-matching
#define SOLUTION_CPP_FOLDER_NAME_ID_11 container-with-most-water
#define SOLUTION_CPP_FOLDER_NAME_ID_12 integer-to-roman
#define SOLUTION_CPP_FOLDER_NAME_ID_13 roman-to-integer
#define SOLUTION_CPP_FOLDER_NAME_ID_14 longest-common-prefix
#define SOLUTION_CPP_FOLDER_NAME_ID_15 3sum
#define SOLUTION_CPP_FOLDER_NAME_ID_16 3sum-closest
#define SOLUTION_CPP_FOLDER_NAME_ID_17 letter-combinations-of-a-phone-number
#define SOLUTION_CPP_FOLDER_NAME_ID_18 4sum
#define SOLUTION_CPP_FOLDER_NAME_ID_19 remove-nth-node-from-end-of-list
#define SOLUTION_CPP_FOLDER_NAME_ID_20 valid-parentheses
#define SOLUTION_CPP_FOLDER_NAME_ID_21 merge-two-sorted-lists
#define SOLUTION_CPP_FOLDER_NAME_ID_22 generate-parentheses
#define SOLUTION_CPP_FOLDER_NAME_ID_23 merge-k-sorted-lists
#define SOLUTION_CPP_FOLDER_NAME_ID_24 swap-nodes-in-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_25 reverse-nodes-in-k-group
#define SOLUTION_CPP_FOLDER_NAME_ID_26 remove-duplicates-from-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_27 remove-element
#define SOLUTION_CPP_FOLDER_NAME_ID_28 implement-strstr
#define SOLUTION_CPP_FOLDER_NAME_ID_29 divide-two-integers
#define SOLUTION_CPP_FOLDER_NAME_ID_30 substring-with-concatenation-of-all-words
#define SOLUTION_CPP_FOLDER_NAME_ID_31 next-permutation
#define SOLUTION_CPP_FOLDER_NAME_ID_32 longest-valid-parentheses
#define SOLUTION_CPP_FOLDER_NAME_ID_33 search-in-rotated-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_34 find-first-and-last-position-of-element-in-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_35 search-insert-position
#define SOLUTION_CPP_FOLDER_NAME_ID_36 valid-sudoku
#define SOLUTION_CPP_FOLDER_NAME_ID_37 sudoku-solver
#define SOLUTION_CPP_FOLDER_NAME_ID_38 count-and-say
#define SOLUTION_CPP_FOLDER_NAME_ID_39 combination-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_40 combination-sum-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_41 first-missing-positive
#define SOLUTION_CPP_FOLDER_NAME_ID_42 trapping-rain-water
#define SOLUTION_CPP_FOLDER_NAME_ID_43 multiply-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_44 wildcard-matching
#define SOLUTION_CPP_FOLDER_NAME_ID_45 jump-game-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_46 permutations
#define SOLUTION_CPP_FOLDER_NAME_ID_47 permutations-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_48 rotate-image
#define SOLUTION_CPP_FOLDER_NAME_ID_49 group-anagrams
#define SOLUTION_CPP_FOLDER_NAME_ID_50 powx-n
#define SOLUTION_CPP_FOLDER_NAME_ID_51 n-queens
#define SOLUTION_CPP_FOLDER_NAME_ID_52 n-queens-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_53 maximum-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_54 spiral-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_55 jump-game
#define SOLUTION_CPP_FOLDER_NAME_ID_56 merge-intervals
#define SOLUTION_CPP_FOLDER_NAME_ID_57 insert-interval
#define SOLUTION_CPP_FOLDER_NAME_ID_58 length-of-last-word
#define SOLUTION_CPP_FOLDER_NAME_ID_59 spiral-matrix-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_60 permutation-sequence
#define SOLUTION_CPP_FOLDER_NAME_ID_61 rotate-list
#define SOLUTION_CPP_FOLDER_NAME_ID_62 unique-paths
#define SOLUTION_CPP_FOLDER_NAME_ID_63 unique-paths-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_64 minimum-path-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_65 valid-number
#define SOLUTION_CPP_FOLDER_NAME_ID_66 plus-one
#define SOLUTION_CPP_FOLDER_NAME_ID_67 add-binary
#define SOLUTION_CPP_FOLDER_NAME_ID_68 text-justification
#define SOLUTION_CPP_FOLDER_NAME_ID_69 sqrtx
#define SOLUTION_CPP_FOLDER_NAME_ID_70 climbing-stairs
#define SOLUTION_CPP_FOLDER_NAME_ID_71 simplify-path
#define SOLUTION_CPP_FOLDER_NAME_ID_72 edit-distance
#define SOLUTION_CPP_FOLDER_NAME_ID_73 set-matrix-zeroes
#define SOLUTION_CPP_FOLDER_NAME_ID_74 search-a-2d-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_75 sort-colors
#define SOLUTION_CPP_FOLDER_NAME_ID_76 minimum-window-substring
#define SOLUTION_CPP_FOLDER_NAME_ID_77 combinations
#define SOLUTION_CPP_FOLDER_NAME_ID_78 subsets
#define SOLUTION_CPP_FOLDER_NAME_ID_79 word-search
#define SOLUTION_CPP_FOLDER_NAME_ID_80 remove-duplicates-from-sorted-array-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_81 search-in-rotated-sorted-array-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_82 remove-duplicates-from-sorted-list-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_83 remove-duplicates-from-sorted-list
#define SOLUTION_CPP_FOLDER_NAME_ID_84 largest-rectangle-in-histogram
#define SOLUTION_CPP_FOLDER_NAME_ID_86 partition-list
#define SOLUTION_CPP_FOLDER_NAME_ID_88 merge-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_89 gray-code
#define SOLUTION_CPP_FOLDER_NAME_ID_90 subsets-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_91 decode-ways
#define SOLUTION_CPP_FOLDER_NAME_ID_92 reverse-linked-list-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_93 restore-ip-addresses
#define SOLUTION_CPP_FOLDER_NAME_ID_94 binary-tree-inorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_95 unique-binary-search-trees-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_96 unique-binary-search-trees
#define SOLUTION_CPP_FOLDER_NAME_ID_98 validate-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_99 recover-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_100 same-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_101 symmetric-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_102 binary-tree-level-order-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_103 binary-tree-zigzag-level-order-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_104 maximum-depth-of-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_105 construct-binary-tree-from-preorder-and-inorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_106 construct-binary-tree-from-inorder-and-postorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_107 binary-tree-level-order-traversal-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_108 convert-sorted-array-to-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_109 convert-sorted-list-to-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_110 balanced-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_111 minimum-depth-of-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_112 path-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_113 path-sum-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_114 flatten-binary-tree-to-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_115 distinct-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_116 populating-next-right-pointers-in-each-node
#define SOLUTION_CPP_FOLDER_NAME_ID_117 populating-next-right-pointers-in-each-node-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_118 pascals-triangle
#define SOLUTION_CPP_FOLDER_NAME_ID_119 pascals-triangle-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_120 triangle
#define SOLUTION_CPP_FOLDER_NAME_ID_121 best-time-to-buy-and-sell-stock
#define SOLUTION_CPP_FOLDER_NAME_ID_122 best-time-to-buy-and-sell-stock-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_123 best-time-to-buy-and-sell-stock-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_124 binary-tree-maximum-path-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_125 valid-palindrome
#define SOLUTION_CPP_FOLDER_NAME_ID_127 word-ladder
#define SOLUTION_CPP_FOLDER_NAME_ID_128 longest-consecutive-sequence
#define SOLUTION_CPP_FOLDER_NAME_ID_129 sum-root-to-leaf-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_130 surrounded-regions
#define SOLUTION_CPP_FOLDER_NAME_ID_131 palindrome-partitioning
#define SOLUTION_CPP_FOLDER_NAME_ID_132 palindrome-partitioning-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_133 clone-graph
#define SOLUTION_CPP_FOLDER_NAME_ID_134 gas-station
#define SOLUTION_CPP_FOLDER_NAME_ID_135 candy
#define SOLUTION_CPP_FOLDER_NAME_ID_136 single-number
#define SOLUTION_CPP_FOLDER_NAME_ID_137 single-number-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_138 copy-list-with-random-pointer
#define SOLUTION_CPP_FOLDER_NAME_ID_139 word-break
#define SOLUTION_CPP_FOLDER_NAME_ID_140 word-break-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_141 linked-list-cycle
#define SOLUTION_CPP_FOLDER_NAME_ID_142 linked-list-cycle-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_143 reorder-list
#define SOLUTION_CPP_FOLDER_NAME_ID_144 binary-tree-preorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_145 binary-tree-postorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_146 lru-cache
#define SOLUTION_CPP_FOLDER_NAME_ID_147 insertion-sort-list
#define SOLUTION_CPP_FOLDER_NAME_ID_148 sort-list
#define SOLUTION_CPP_FOLDER_NAME_ID_149 max-points-on-a-line
#define SOLUTION_CPP_FOLDER_NAME_ID_150 evaluate-reverse-polish-notation
#define SOLUTION_CPP_FOLDER_NAME_ID_151 reverse-words-in-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_152 maximum-product-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_153 find-minimum-in-rotated-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_154 find-minimum-in-rotated-sorted-array-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_155 min-stack
#define SOLUTION_CPP_FOLDER_NAME_ID_160 intersection-of-two-linked-lists
#define SOLUTION_CPP_FOLDER_NAME_ID_162 find-peak-element
#define SOLUTION_CPP_FOLDER_NAME_ID_165 compare-version-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_166 fraction-to-recurring-decimal
#define SOLUTION_CPP_FOLDER_NAME_ID_167 two-sum-ii-input-array-is-sorted
#define SOLUTION_CPP_FOLDER_NAME_ID_168 excel-sheet-column-title
#define SOLUTION_CPP_FOLDER_NAME_ID_169 majority-element
#define SOLUTION_CPP_FOLDER_NAME_ID_171 excel-sheet-column-number
#define SOLUTION_CPP_FOLDER_NAME_ID_172 factorial-trailing-zeroes
#define SOLUTION_CPP_FOLDER_NAME_ID_173 binary-search-tree-iterator
#define SOLUTION_CPP_FOLDER_NAME_ID_174 dungeon-game
#define SOLUTION_CPP_FOLDER_NAME_ID_179 largest-number
#define SOLUTION_CPP_FOLDER_NAME_ID_187 repeated-dna-sequences
#define SOLUTION_CPP_FOLDER_NAME_ID_188 best-time-to-buy-and-sell-stock-iv
#define SOLUTION_CPP_FOLDER_NAME_ID_189 rotate-array
#define SOLUTION_CPP_FOLDER_NAME_ID_189 rotate-array
#define SOLUTION_CPP_FOLDER_NAME_ID_190 reverse-bits
#define SOLUTION_CPP_FOLDER_NAME_ID_191 number-of-1-bits
#define SOLUTION_CPP_FOLDER_NAME_ID_198 house-robber
#define SOLUTION_CPP_FOLDER_NAME_ID_199 binary-tree-right-side-view
#define SOLUTION_CPP_FOLDER_NAME_ID_200 number-of-islands
#define SOLUTION_CPP_FOLDER_NAME_ID_201 bitwise-and-of-numbers-range
#define SOLUTION_CPP_FOLDER_NAME_ID_202 happy-number
#define SOLUTION_CPP_FOLDER_NAME_ID_203 remove-linked-list-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_204 count-primes
#define SOLUTION_CPP_FOLDER_NAME_ID_205 isomorphic-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_206 reverse-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_207 course-schedule
#define SOLUTION_CPP_FOLDER_NAME_ID_208 implement-trie-prefix-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_209 minimum-size-subarray-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_210 course-schedule-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_211 design-add-and-search-words-data-structure
#define SOLUTION_CPP_FOLDER_NAME_ID_212 word-search-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_213 house-robber-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_215 kth-largest-element-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_216 combination-sum-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_217 contains-duplicate
#define SOLUTION_CPP_FOLDER_NAME_ID_218 the-skyline-problem
#define SOLUTION_CPP_FOLDER_NAME_ID_219 contains-duplicate-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_220 contains-duplicate-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_221 maximal-square
#define SOLUTION_CPP_FOLDER_NAME_ID_222 count-complete-tree-nodes
#define SOLUTION_CPP_FOLDER_NAME_ID_224 basic-calculator
#define SOLUTION_CPP_FOLDER_NAME_ID_225 implement-stack-using-queues
#define SOLUTION_CPP_FOLDER_NAME_ID_226 invert-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_227 basic-calculator-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_228 summary-ranges
#define SOLUTION_CPP_FOLDER_NAME_ID_229 majority-element-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_230 kth-smallest-element-in-a-bst
#define SOLUTION_CPP_FOLDER_NAME_ID_231 power-of-two
#define SOLUTION_CPP_FOLDER_NAME_ID_232 implement-queue-using-stacks
#define SOLUTION_CPP_FOLDER_NAME_ID_234 palindrome-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_235 lowest-common-ancestor-of-a-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_236 lowest-common-ancestor-of-a-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_237 delete-node-in-a-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_238 product-of-array-except-self
#define SOLUTION_CPP_FOLDER_NAME_ID_239 sliding-window-maximum
#define SOLUTION_CPP_FOLDER_NAME_ID_240 search-a-2d-matrix-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_242 valid-anagram
#define SOLUTION_CPP_FOLDER_NAME_ID_249 group-shifted-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_257 binary-tree-paths
#define SOLUTION_CPP_FOLDER_NAME_ID_258 add-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_260 single-number-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_263 ugly-number
#define SOLUTION_CPP_FOLDER_NAME_ID_264 ugly-number-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_268 missing-number
#define SOLUTION_CPP_FOLDER_NAME_ID_278 first-bad-version
#define SOLUTION_CPP_FOLDER_NAME_ID_279 perfect-squares
#define SOLUTION_CPP_FOLDER_NAME_ID_283 move-zeroes
#define SOLUTION_CPP_FOLDER_NAME_ID_286 walls-and-gates
#define SOLUTION_CPP_FOLDER_NAME_ID_287 find-the-duplicate-number
#define SOLUTION_CPP_FOLDER_NAME_ID_289 game-of-life
#define SOLUTION_CPP_FOLDER_NAME_ID_290 word-pattern
#define SOLUTION_CPP_FOLDER_NAME_ID_292 nim-game
#define SOLUTION_CPP_FOLDER_NAME_ID_295 find-median-from-data-stream
#define SOLUTION_CPP_FOLDER_NAME_ID_297 serialize-and-deserialize-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_299 bulls-and-cows
#define SOLUTION_CPP_FOLDER_NAME_ID_300 longest-increasing-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_301 remove-invalid-parentheses
#define SOLUTION_CPP_FOLDER_NAME_ID_303 range-sum-query-immutable
#define SOLUTION_CPP_FOLDER_NAME_ID_304 range-sum-query-2d-immutable
#define SOLUTION_CPP_FOLDER_NAME_ID_309 best-time-to-buy-and-sell-stock-with-cooldown
#define SOLUTION_CPP_FOLDER_NAME_ID_312 burst-balloons
#define SOLUTION_CPP_FOLDER_NAME_ID_315 count-of-smaller-numbers-after-self
#define SOLUTION_CPP_FOLDER_NAME_ID_321 create-maximum-number
#define SOLUTION_CPP_FOLDER_NAME_ID_322 coin-change
#define SOLUTION_CPP_FOLDER_NAME_ID_324 wiggle-sort-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_326 power-of-three
#define SOLUTION_CPP_FOLDER_NAME_ID_328 odd-even-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_329 longest-increasing-path-in-a-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_331 verify-preorder-serialization-of-a-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_332 reconstruct-itinerary
#define SOLUTION_CPP_FOLDER_NAME_ID_334 increasing-triplet-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_336 palindrome-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_337 house-robber-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_338 counting-bits
#define SOLUTION_CPP_FOLDER_NAME_ID_341 flatten-nested-list-iterator
#define SOLUTION_CPP_FOLDER_NAME_ID_342 power-of-four
#define SOLUTION_CPP_FOLDER_NAME_ID_343 integer-break
#define SOLUTION_CPP_FOLDER_NAME_ID_344 reverse-string
#define SOLUTION_CPP_FOLDER_NAME_ID_345 reverse-vowels-of-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_347 top-k-frequent-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_349 intersection-of-two-arrays
#define SOLUTION_CPP_FOLDER_NAME_ID_350 intersection-of-two-arrays-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_354 russian-doll-envelopes
#define SOLUTION_CPP_FOLDER_NAME_ID_355 design-twitter
#define SOLUTION_CPP_FOLDER_NAME_ID_363 max-sum-of-rectangle-no-larger-than-k
#define SOLUTION_CPP_FOLDER_NAME_ID_365 water-and-jug-problem
#define SOLUTION_CPP_FOLDER_NAME_ID_367 valid-perfect-square
#define SOLUTION_CPP_FOLDER_NAME_ID_368 largest-divisible-subset
#define SOLUTION_CPP_FOLDER_NAME_ID_371 sum-of-two-integers
#define SOLUTION_CPP_FOLDER_NAME_ID_374 guess-number-higher-or-lower
#define SOLUTION_CPP_FOLDER_NAME_ID_375 guess-number-higher-or-lower-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_376 wiggle-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_377 combination-sum-iv
#define SOLUTION_CPP_FOLDER_NAME_ID_378 kth-smallest-element-in-a-sorted-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_380 insert-delete-getrandom-o1
#define SOLUTION_CPP_FOLDER_NAME_ID_381 insert-delete-getrandom-o1-duplicates-allowed
#define SOLUTION_CPP_FOLDER_NAME_ID_383 ransom-note
#define SOLUTION_CPP_FOLDER_NAME_ID_384 shuffle-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_387 first-unique-character-in-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_389 find-the-difference
#define SOLUTION_CPP_FOLDER_NAME_ID_390 elimination-game
#define SOLUTION_CPP_FOLDER_NAME_ID_392 is-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_393 utf-8-validation
#define SOLUTION_CPP_FOLDER_NAME_ID_394 decode-string
#define SOLUTION_CPP_FOLDER_NAME_ID_395 longest-substring-with-at-least-k-repeating-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_399 evaluate-division
#define SOLUTION_CPP_FOLDER_NAME_ID_401 binary-watch
#define SOLUTION_CPP_FOLDER_NAME_ID_402 remove-k-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_403 frog-jump
#define SOLUTION_CPP_FOLDER_NAME_ID_404 sum-of-left-leaves
#define SOLUTION_CPP_FOLDER_NAME_ID_405 convert-a-number-to-hexadecimal
#define SOLUTION_CPP_FOLDER_NAME_ID_406 queue-reconstruction-by-height
#define SOLUTION_CPP_FOLDER_NAME_ID_409 longest-palindrome
#define SOLUTION_CPP_FOLDER_NAME_ID_410 split-array-largest-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_412 fizz-buzz
#define SOLUTION_CPP_FOLDER_NAME_ID_413 arithmetic-slices
#define SOLUTION_CPP_FOLDER_NAME_ID_414 third-maximum-number
#define SOLUTION_CPP_FOLDER_NAME_ID_415 add-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_416 partition-equal-subset-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_419 battleships-in-a-board
#define SOLUTION_CPP_FOLDER_NAME_ID_423 reconstruct-original-digits-from-english
#define SOLUTION_CPP_FOLDER_NAME_ID_424 longest-repeating-character-replacement
#define SOLUTION_CPP_FOLDER_NAME_ID_429 n-ary-tree-level-order-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_430 flatten-a-multilevel-doubly-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_432 all-oone-data-structure
#define SOLUTION_CPP_FOLDER_NAME_ID_434 number-of-segments-in-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_435 non-overlapping-intervals
#define SOLUTION_CPP_FOLDER_NAME_ID_437 path-sum-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_441 arranging-coins
#define SOLUTION_CPP_FOLDER_NAME_ID_443 string-compression
#define SOLUTION_CPP_FOLDER_NAME_ID_445 add-two-numbers-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_447 number-of-boomerangs
#define SOLUTION_CPP_FOLDER_NAME_ID_448 find-all-numbers-disappeared-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_451 sort-characters-by-frequency
#define SOLUTION_CPP_FOLDER_NAME_ID_452 minimum-number-of-arrows-to-burst-balloons
#define SOLUTION_CPP_FOLDER_NAME_ID_453 minimum-moves-to-equal-array-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_459 repeated-substring-pattern
#define SOLUTION_CPP_FOLDER_NAME_ID_460 lfu-cache
#define SOLUTION_CPP_FOLDER_NAME_ID_466 count-the-repetitions
#define SOLUTION_CPP_FOLDER_NAME_ID_473 matchsticks-to-square
#define SOLUTION_CPP_FOLDER_NAME_ID_475 heaters
#define SOLUTION_CPP_FOLDER_NAME_ID_476 number-complement
#define SOLUTION_CPP_FOLDER_NAME_ID_480 sliding-window-median
#define SOLUTION_CPP_FOLDER_NAME_ID_481 magical-string
#define SOLUTION_CPP_FOLDER_NAME_ID_482 license-key-formatting
#define SOLUTION_CPP_FOLDER_NAME_ID_486 predict-the-winner
#define SOLUTION_CPP_FOLDER_NAME_ID_488 zuma-game
#define SOLUTION_CPP_FOLDER_NAME_ID_450 delete-node-in-a-bst
#define SOLUTION_CPP_FOLDER_NAME_ID_451 sort-characters-by-frequency
#define SOLUTION_CPP_FOLDER_NAME_ID_454 4sum-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_455 assign-cookies
#define SOLUTION_CPP_FOLDER_NAME_ID_457 circular-array-loop
#define SOLUTION_CPP_FOLDER_NAME_ID_461 hamming-distance
#define SOLUTION_CPP_FOLDER_NAME_ID_463 island-perimeter
#define SOLUTION_CPP_FOLDER_NAME_ID_485 max-consecutive-ones
#define SOLUTION_CPP_FOLDER_NAME_ID_491 increasing-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_493 reverse-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_494 target-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_495 teemo-attacking
#define SOLUTION_CPP_FOLDER_NAME_ID_496 next-greater-element-i
#define SOLUTION_CPP_FOLDER_NAME_ID_498 diagonal-traverse
#define SOLUTION_CPP_FOLDER_NAME_ID_500 keyboard-row
#define SOLUTION_CPP_FOLDER_NAME_ID_501 find-mode-in-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_503 next-greater-element-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_504 base-7
#define SOLUTION_CPP_FOLDER_NAME_ID_506 relative-ranks
#define SOLUTION_CPP_FOLDER_NAME_ID_509 fibonacci-number
#define SOLUTION_CPP_FOLDER_NAME_ID_514 freedom-trail
#define SOLUTION_CPP_FOLDER_NAME_ID_516 longest-palindromic-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_520 detect-capital
#define SOLUTION_CPP_FOLDER_NAME_ID_521 longest-uncommon-subsequence-i
#define SOLUTION_CPP_FOLDER_NAME_ID_523 continuous-subarray-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_524 longest-word-in-dictionary-through-deleting
#define SOLUTION_CPP_FOLDER_NAME_ID_525 contiguous-array
#define SOLUTION_CPP_FOLDER_NAME_ID_529 minesweeper
#define SOLUTION_CPP_FOLDER_NAME_ID_530 minimum-absolute-difference-in-bst
#define SOLUTION_CPP_FOLDER_NAME_ID_538 convert-bst-to-greater-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_539 minimum-time-difference
#define SOLUTION_CPP_FOLDER_NAME_ID_540 single-element-in-a-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_541 reverse-string-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_541 reverse-string-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_542 01-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_543 diameter-of-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_547 friend-circles
#define SOLUTION_CPP_FOLDER_NAME_ID_551 student-attendance-record-i
#define SOLUTION_CPP_FOLDER_NAME_ID_554 brick-wall
#define SOLUTION_CPP_FOLDER_NAME_ID_556 next-greater-element-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_557 reverse-words-in-a-string-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_559 maximum-depth-of-n-ary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_561 array-partition-i
#define SOLUTION_CPP_FOLDER_NAME_ID_563 binary-tree-tilt
#define SOLUTION_CPP_FOLDER_NAME_ID_566 reshape-the-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_567 permutation-in-string
#define SOLUTION_CPP_FOLDER_NAME_ID_572 subtree-of-another-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_575 distribute-candies
#define SOLUTION_CPP_FOLDER_NAME_ID_576 out-of-boundary-paths
#define SOLUTION_CPP_FOLDER_NAME_ID_581 shortest-unsorted-continuous-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_589 n-ary-tree-preorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_590 n-ary-tree-postorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_594 longest-harmonious-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_598 range-addition-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_599 minimum-index-sum-of-two-lists
#define SOLUTION_CPP_FOLDER_NAME_ID_605 can-place-flowers
#define SOLUTION_CPP_FOLDER_NAME_ID_611 valid-triangle-number
#define SOLUTION_CPP_FOLDER_NAME_ID_617 merge-two-binary-trees
#define SOLUTION_CPP_FOLDER_NAME_ID_621 task-scheduler
#define SOLUTION_CPP_FOLDER_NAME_ID_622 design-circular-queue
#define SOLUTION_CPP_FOLDER_NAME_ID_628 maximum-product-of-three-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_637 average-of-levels-in-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_641 design-circular-deque
#define SOLUTION_CPP_FOLDER_NAME_ID_643 maximum-average-subarray-i
#define SOLUTION_CPP_FOLDER_NAME_ID_647 palindromic-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_648 replace-words
#define SOLUTION_CPP_FOLDER_NAME_ID_649 dota2-senate
#define SOLUTION_CPP_FOLDER_NAME_ID_652 find-duplicate-subtrees
#define SOLUTION_CPP_FOLDER_NAME_ID_657 robot-return-to-origin
#define SOLUTION_CPP_FOLDER_NAME_ID_658 find-k-closest-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_659 split-array-into-consecutive-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_664 strange-printer
#define SOLUTION_CPP_FOLDER_NAME_ID_665 non-decreasing-array
#define SOLUTION_CPP_FOLDER_NAME_ID_670 maximum-swap
#define SOLUTION_CPP_FOLDER_NAME_ID_671 second-minimum-node-in-a-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_674 longest-continuous-increasing-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_677 map-sum-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_680 valid-palindrome-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_684 redundant-connection
#define SOLUTION_CPP_FOLDER_NAME_ID_687 longest-univalue-path
#define SOLUTION_CPP_FOLDER_NAME_ID_690 employee-importance
#define SOLUTION_CPP_FOLDER_NAME_ID_692 top-k-frequent-words
#define SOLUTION_CPP_FOLDER_NAME_ID_693 binary-number-with-alternating-bits
#define SOLUTION_CPP_FOLDER_NAME_ID_695 max-area-of-island
#define SOLUTION_CPP_FOLDER_NAME_ID_696 count-binary-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_697 degree-of-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_698 partition-to-k-equal-sum-subsets
#define SOLUTION_CPP_FOLDER_NAME_ID_700 search-in-a-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_701 insert-into-a-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_703 kth-largest-element-in-a-stream
#define SOLUTION_CPP_FOLDER_NAME_ID_704 binary-search
#define SOLUTION_CPP_FOLDER_NAME_ID_705 design-hashset
#define SOLUTION_CPP_FOLDER_NAME_ID_706 design-hashmap
#define SOLUTION_CPP_FOLDER_NAME_ID_707 design-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_709 to-lower-case
#define SOLUTION_CPP_FOLDER_NAME_ID_714 best-time-to-buy-and-sell-stock-with-transaction-fee
#define SOLUTION_CPP_FOLDER_NAME_ID_718 maximum-length-of-repeated-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_719 find-k-th-smallest-pair-distance
#define SOLUTION_CPP_FOLDER_NAME_ID_721 accounts-merge
#define SOLUTION_CPP_FOLDER_NAME_ID_724 find-pivot-index
#define SOLUTION_CPP_FOLDER_NAME_ID_733 flood-fill
#define SOLUTION_CPP_FOLDER_NAME_ID_738 monotone-increasing-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_739 daily-temperatures
#define SOLUTION_CPP_FOLDER_NAME_ID_740 delete-and-earn
#define SOLUTION_CPP_FOLDER_NAME_ID_743 network-delay-time
#define SOLUTION_CPP_FOLDER_NAME_ID_744 find-smallest-letter-greater-than-target
#define SOLUTION_CPP_FOLDER_NAME_ID_746 min-cost-climbing-stairs
#define SOLUTION_CPP_FOLDER_NAME_ID_747 largest-number-at-least-twice-of-others
#define SOLUTION_CPP_FOLDER_NAME_ID_748 shortest-completing-word
#define SOLUTION_CPP_FOLDER_NAME_ID_752 open-the-lock
#define SOLUTION_CPP_FOLDER_NAME_ID_763 partition-labels
#define SOLUTION_CPP_FOLDER_NAME_ID_765 couples-holding-hands
#define SOLUTION_CPP_FOLDER_NAME_ID_766 toeplitz-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_767 reorganize-string
#define SOLUTION_CPP_FOLDER_NAME_ID_771 jewels-and-stones
#define SOLUTION_CPP_FOLDER_NAME_ID_773 sliding-puzzle
#define SOLUTION_CPP_FOLDER_NAME_ID_778 swim-in-rising-water
#define SOLUTION_CPP_FOLDER_NAME_ID_779 k-th-symbol-in-grammar
#define SOLUTION_CPP_FOLDER_NAME_ID_781 rabbits-in-forest
#define SOLUTION_CPP_FOLDER_NAME_ID_783 minimum-distance-between-bst-nodes
#define SOLUTION_CPP_FOLDER_NAME_ID_787 cheapest-flights-within-k-stops
#define SOLUTION_CPP_FOLDER_NAME_ID_788 rotated-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_794 valid-tic-tac-toe-state
#define SOLUTION_CPP_FOLDER_NAME_ID_797 all-paths-from-source-to-target
#define SOLUTION_CPP_FOLDER_NAME_ID_807 max-increase-to-keep-city-skyline
#define SOLUTION_CPP_FOLDER_NAME_ID_810 chalkboard-xor-game
#define SOLUTION_CPP_FOLDER_NAME_ID_819 most-common-word
#define SOLUTION_CPP_FOLDER_NAME_ID_820 short-encoding-of-words
#define SOLUTION_CPP_FOLDER_NAME_ID_830 positions-of-large-groups
#define SOLUTION_CPP_FOLDER_NAME_ID_832 flipping-an-image
#define SOLUTION_CPP_FOLDER_NAME_ID_836 rectangle-overlap
#define SOLUTION_CPP_FOLDER_NAME_ID_839 similar-string-groups
#define SOLUTION_CPP_FOLDER_NAME_ID_841 keys-and-rooms
#define SOLUTION_CPP_FOLDER_NAME_ID_842 split-array-into-fibonacci-sequence
#define SOLUTION_CPP_FOLDER_NAME_ID_844 backspace-string-compare
#define SOLUTION_CPP_FOLDER_NAME_ID_845 longest-mountain-in-array
#define SOLUTION_CPP_FOLDER_NAME_ID_846 hand-of-straights
#define SOLUTION_CPP_FOLDER_NAME_ID_851 loud-and-rich
#define SOLUTION_CPP_FOLDER_NAME_ID_852 peak-index-in-a-mountain-array
#define SOLUTION_CPP_FOLDER_NAME_ID_859 buddy-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_860 lemonade-change
#define SOLUTION_CPP_FOLDER_NAME_ID_861 score-after-flipping-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_863 all-nodes-distance-k-in-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_867 transpose-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_868 binary-gap
#define SOLUTION_CPP_FOLDER_NAME_ID_872 leaf-similar-trees
#define SOLUTION_CPP_FOLDER_NAME_ID_874 walking-robot-simulation
#define SOLUTION_CPP_FOLDER_NAME_ID_876 middle-of-the-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_881 boats-to-save-people
#define SOLUTION_CPP_FOLDER_NAME_ID_887 super-egg-drop
#define SOLUTION_CPP_FOLDER_NAME_ID_888 fair-candy-swap
#define SOLUTION_CPP_FOLDER_NAME_ID_892 surface-area-of-3d-shapes
#define SOLUTION_CPP_FOLDER_NAME_ID_897 increasing-order-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_905 sort-array-by-parity
#define SOLUTION_CPP_FOLDER_NAME_ID_911 online-election
#define SOLUTION_CPP_FOLDER_NAME_ID_912 sort-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_914 x-of-a-kind-in-a-deck-of-cards
#define SOLUTION_CPP_FOLDER_NAME_ID_918 maximum-sum-circular-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_922 sort-array-by-parity-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_925 long-pressed-name
#define SOLUTION_CPP_FOLDER_NAME_ID_930 binary-subarrays-with-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_933 number-of-recent-calls
#define SOLUTION_CPP_FOLDER_NAME_ID_938 range-sum-of-bst
#define SOLUTION_CPP_FOLDER_NAME_ID_945 minimum-increment-to-make-array-unique
#define SOLUTION_CPP_FOLDER_NAME_ID_946 validate-stack-sequences
#define SOLUTION_CPP_FOLDER_NAME_ID_947 most-stones-removed-with-same-row-or-column
#define SOLUTION_CPP_FOLDER_NAME_ID_949 largest-time-for-given-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_953 verifying-an-alien-dictionary
#define SOLUTION_CPP_FOLDER_NAME_ID_956 tallest-billboard
#define SOLUTION_CPP_FOLDER_NAME_ID_959 regions-cut-by-slashes
#define SOLUTION_CPP_FOLDER_NAME_ID_968 binary-tree-cameras
#define SOLUTION_CPP_FOLDER_NAME_ID_973 k-closest-points-to-origin
#define SOLUTION_CPP_FOLDER_NAME_ID_974 subarray-sums-divisible-by-k
#define SOLUTION_CPP_FOLDER_NAME_ID_975 odd-even-jump
#define SOLUTION_CPP_FOLDER_NAME_ID_976 largest-perimeter-triangle
#define SOLUTION_CPP_FOLDER_NAME_ID_977 squares-of-a-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_978 longest-turbulent-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_989 add-to-array-form-of-integer
#define SOLUTION_CPP_FOLDER_NAME_ID_990 satisfiability-of-equality-equations
#define SOLUTION_CPP_FOLDER_NAME_ID_992 subarrays-with-k-different-integers
#define SOLUTION_CPP_FOLDER_NAME_ID_993 cousins-in-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_994 rotting-oranges
#define SOLUTION_CPP_FOLDER_NAME_ID_995 minimum-number-of-k-consecutive-bit-flips
#define SOLUTION_CPP_FOLDER_NAME_ID_997 find-the-town-judge
#define SOLUTION_CPP_FOLDER_NAME_ID_999 available-captures-for-rook
#define SOLUTION_CPP_FOLDER_NAME_ID_1002 find-common-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_1004 max-consecutive-ones-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_1011 capacity-to-ship-packages-within-d-days
#define SOLUTION_CPP_FOLDER_NAME_ID_1013 partition-array-into-three-parts-with-equal-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1014 best-sightseeing-pair
#define SOLUTION_CPP_FOLDER_NAME_ID_1018 binary-prefix-divisible-by-5
#define SOLUTION_CPP_FOLDER_NAME_ID_1024 video-stitching
#define SOLUTION_CPP_FOLDER_NAME_ID_1025 divisor-game
#define SOLUTION_CPP_FOLDER_NAME_ID_1028 recover-a-tree-from-preorder-traversal
#define SOLUTION_CPP_FOLDER_NAME_ID_1034 coloring-a-border
#define SOLUTION_CPP_FOLDER_NAME_ID_1035 uncrossed-lines
#define SOLUTION_CPP_FOLDER_NAME_ID_1037 valid-boomerang
#define SOLUTION_CPP_FOLDER_NAME_ID_1038 binary-search-tree-to-greater-sum-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1046 last-stone-weight
#define SOLUTION_CPP_FOLDER_NAME_ID_1047 remove-all-adjacent-duplicates-in-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1052 grumpy-bookstore-owner
#define SOLUTION_CPP_FOLDER_NAME_ID_1071 greatest-common-divisor-of-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_1078 occurrences-after-bigram
#define SOLUTION_CPP_FOLDER_NAME_ID_1095 find-in-mountain-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1103 distribute-candies-to-people
#define SOLUTION_CPP_FOLDER_NAME_ID_1104 path-in-zigzag-labelled-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1109 corporate-flight-bookings
#define SOLUTION_CPP_FOLDER_NAME_ID_1111 maximum-nesting-depth-of-two-valid-parentheses-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_1128 number-of-equivalent-domino-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_1137 n-th-tribonacci-number
#define SOLUTION_CPP_FOLDER_NAME_ID_1143 longest-common-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_1146 snapshot-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1154 day-of-the-year
#define SOLUTION_CPP_FOLDER_NAME_ID_1160 find-words-that-can-be-formed-by-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_1162 as-far-from-land-as-possible
#define SOLUTION_CPP_FOLDER_NAME_ID_1171 remove-zero-sum-consecutive-nodes-from-linked-list
#define SOLUTION_CPP_FOLDER_NAME_ID_1190 reverse-substrings-between-each-pair-of-parentheses
#define SOLUTION_CPP_FOLDER_NAME_ID_1202 smallest-string-with-swaps
#define SOLUTION_CPP_FOLDER_NAME_ID_1207 unique-number-of-occurrences
#define SOLUTION_CPP_FOLDER_NAME_ID_1208 get-equal-substrings-within-budget
#define SOLUTION_CPP_FOLDER_NAME_ID_1209 remove-all-adjacent-duplicates-in-string-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_1210 minimum-moves-to-reach-target-with-rotations
#define SOLUTION_CPP_FOLDER_NAME_ID_1217 play-with-chips
#define SOLUTION_CPP_FOLDER_NAME_ID_1218 longest-arithmetic-subsequence-of-given-difference
#define SOLUTION_CPP_FOLDER_NAME_ID_1219 path-with-maximum-gold
#define SOLUTION_CPP_FOLDER_NAME_ID_1220 count-vowels-permutation
#define SOLUTION_CPP_FOLDER_NAME_ID_1221 split-a-string-in-balanced-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_1222 queens-that-can-attack-the-king
#define SOLUTION_CPP_FOLDER_NAME_ID_1223 dice-roll-simulation
#define SOLUTION_CPP_FOLDER_NAME_ID_1224 maximum-equal-frequency
#define SOLUTION_CPP_FOLDER_NAME_ID_1228 missing-number-in-arithmetic-progression
#define SOLUTION_CPP_FOLDER_NAME_ID_1229 meeting-scheduler
#define SOLUTION_CPP_FOLDER_NAME_ID_1230 toss-strange-coins
#define SOLUTION_CPP_FOLDER_NAME_ID_1231 divide-chocolate
#define SOLUTION_CPP_FOLDER_NAME_ID_1232 check-if-it-is-a-straight-line
#define SOLUTION_CPP_FOLDER_NAME_ID_1233 remove-sub-folders-from-the-filesystem
#define SOLUTION_CPP_FOLDER_NAME_ID_1234 replace-the-substring-for-balanced-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1235 maximum-profit-in-job-scheduling
#define SOLUTION_CPP_FOLDER_NAME_ID_1243 array-transformation
#define SOLUTION_CPP_FOLDER_NAME_ID_1244 design-a-leaderboard
#define SOLUTION_CPP_FOLDER_NAME_ID_1245 tree-diameter
#define SOLUTION_CPP_FOLDER_NAME_ID_1246 palindrome-removal
#define SOLUTION_CPP_FOLDER_NAME_ID_1237 find-positive-integer-solution-for-a-given-equation
#define SOLUTION_CPP_FOLDER_NAME_ID_1238 circular-permutation-in-binary-representation
#define SOLUTION_CPP_FOLDER_NAME_ID_1239 maximum-length-of-a-concatenated-string-with-unique-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_1240 tiling-a-rectangle-with-the-fewest-squares
#define SOLUTION_CPP_FOLDER_NAME_ID_1247 minimum-swaps-to-make-strings-equal
#define SOLUTION_CPP_FOLDER_NAME_ID_1248 count-number-of-nice-subarrays
#define SOLUTION_CPP_FOLDER_NAME_ID_1249 minimum-remove-to-make-valid-parentheses
#define SOLUTION_CPP_FOLDER_NAME_ID_1250 check-if-it-is-a-good-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1252 cells-with-odd-values-in-a-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1253 reconstruct-a-2-row-binary-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1254 number-of-closed-islands
#define SOLUTION_CPP_FOLDER_NAME_ID_1255 maximum-score-words-formed-by-letters
#define SOLUTION_CPP_FOLDER_NAME_ID_1256 encode-number
#define SOLUTION_CPP_FOLDER_NAME_ID_1257 smallest-common-region
#define SOLUTION_CPP_FOLDER_NAME_ID_1258 synonymous-sentences
#define SOLUTION_CPP_FOLDER_NAME_ID_1259 handshakes-that-dont-cross
#define SOLUTION_CPP_FOLDER_NAME_ID_1260 shift-2d-grid
#define SOLUTION_CPP_FOLDER_NAME_ID_1261 find-elements-in-a-contaminated-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1262 greatest-sum-divisible-by-three
#define SOLUTION_CPP_FOLDER_NAME_ID_1263 minimum-moves-to-move-a-box-to-their-target-location
#define SOLUTION_CPP_FOLDER_NAME_ID_1266 minimum-time-visiting-all-points
#define SOLUTION_CPP_FOLDER_NAME_ID_1267 count-servers-that-communicate
#define SOLUTION_CPP_FOLDER_NAME_ID_1268 search-suggestions-system
#define SOLUTION_CPP_FOLDER_NAME_ID_1269 number-of-ways-to-stay-in-the-same-place-after-some-steps
#define SOLUTION_CPP_FOLDER_NAME_ID_1271 hexspeak
#define SOLUTION_CPP_FOLDER_NAME_ID_1272 remove-interval
#define SOLUTION_CPP_FOLDER_NAME_ID_1273 delete-tree-nodes
#define SOLUTION_CPP_FOLDER_NAME_ID_1274 number-of-ships-in-a-rectangle
#define SOLUTION_CPP_FOLDER_NAME_ID_1275 find-winner-on-a-tic-tac-toe-game
#define SOLUTION_CPP_FOLDER_NAME_ID_1276 number-of-burgers-with-no-waste-of-ingredients
#define SOLUTION_CPP_FOLDER_NAME_ID_1277 count-square-submatrices-with-all-ones
#define SOLUTION_CPP_FOLDER_NAME_ID_1278 palindrome-partitioning-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_1281 subtract-the-product-and-sum-of-digits-of-an-integer
#define SOLUTION_CPP_FOLDER_NAME_ID_1282 group-the-people-given-the-group-size-they-belong-to
#define SOLUTION_CPP_FOLDER_NAME_ID_1283 find-the-smallest-divisor-given-a-threshold
#define SOLUTION_CPP_FOLDER_NAME_ID_1284 minimum-number-of-flips-to-convert-binary-matrix-to-zero-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1286 iterator-for-combination
#define SOLUTION_CPP_FOLDER_NAME_ID_1287 element-appearing-more-than-25-in-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1288 remove-covered-intervals
#define SOLUTION_CPP_FOLDER_NAME_ID_1289 minimum-falling-path-sum-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_1290 convert-binary-number-in-a-linked-list-to-integer
#define SOLUTION_CPP_FOLDER_NAME_ID_1291 sequential-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_1292 maximum-side-length-of-a-square-with-sum-less-than-or-equal-to-threshold
#define SOLUTION_CPP_FOLDER_NAME_ID_1293 shortest-path-in-a-grid-with-obstacles-elimination
#define SOLUTION_CPP_FOLDER_NAME_ID_1295 find-numbers-with-even-number-of-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_1296 divide-array-in-sets-of-k-consecutive-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_1297 maximum-number-of-occurrences-of-a-substring
#define SOLUTION_CPP_FOLDER_NAME_ID_1298 maximum-candies-you-can-get-from-boxes
#define SOLUTION_CPP_FOLDER_NAME_ID_1299 replace-elements-with-greatest-element-on-right-side
#define SOLUTION_CPP_FOLDER_NAME_ID_1300 sum-of-mutated-array-closest-to-target
#define SOLUTION_CPP_FOLDER_NAME_ID_1301 number-of-paths-with-max-score
#define SOLUTION_CPP_FOLDER_NAME_ID_1302 deepest-leaves-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1304 find-n-unique-integers-sum-up-to-zero
#define SOLUTION_CPP_FOLDER_NAME_ID_1305 all-elements-in-two-binary-search-trees
#define SOLUTION_CPP_FOLDER_NAME_ID_1306 jump-game-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_1307 verbal-arithmetic-puzzle
#define SOLUTION_CPP_FOLDER_NAME_ID_1309 decrypt-string-from-alphabet-to-integer-mapping
#define SOLUTION_CPP_FOLDER_NAME_ID_1310 xor-queries-of-a-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_1311 get-watched-videos-by-your-friends
#define SOLUTION_CPP_FOLDER_NAME_ID_1312 minimum-insertion-steps-to-make-a-string-palindrome
#define SOLUTION_CPP_FOLDER_NAME_ID_1313 decompress-run-length-encoded-list
#define SOLUTION_CPP_FOLDER_NAME_ID_1314 matrix-block-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1315 sum-of-nodes-with-even-valued-grandparent
#define SOLUTION_CPP_FOLDER_NAME_ID_1316 distinct-echo-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_1317 convert-integer-to-the-sum-of-two-no-zero-integers
#define SOLUTION_CPP_FOLDER_NAME_ID_1318 minimum-flips-to-make-a-or-b-equal-to-c
#define SOLUTION_CPP_FOLDER_NAME_ID_1319 number-of-operations-to-make-network-connected
#define SOLUTION_CPP_FOLDER_NAME_ID_1320 minimum-distance-to-type-a-word-using-two-fingers
#define SOLUTION_CPP_FOLDER_NAME_ID_1323 maximum-69-number
#define SOLUTION_CPP_FOLDER_NAME_ID_1324 print-words-vertically
#define SOLUTION_CPP_FOLDER_NAME_ID_1325 delete-leaves-with-a-given-value
#define SOLUTION_CPP_FOLDER_NAME_ID_1326 minimum-number-of-taps-to-open-to-water-a-garden
#define SOLUTION_CPP_FOLDER_NAME_ID_1328 break-a-palindrome
#define SOLUTION_CPP_FOLDER_NAME_ID_1329 sort-the-matrix-diagonally
#define SOLUTION_CPP_FOLDER_NAME_ID_1330 reverse-subarray-to-maximize-array-value
#define SOLUTION_CPP_FOLDER_NAME_ID_1331 rank-transform-of-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1332 remove-palindromic-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_1333 filter-restaurants-by-vegan-friendly-price-and-distance
#define SOLUTION_CPP_FOLDER_NAME_ID_1334 find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance
#define SOLUTION_CPP_FOLDER_NAME_ID_1335 minimum-difficulty-of-a-job-schedule
#define SOLUTION_CPP_FOLDER_NAME_ID_1337 the-k-weakest-rows-in-a-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1338 reduce-array-size-to-the-half
#define SOLUTION_CPP_FOLDER_NAME_ID_1339 maximum-product-of-splitted-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1340 jump-game-v
#define SOLUTION_CPP_FOLDER_NAME_ID_1342 number-of-steps-to-reduce-a-number-to-zero
#define SOLUTION_CPP_FOLDER_NAME_ID_1343 number-of-sub-arrays-of-size-k-and-average-greater-than-or-equal-to-threshold
#define SOLUTION_CPP_FOLDER_NAME_ID_1344 angle-between-hands-of-a-clock
#define SOLUTION_CPP_FOLDER_NAME_ID_1345 jump-game-iv
#define SOLUTION_CPP_FOLDER_NAME_ID_1346 check-if-n-and-its-double-exist
#define SOLUTION_CPP_FOLDER_NAME_ID_1347 minimum-number-of-steps-to-make-two-strings-anagram
#define SOLUTION_CPP_FOLDER_NAME_ID_1348 tweet-counts-per-frequency
#define SOLUTION_CPP_FOLDER_NAME_ID_1349 maximum-students-taking-exam
#define SOLUTION_CPP_FOLDER_NAME_ID_1351 count-negative-numbers-in-a-sorted-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1352 product-of-the-last-k-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_1353 maximum-number-of-events-that-can-be-attended
#define SOLUTION_CPP_FOLDER_NAME_ID_1354 construct-target-array-with-multiple-sums
#define SOLUTION_CPP_FOLDER_NAME_ID_1356 sort-integers-by-the-number-of-1-bits
#define SOLUTION_CPP_FOLDER_NAME_ID_1357 apply-discount-every-n-orders
#define SOLUTION_CPP_FOLDER_NAME_ID_1358 number-of-substrings-containing-all-three-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_1359 count-all-valid-pickup-and-delivery-options
#define SOLUTION_CPP_FOLDER_NAME_ID_1360 number-of-days-between-two-dates
#define SOLUTION_CPP_FOLDER_NAME_ID_1361 validate-binary-tree-nodes
#define SOLUTION_CPP_FOLDER_NAME_ID_1362 closest-divisors
#define SOLUTION_CPP_FOLDER_NAME_ID_1363 largest-multiple-of-three
#define SOLUTION_CPP_FOLDER_NAME_ID_1390 four-divisors
#define SOLUTION_CPP_FOLDER_NAME_ID_1382 balance-a-binary-search-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1370 increasing-decreasing-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1371 find-the-longest-substring-containing-vowels-in-even-counts
#define SOLUTION_CPP_FOLDER_NAME_ID_1372 longest-zigzag-path-in-a-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1373 maximum-sum-bst-in-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1365 how-many-numbers-are-smaller-than-the-current-number
#define SOLUTION_CPP_FOLDER_NAME_ID_1366 rank-teams-by-votes
#define SOLUTION_CPP_FOLDER_NAME_ID_1367 linked-list-in-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1368 minimum-cost-to-make-at-least-one-valid-path-in-a-grid
#define SOLUTION_CPP_FOLDER_NAME_ID_1374 generate-a-string-with-characters-that-have-odd-counts
#define SOLUTION_CPP_FOLDER_NAME_ID_1375 bulb-switcher-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_1376 time-needed-to-inform-all-employees
#define SOLUTION_CPP_FOLDER_NAME_ID_1377 frog-position-after-t-seconds
#define SOLUTION_CPP_FOLDER_NAME_ID_1380 lucky-numbers-in-a-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1381 design-a-stack-with-increment-operation
#define SOLUTION_CPP_FOLDER_NAME_ID_1383 maximum-performance-of-a-team
#define SOLUTION_CPP_FOLDER_NAME_ID_1385 find-the-distance-value-between-two-arrays
#define SOLUTION_CPP_FOLDER_NAME_ID_1386 cinema-seat-allocation
#define SOLUTION_CPP_FOLDER_NAME_ID_1387 sort-integers-by-the-power-value
#define SOLUTION_CPP_FOLDER_NAME_ID_1388 pizza-with-3n-slices
#define SOLUTION_CPP_FOLDER_NAME_ID_1389 create-target-array-in-the-given-order
#define SOLUTION_CPP_FOLDER_NAME_ID_1391 check-if-there-is-a-valid-path-in-a-grid
#define SOLUTION_CPP_FOLDER_NAME_ID_1392 longest-happy-prefix
#define SOLUTION_CPP_FOLDER_NAME_ID_1394 find-lucky-integer-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1395 count-number-of-teams
#define SOLUTION_CPP_FOLDER_NAME_ID_1396 design-underground-system
#define SOLUTION_CPP_FOLDER_NAME_ID_1397 find-all-good-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_1399 count-largest-group
#define SOLUTION_CPP_FOLDER_NAME_ID_1400 construct-k-palindrome-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_1401 circle-and-rectangle-overlapping
#define SOLUTION_CPP_FOLDER_NAME_ID_1402 reducing-dishes
#define SOLUTION_CPP_FOLDER_NAME_ID_1405 longest-happy-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1403 minimum-subsequence-in-non-increasing-order
#define SOLUTION_CPP_FOLDER_NAME_ID_1404 number-of-steps-to-reduce-a-number-in-binary-representation-to-one
#define SOLUTION_CPP_FOLDER_NAME_ID_1406 stone-game-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_1408 string-matching-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1409 queries-on-a-permutation-with-key
#define SOLUTION_CPP_FOLDER_NAME_ID_1410 html-entity-parser
#define SOLUTION_CPP_FOLDER_NAME_ID_1411 number-of-ways-to-paint-n-x-3-grid
#define SOLUTION_CPP_FOLDER_NAME_ID_1413 minimum-value-to-get-positive-step-by-step-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1414 find-the-minimum-number-of-fibonacci-numbers-whose-sum-is-k
#define SOLUTION_CPP_FOLDER_NAME_ID_1415 the-k-th-lexicographical-string-of-all-happy-strings-of-length-n
#define SOLUTION_CPP_FOLDER_NAME_ID_1416 restore-the-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1417 reformat-the-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1418 display-table-of-food-orders-in-a-restaurant
#define SOLUTION_CPP_FOLDER_NAME_ID_1419 minimum-number-of-frogs-croaking
#define SOLUTION_CPP_FOLDER_NAME_ID_1420 build-array-where-you-can-find-the-maximum-exactly-k-comparisons
#define SOLUTION_CPP_FOLDER_NAME_ID_1422 maximum-score-after-splitting-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1423 maximum-points-you-can-obtain-from-cards
#define SOLUTION_CPP_FOLDER_NAME_ID_1424 diagonal-traverse-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_1425 constrained-subset-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1431 kids-with-the-greatest-number-of-candies
#define SOLUTION_CPP_FOLDER_NAME_ID_1432 max-difference-you-can-get-from-changing-an-integer
#define SOLUTION_CPP_FOLDER_NAME_ID_1433 check-if-a-string-can-break-another-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1434 number-of-ways-to-wear-different-hats-to-each-other
#define SOLUTION_CPP_FOLDER_NAME_ID_1436 destination-city
#define SOLUTION_CPP_FOLDER_NAME_ID_1437 check-if-all-1s-are-at-least-length-k-places-away
#define SOLUTION_CPP_FOLDER_NAME_ID_1438 longest-continuous-subarray-with-absolute-diff-less-than-or-equal-to-limit
#define SOLUTION_CPP_FOLDER_NAME_ID_1439 find-the-kth-smallest-sum-of-a-matrix-with-sorted-rows
#define SOLUTION_CPP_FOLDER_NAME_ID_1441 build-an-array-with-stack-operations
#define SOLUTION_CPP_FOLDER_NAME_ID_1442 count-triplets-that-can-form-two-arrays-of-equal-xor
#define SOLUTION_CPP_FOLDER_NAME_ID_1443 minimum-time-to-collect-all-apples-in-a-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1444 number-of-ways-of-cutting-a-pizza
#define SOLUTION_CPP_FOLDER_NAME_ID_1446 consecutive-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_1447 simplified-fractions
#define SOLUTION_CPP_FOLDER_NAME_ID_1448 count-good-nodes-in-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1449 form-largest-integer-with-digits-that-add-up-to-target
#define SOLUTION_CPP_FOLDER_NAME_ID_1450 number-of-students-doing-homework-at-a-given-time
#define SOLUTION_CPP_FOLDER_NAME_ID_1451 rearrange-words-in-a-sentence
#define SOLUTION_CPP_FOLDER_NAME_ID_1452 people-whose-list-of-favorite-companies-is-not-a-subset-of-another-list
#define SOLUTION_CPP_FOLDER_NAME_ID_1453 maximum-number-of-darts-inside-of-a-circular-dartboard
#define SOLUTION_CPP_FOLDER_NAME_ID_1455 check-if-a-word-occurs-as-a-prefix-of-any-word-in-a-sentence
#define SOLUTION_CPP_FOLDER_NAME_ID_1456 maximum-number-of-vowels-in-a-substring-of-given-length
#define SOLUTION_CPP_FOLDER_NAME_ID_1457 pseudo-palindromic-paths-in-a-binary-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1458 max-dot-product-of-two-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_1460 make-two-arrays-equal-by-reversing-sub-arrays
#define SOLUTION_CPP_FOLDER_NAME_ID_1461 check-if-a-string-contains-all-binary-codes-of-size-k
#define SOLUTION_CPP_FOLDER_NAME_ID_1462 course-schedule-iv
#define SOLUTION_CPP_FOLDER_NAME_ID_1463 cherry-pickup-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_1464 maximum-product-of-two-elements-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1465 maximum-area-of-a-piece-of-cake-after-horizontal-and-vertical-cuts
#define SOLUTION_CPP_FOLDER_NAME_ID_1466 reorder-routes-to-make-all-paths-lead-to-the-city-zero
#define SOLUTION_CPP_FOLDER_NAME_ID_1467 probability-of-a-two-boxes-having-the-same-number-of-distinct-balls
#define SOLUTION_CPP_FOLDER_NAME_ID_1470 shuffle-the-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1471 the-k-strongest-values-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1472 design-browser-history
#define SOLUTION_CPP_FOLDER_NAME_ID_1473 paint-house-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_1475 final-prices-with-a-special-discount-in-a-shop
#define SOLUTION_CPP_FOLDER_NAME_ID_1476 avoid-flood-in-the-city
#define SOLUTION_CPP_FOLDER_NAME_ID_1477 find-two-non-overlapping-sub-arrays-each-with-target-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1478 allocate-mailboxes
#define SOLUTION_CPP_FOLDER_NAME_ID_1480 running-sum-of-1d-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1481 least-number-of-unique-integers-after-k-removals
#define SOLUTION_CPP_FOLDER_NAME_ID_1482 minimum-number-of-days-to-make-m-bouquets
#define SOLUTION_CPP_FOLDER_NAME_ID_1483 kth-ancestor-of-a-tree-node
#define SOLUTION_CPP_FOLDER_NAME_ID_1486 xor-operation-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1487 making-file-names-unique
#define SOLUTION_CPP_FOLDER_NAME_ID_1488 avoid-flood-in-the-city
#define SOLUTION_CPP_FOLDER_NAME_ID_1489 find-critical-and-pseudo-critical-edges-in-minimum-spanning-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1491 average-salary-excluding-the-minimum-and-maximum-salary
#define SOLUTION_CPP_FOLDER_NAME_ID_1492 the-kth-factor-of-n
#define SOLUTION_CPP_FOLDER_NAME_ID_1493 longest-subarray-of-1s-after-deleting-one-element
#define SOLUTION_CPP_FOLDER_NAME_ID_1494 parallel-courses-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_1496 path-crossing
#define SOLUTION_CPP_FOLDER_NAME_ID_1497 check-if-array-pairs-are-divisible-by-k
#define SOLUTION_CPP_FOLDER_NAME_ID_1498 number-of-subsequences-that-satisfy-the-given-sum-condition
#define SOLUTION_CPP_FOLDER_NAME_ID_1499 max-value-of-equation
#define SOLUTION_CPP_FOLDER_NAME_ID_1502 can-make-arithmetic-progression-from-sequence
#define SOLUTION_CPP_FOLDER_NAME_ID_1503 last-moment-before-all-ants-fall-out-of-a-plank
#define SOLUTION_CPP_FOLDER_NAME_ID_1504 count-submatrices-with-all-ones
#define SOLUTION_CPP_FOLDER_NAME_ID_1505 minimum-possible-integer-after-at-most-k-adjacent-swaps-on-digits
#define SOLUTION_CPP_FOLDER_NAME_ID_1507 reformat-date
#define SOLUTION_CPP_FOLDER_NAME_ID_1508 range-sum-of-sorted-subarray-sums
#define SOLUTION_CPP_FOLDER_NAME_ID_1509 minimum-difference-between-largest-and-smallest-value-in-three-moves
#define SOLUTION_CPP_FOLDER_NAME_ID_1510 stone-game-iv
#define SOLUTION_CPP_FOLDER_NAME_ID_1512 number-of-good-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_1513 number-of-substrings-with-only-1s
#define SOLUTION_CPP_FOLDER_NAME_ID_1514 path-with-maximum-probability
#define SOLUTION_CPP_FOLDER_NAME_ID_1515 best-position-for-a-service-centre
#define SOLUTION_CPP_FOLDER_NAME_ID_1518 water-bottles
#define SOLUTION_CPP_FOLDER_NAME_ID_1519 number-of-nodes-in-the-sub-tree-with-the-same-label
#define SOLUTION_CPP_FOLDER_NAME_ID_1520 maximum-number-of-non-overlapping-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_1521 find-a-value-of-a-mysterious-function-closest-to-target
#define SOLUTION_CPP_FOLDER_NAME_ID_1523 count-odd-numbers-in-an-interval-range
#define SOLUTION_CPP_FOLDER_NAME_ID_1524 number-of-sub-arrays-with-odd-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1525 number-of-good-ways-to-split-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1526 minimum-number-of-increments-on-subarrays-to-form-a-target-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1528 shuffle-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1529 bulb-switcher-iv
#define SOLUTION_CPP_FOLDER_NAME_ID_1530 number-of-good-leaf-nodes-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_1531 string-compression-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_1534 count-good-triplets
#define SOLUTION_CPP_FOLDER_NAME_ID_1535 find-the-winner-of-an-array-game
#define SOLUTION_CPP_FOLDER_NAME_ID_1536 minimum-swaps-to-arrange-a-binary-grid
#define SOLUTION_CPP_FOLDER_NAME_ID_1537 get-the-maximum-score
#define SOLUTION_CPP_FOLDER_NAME_ID_1539 kth-missing-positive-number
#define SOLUTION_CPP_FOLDER_NAME_ID_1540 can-convert-string-in-k-moves
#define SOLUTION_CPP_FOLDER_NAME_ID_1541 minimum-insertions-to-balance-a-parentheses-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1542 find-longest-awesome-substring
#define SOLUTION_CPP_FOLDER_NAME_ID_1546 maximum-number-of-non-overlapping-subarrays-with-sum-equals-target
#define SOLUTION_CPP_FOLDER_NAME_ID_1544 make-the-string-great
#define SOLUTION_CPP_FOLDER_NAME_ID_1545 find-kth-bit-in-nth-binary-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1547 minimum-cost-to-cut-a-stick
#define SOLUTION_CPP_FOLDER_NAME_ID_1550 three-consecutive-odds
#define SOLUTION_CPP_FOLDER_NAME_ID_1551 minimum-operations-to-make-array-equal
#define SOLUTION_CPP_FOLDER_NAME_ID_1552 magnetic-force-between-two-balls
#define SOLUTION_CPP_FOLDER_NAME_ID_1553 minimum-number-of-days-to-eat-n-oranges
#define SOLUTION_CPP_FOLDER_NAME_ID_1556 thousand-separator
#define SOLUTION_CPP_FOLDER_NAME_ID_1557 minimum-number-of-vertices-to-reach-all-nodes
#define SOLUTION_CPP_FOLDER_NAME_ID_1558 minimum-numbers-of-function-calls-to-make-target-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1559 detect-cycles-in-2d-grid
#define SOLUTION_CPP_FOLDER_NAME_ID_1560 most-visited-sector-in-a-circular-track
#define SOLUTION_CPP_FOLDER_NAME_ID_1561 maximum-number-of-coins-you-can-get
#define SOLUTION_CPP_FOLDER_NAME_ID_1562 find-latest-group-of-size-m
#define SOLUTION_CPP_FOLDER_NAME_ID_1563 stone-game-v
#define SOLUTION_CPP_FOLDER_NAME_ID_1566 detect-pattern-of-length-m-repeated-k-or-more-times
#define SOLUTION_CPP_FOLDER_NAME_ID_1567 maximum-length-of-subarray-with-positive-product
#define SOLUTION_CPP_FOLDER_NAME_ID_1568 minimum-number-of-days-to-disconnect-island
#define SOLUTION_CPP_FOLDER_NAME_ID_1569 number-of-ways-to-reorder-array-to-get-same-bst
#define SOLUTION_CPP_FOLDER_NAME_ID_1572 matrix-diagonal-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_1573 number-of-ways-to-split-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_1574 shortest-subarray-to-be-removed-to-make-array-sorted
#define SOLUTION_CPP_FOLDER_NAME_ID_1575 count-all-possible-routes
#define SOLUTION_CPP_FOLDER_NAME_ID_1576 replace-all-s-to-avoid-consecutive-repeating-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_1577 number-of-ways-where-square-of-number-is-equal-to-product-of-two-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_1578 minimum-deletion-cost-to-avoid-repeating-letters
#define SOLUTION_CPP_FOLDER_NAME_ID_1579 remove-max-number-of-edges-to-keep-graph-fully-traversable
#define SOLUTION_CPP_FOLDER_NAME_ID_1582 special-positions-in-a-binary-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1583 count-unhappy-friends
#define SOLUTION_CPP_FOLDER_NAME_ID_1584 min-cost-to-connect-all-points
#define SOLUTION_CPP_FOLDER_NAME_ID_1585 check-if-string-is-transformable-with-substring-sort-operations
#define SOLUTION_CPP_FOLDER_NAME_ID_1603 design-parking-system
#define SOLUTION_CPP_FOLDER_NAME_ID_1604 alert-using-same-key-card-three-or-more-times-in-a-one-hour-period
#define SOLUTION_CPP_FOLDER_NAME_ID_1605 find-valid-matrix-given-row-and-column-sums
#define SOLUTION_CPP_FOLDER_NAME_ID_1606 find-servers-that-handled-most-number-of-requests
#define SOLUTION_CPP_FOLDER_NAME_ID_1608 special-array-with-x-elements-greater-than-or-equal-x
#define SOLUTION_CPP_FOLDER_NAME_ID_1609 even-odd-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1610 maximum-number-of-visible-points
#define SOLUTION_CPP_FOLDER_NAME_ID_1611 minimum-one-bit-operations-to-make-integers-zero
#define SOLUTION_CPP_FOLDER_NAME_ID_1616 split-two-strings-to-make-palindrome
#define SOLUTION_CPP_FOLDER_NAME_ID_1619 mean-of-array-after-removing-some-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_1624 largest-substring-between-two-equal-characters
#define SOLUTION_CPP_FOLDER_NAME_ID_1625 lexicographically-smallest-string-after-applying-operations
#define SOLUTION_CPP_FOLDER_NAME_ID_1626 best-team-with-no-conflicts
#define SOLUTION_CPP_FOLDER_NAME_ID_1627 graph-connectivity-with-threshold
#define SOLUTION_CPP_FOLDER_NAME_ID_1632 rank-transform-of-a-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1662 check-if-two-string-arrays-are-equivalent
#define SOLUTION_CPP_FOLDER_NAME_ID_1663 smallest-string-with-a-given-numeric-value
#define SOLUTION_CPP_FOLDER_NAME_ID_1664 ways-to-make-a-fair-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1665 minimum-initial-energy-to-finish-tasks
#define SOLUTION_CPP_FOLDER_NAME_ID_1684 count-the-number-of-consistent-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_1685 sum-of-absolute-differences-in-a-sorted-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1686 stone-game-vi
#define SOLUTION_CPP_FOLDER_NAME_ID_1687 delivering-boxes-from-storage-to-ports
#define SOLUTION_CPP_FOLDER_NAME_ID_1691 maximum-height-by-stacking-cuboids
#define SOLUTION_CPP_FOLDER_NAME_ID_1694 reformat-phone-number
#define SOLUTION_CPP_FOLDER_NAME_ID_1695 maximum-erasure-value
#define SOLUTION_CPP_FOLDER_NAME_ID_1696 jump-game-vi
#define SOLUTION_CPP_FOLDER_NAME_ID_1697 checking-existence-of-edge-length-limited-paths
#define SOLUTION_CPP_FOLDER_NAME_ID_1588 sum-of-all-odd-length-subarrays
#define SOLUTION_CPP_FOLDER_NAME_ID_1589 maximum-sum-obtained-of-any-permutation
#define SOLUTION_CPP_FOLDER_NAME_ID_1590 make-sum-divisible-by-p
#define SOLUTION_CPP_FOLDER_NAME_ID_1591 strange-printer-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_1592 rearrange-spaces-between-words
#define SOLUTION_CPP_FOLDER_NAME_ID_1593 split-a-string-into-the-max-number-of-unique-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_1594 maximum-non-negative-product-in-a-matrix
#define SOLUTION_CPP_FOLDER_NAME_ID_1595 minimum-cost-to-connect-two-groups-of-points
#define SOLUTION_CPP_FOLDER_NAME_ID_1598 crawler-log-folder
#define SOLUTION_CPP_FOLDER_NAME_ID_1599 maximum-profit-of-operating-a-centennial-wheel
#define SOLUTION_CPP_FOLDER_NAME_ID_1600 throne-inheritance
#define SOLUTION_CPP_FOLDER_NAME_ID_1601 maximum-number-of-achievable-transfer-requests
#define SOLUTION_CPP_FOLDER_NAME_ID_1614 maximum-nesting-depth-of-the-parentheses
#define SOLUTION_CPP_FOLDER_NAME_ID_1615 maximal-network-rank
#define SOLUTION_CPP_FOLDER_NAME_ID_1616 split-two-strings-to-make-palindrome
#define SOLUTION_CPP_FOLDER_NAME_ID_1617 count-subtrees-with-max-distance-between-cities
#define SOLUTION_CPP_FOLDER_NAME_ID_1620 coordinate-with-maximum-network-quality
#define SOLUTION_CPP_FOLDER_NAME_ID_1621 number-of-sets-of-k-non-overlapping-line-segments
#define SOLUTION_CPP_FOLDER_NAME_ID_1622 fancy-sequence
#define SOLUTION_CPP_FOLDER_NAME_ID_1629 slowest-key
#define SOLUTION_CPP_FOLDER_NAME_ID_1630 arithmetic-subarrays
#define SOLUTION_CPP_FOLDER_NAME_ID_1631 path-with-minimum-effort
#define SOLUTION_CPP_FOLDER_NAME_ID_1636 sort-array-by-increasing-frequency
#define SOLUTION_CPP_FOLDER_NAME_ID_1637 widest-vertical-area-between-two-points-containing-no-points
#define SOLUTION_CPP_FOLDER_NAME_ID_1638 count-substrings-that-differ-by-one-character
#define SOLUTION_CPP_FOLDER_NAME_ID_1639 number-of-ways-to-form-a-target-string-given-a-dictionary
#define SOLUTION_CPP_FOLDER_NAME_ID_1640 check-array-formation-through-concatenation
#define SOLUTION_CPP_FOLDER_NAME_ID_1641 count-sorted-vowel-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_1642 furthest-building-you-can-reach
#define SOLUTION_CPP_FOLDER_NAME_ID_1643 kth-smallest-instructions
#define SOLUTION_CPP_FOLDER_NAME_ID_1646 get-maximum-in-generated-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1647 minimum-deletions-to-make-character-frequencies-unique
#define SOLUTION_CPP_FOLDER_NAME_ID_1648 sell-diminishing-valued-colored-balls
#define SOLUTION_CPP_FOLDER_NAME_ID_1649 create-sorted-array-through-instructions
#define SOLUTION_CPP_FOLDER_NAME_ID_1652 defuse-the-bomb
#define SOLUTION_CPP_FOLDER_NAME_ID_1653 minimum-deletions-to-make-string-balanced
#define SOLUTION_CPP_FOLDER_NAME_ID_1654 minimum-jumps-to-reach-home
#define SOLUTION_CPP_FOLDER_NAME_ID_1655 distribute-repeating-integers
#define SOLUTION_CPP_FOLDER_NAME_ID_1656 design-an-ordered-stream
#define SOLUTION_CPP_FOLDER_NAME_ID_1657 determine-if-two-strings-are-close
#define SOLUTION_CPP_FOLDER_NAME_ID_1658 minimum-operations-to-reduce-x-to-zero
#define SOLUTION_CPP_FOLDER_NAME_ID_1659 maximize-grid-happiness
#define SOLUTION_CPP_FOLDER_NAME_ID_1668 maximum-repeating-substring
#define SOLUTION_CPP_FOLDER_NAME_ID_1669 merge-in-between-linked-lists
#define SOLUTION_CPP_FOLDER_NAME_ID_1670 design-front-middle-back-queue
#define SOLUTION_CPP_FOLDER_NAME_ID_1671 minimum-number-of-removals-to-make-mountain-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1672 richest-customer-wealth
#define SOLUTION_CPP_FOLDER_NAME_ID_1673 find-the-most-competitive-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_1674 minimum-moves-to-make-array-complementary
#define SOLUTION_CPP_FOLDER_NAME_ID_1675 minimize-deviation-in-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1678 goal-parser-interpretation
#define SOLUTION_CPP_FOLDER_NAME_ID_1679 max-number-of-k-sum-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_1680 concatenation-of-consecutive-binary-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_1681 minimum-incompatibility
#define SOLUTION_CPP_FOLDER_NAME_ID_1688 count-of-matches-in-tournament
#define SOLUTION_CPP_FOLDER_NAME_ID_1689 partitioning-into-minimum-number-of-deci-binary-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_1690 stone-game-vii
#define SOLUTION_CPP_FOLDER_NAME_ID_1700 number-of-students-unable-to-eat-lunch
#define SOLUTION_CPP_FOLDER_NAME_ID_1701 average-waiting-time
#define SOLUTION_CPP_FOLDER_NAME_ID_1702 maximum-binary-string-after-change
#define SOLUTION_CPP_FOLDER_NAME_ID_1703 minimum-adjacent-swaps-for-k-consecutive-ones
#define SOLUTION_CPP_FOLDER_NAME_ID_1704 determine-if-string-halves-are-alike
#define SOLUTION_CPP_FOLDER_NAME_ID_1705 maximum-number-of-eaten-apples
#define SOLUTION_CPP_FOLDER_NAME_ID_1706 where-will-the-ball-fall
#define SOLUTION_CPP_FOLDER_NAME_ID_1707 maximum-xor-with-an-element-from-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1710 maximum-units-on-a-truck
#define SOLUTION_CPP_FOLDER_NAME_ID_1711 count-good-meals
#define SOLUTION_CPP_FOLDER_NAME_ID_1712 ways-to-split-array-into-three-subarrays
#define SOLUTION_CPP_FOLDER_NAME_ID_1713 minimum-operations-to-make-a-subsequence
#define SOLUTION_CPP_FOLDER_NAME_ID_1716 calculate-money-in-leetcode-bank
#define SOLUTION_CPP_FOLDER_NAME_ID_1717 maximum-score-from-removing-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_1718 construct-the-lexicographically-largest-valid-sequence
#define SOLUTION_CPP_FOLDER_NAME_ID_1719 number-of-ways-to-reconstruct-a-tree
#define SOLUTION_CPP_FOLDER_NAME_ID_1720 decode-xored-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1812 determine-color-of-a-chessboard-square
#define SOLUTION_CPP_FOLDER_NAME_ID_1813 sentence-similarity-iii
#define SOLUTION_CPP_FOLDER_NAME_ID_1814 count-nice-pairs-in-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1815 maximum-number-of-groups-getting-fresh-donuts
#define SOLUTION_CPP_FOLDER_NAME_ID_1816 truncate-sentence
#define SOLUTION_CPP_FOLDER_NAME_ID_1818 minimum-absolute-sum-difference
#define SOLUTION_CPP_FOLDER_NAME_ID_1833 maximum-ice-cream-bars
#define SOLUTION_CPP_FOLDER_NAME_ID_1837 sum-of-digits-in-base-k
#define SOLUTION_CPP_FOLDER_NAME_ID_1838 frequency-of-the-most-frequent-element
#define SOLUTION_CPP_FOLDER_NAME_ID_1839 longest-substring-of-all-vowels-in-order
#define SOLUTION_CPP_FOLDER_NAME_ID_1840 maximum-building-height
#define SOLUTION_CPP_FOLDER_NAME_ID_1846 maximum-element-after-decreasing-and-rearranging
#define SOLUTION_CPP_FOLDER_NAME_ID_1859 sorting-the-sentence
#define SOLUTION_CPP_FOLDER_NAME_ID_1860 incremental-memory-leak
#define SOLUTION_CPP_FOLDER_NAME_ID_1861 rotating-the-box
#define SOLUTION_CPP_FOLDER_NAME_ID_1862 sum-of-floored-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_1877 minimize-maximum-pair-sum-in-array
#define SOLUTION_CPP_FOLDER_NAME_ID_1913 maximum-product-difference-between-two-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_1914 cyclically-rotating-a-grid
#define SOLUTION_CPP_FOLDER_NAME_ID_1915 number-of-wonderful-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_1916 count-ways-to-build-rooms-in-an-ant-colony
#define SOLUTION_CPP_FOLDER_NAME_ID_1996 the-number-of-weak-characters-in-the-game
#define SOLUTION_CPP_FOLDER_NAME_ID_5161 maximum-number-of-words-you-can-type
#define SOLUTION_CPP_FOLDER_NAME_ID_5187 minimum-garden-perimeter-to-collect-enough-apples
#define SOLUTION_CPP_FOLDER_NAME_ID_5194 minimum-moves-to-reach-target-score
#define SOLUTION_CPP_FOLDER_NAME_ID_5243 tuple-with-same-product
#define SOLUTION_CPP_FOLDER_NAME_ID_5529 cat-and-mouse-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_5653 number-of-rectangles-that-can-form-the-largest-square
#define SOLUTION_CPP_FOLDER_NAME_ID_5654 maximum-number-of-balls-in-a-box
#define SOLUTION_CPP_FOLDER_NAME_ID_5655 largest-submatrix-with-rearrangements
#define SOLUTION_CPP_FOLDER_NAME_ID_5657 sum-of-unique-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_5658 maximum-absolute-sum-of-any-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_5659 minimum-length-of-string-after-deleting-similar-ends
#define SOLUTION_CPP_FOLDER_NAME_ID_5660 maximum-number-of-events-that-can-be-attended-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_5665 restore-the-array-from-adjacent-pairs
#define SOLUTION_CPP_FOLDER_NAME_ID_5666 palindrome-partitioning-iv
#define SOLUTION_CPP_FOLDER_NAME_ID_5667 can-you-eat-your-favorite-candy-on-your-favorite-day
#define SOLUTION_CPP_FOLDER_NAME_ID_5672 check-if-array-is-sorted-and-rotated
#define SOLUTION_CPP_FOLDER_NAME_ID_5673 maximum-score-from-removing-stones
#define SOLUTION_CPP_FOLDER_NAME_ID_5674 largest-merge-of-two-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_5675 closest-subsequence-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_5676 minimum-changes-to-make-alternating-binary-string
#define SOLUTION_CPP_FOLDER_NAME_ID_5677 count-number-of-homogenous-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_5678 minimum-limit-of-balls-in-a-bag
#define SOLUTION_CPP_FOLDER_NAME_ID_5679 minimum-degree-of-a-connected-trio-in-a-graph
#define SOLUTION_CPP_FOLDER_NAME_ID_5680 find-nearest-point-that-has-the-same-x-or-y-coordinate
#define SOLUTION_CPP_FOLDER_NAME_ID_5681 check-if-number-is-a-sum-of-powers-of-three
#define SOLUTION_CPP_FOLDER_NAME_ID_5682 sum-of-beauty-of-all-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_5683 count-pairs-of-nodes
#define SOLUTION_CPP_FOLDER_NAME_ID_5696 count-pairs-with-xor-in-a-range
#define SOLUTION_CPP_FOLDER_NAME_ID_5697 check-if-binary-string-has-at-most-one-segment-of-ones
#define SOLUTION_CPP_FOLDER_NAME_ID_5698 minimum-elements-to-add-to-form-a-given-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_5699 number-of-restricted-paths-from-first-to-last-node
#define SOLUTION_CPP_FOLDER_NAME_ID_5700 make-the-xor-of-all-segments-equal-to-zero
#define SOLUTION_CPP_FOLDER_NAME_ID_5701 check-if-one-string-swap-can-make-strings-equal
#define SOLUTION_CPP_FOLDER_NAME_ID_5702 find-center-of-star-graph
#define SOLUTION_CPP_FOLDER_NAME_ID_5703 maximum-average-pass-ratio
#define SOLUTION_CPP_FOLDER_NAME_ID_5704 maximum-score-of-a-good-subarray
#define SOLUTION_CPP_FOLDER_NAME_ID_5709 maximum-ascending-subarray-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_5710 number-of-orders-in-the-backlog
#define SOLUTION_CPP_FOLDER_NAME_ID_5711 maximum-value-at-a-given-index-in-a-bounded-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5713 number-of-different-integers-in-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_5714 evaluate-the-bracket-pairs-of-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_5715 minimum-number-of-operations-to-reinitialize-a-permutation
#define SOLUTION_CPP_FOLDER_NAME_ID_5716 maximize-number-of-nice-divisors
#define SOLUTION_CPP_FOLDER_NAME_ID_5717 minimum-operations-to-make-the-array-increasing
#define SOLUTION_CPP_FOLDER_NAME_ID_5718 queries-on-number-of-points-inside-a-circle
#define SOLUTION_CPP_FOLDER_NAME_ID_5719 maximum-xor-for-each-query
#define SOLUTION_CPP_FOLDER_NAME_ID_5720 minimum-number-of-operations-to-make-string-sorted
#define SOLUTION_CPP_FOLDER_NAME_ID_5726 sign-of-the-product-of-an-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5727 find-the-winner-of-the-circular-game
#define SOLUTION_CPP_FOLDER_NAME_ID_5728 minimum-sideway-jumps
#define SOLUTION_CPP_FOLDER_NAME_ID_5729 finding-mk-average
#define SOLUTION_CPP_FOLDER_NAME_ID_5750 maximum-population-year
#define SOLUTION_CPP_FOLDER_NAME_ID_5751 maximum-distance-between-a-pair-of-values
#define SOLUTION_CPP_FOLDER_NAME_ID_5752 maximum-subarray-min-product
#define SOLUTION_CPP_FOLDER_NAME_ID_5753 largest-color-value-in-a-directed-graph
#define SOLUTION_CPP_FOLDER_NAME_ID_5759 sum-of-all-subset-xor-totals
#define SOLUTION_CPP_FOLDER_NAME_ID_5760 minimum-number-of-swaps-to-make-the-binary-string-alternating
#define SOLUTION_CPP_FOLDER_NAME_ID_5761 finding-pairs-with-a-certain-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_5762 number-of-ways-to-rearrange-sticks-with-k-sticks-visible
#define SOLUTION_CPP_FOLDER_NAME_ID_5763 longer-contiguous-segments-of-ones-than-zeros
#define SOLUTION_CPP_FOLDER_NAME_ID_5764 minimum-speed-to-arrive-on-time
#define SOLUTION_CPP_FOLDER_NAME_ID_5765 jump-game-vii
#define SOLUTION_CPP_FOLDER_NAME_ID_5766 stone-game-viii
#define SOLUTION_CPP_FOLDER_NAME_ID_5772 check-if-word-equals-summation-of-two-words
#define SOLUTION_CPP_FOLDER_NAME_ID_5773 maximum-value-after-insertion
#define SOLUTION_CPP_FOLDER_NAME_ID_5774 process-tasks-using-servers
#define SOLUTION_CPP_FOLDER_NAME_ID_5775 minimum-skips-to-arrive-at-meeting-on-time
#define SOLUTION_CPP_FOLDER_NAME_ID_5776 determine-whether-matrix-can-be-obtained-by-rotation
#define SOLUTION_CPP_FOLDER_NAME_ID_5777 reduction-operations-to-make-the-array-elements-equal
#define SOLUTION_CPP_FOLDER_NAME_ID_5778 minimum-number-of-flips-to-make-the-binary-string-alternating
#define SOLUTION_CPP_FOLDER_NAME_ID_5779 minimum-space-wasted-from-packaging
#define SOLUTION_CPP_FOLDER_NAME_ID_5814 add-minimum-number-of-rungs
#define SOLUTION_CPP_FOLDER_NAME_ID_5815 maximum-number-of-points-with-cost
#define SOLUTION_CPP_FOLDER_NAME_ID_5816 maximum-genetic-difference-query
#define SOLUTION_CPP_FOLDER_NAME_ID_5823 sum-of-digits-of-string-after-convert
#define SOLUTION_CPP_FOLDER_NAME_ID_5824 largest-number-after-mutating-substring
#define SOLUTION_CPP_FOLDER_NAME_ID_5825 maximum-compatibility-score-sum
#define SOLUTION_CPP_FOLDER_NAME_ID_5826 delete-duplicate-folders-in-system
#define SOLUTION_CPP_FOLDER_NAME_ID_5830 three-divisors
#define SOLUTION_CPP_FOLDER_NAME_ID_5831 maximum-number-of-weeks-for-which-you-can-work
#define SOLUTION_CPP_FOLDER_NAME_ID_5832 array-with-elements-not-equal-to-average-of-neighbors
#define SOLUTION_CPP_FOLDER_NAME_ID_5833 count-number-of-special-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_5838 check-if-string-is-a-prefix-of-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5839 remove-stones-to-minimize-the-total
#define SOLUTION_CPP_FOLDER_NAME_ID_5840 minimum-number-of-swaps-to-make-the-string-balanced
#define SOLUTION_CPP_FOLDER_NAME_ID_5841 find-the-longest-valid-obstacle-course-at-each-position
#define SOLUTION_CPP_FOLDER_NAME_ID_5843 number-of-strings-that-appear-as-substrings-in-word
#define SOLUTION_CPP_FOLDER_NAME_ID_5844 minimum-non-zero-product-of-the-array-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_5845 last-day-where-you-can-still-cross
#define SOLUTION_CPP_FOLDER_NAME_ID_5850 find-greatest-common-divisor-of-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5851 find-unique-binary-string
#define SOLUTION_CPP_FOLDER_NAME_ID_5852 minimize-the-difference-between-target-and-chosen-elements
#define SOLUTION_CPP_FOLDER_NAME_ID_5853 find-array-given-subset-sums
#define SOLUTION_CPP_FOLDER_NAME_ID_5854 minimum-difference-between-highest-and-lowest-of-k-scores
#define SOLUTION_CPP_FOLDER_NAME_ID_5855 find-the-kth-largest-integer-in-the-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5856 minimum-number-of-work-sessions-to-finish-the-tasks
#define SOLUTION_CPP_FOLDER_NAME_ID_5857 number-of-unique-good-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_5867 reverse-prefix-of-word
#define SOLUTION_CPP_FOLDER_NAME_ID_5868 number-of-pairs-of-interchangeable-rectangles
#define SOLUTION_CPP_FOLDER_NAME_ID_5869 maximum-product-of-the-length-of-two-palindromic-subsequences
#define SOLUTION_CPP_FOLDER_NAME_ID_5870 smallest-missing-genetic-value-in-each-subtree
#define SOLUTION_CPP_FOLDER_NAME_ID_5914 smallest-index-with-equal-value
#define SOLUTION_CPP_FOLDER_NAME_ID_5915 find-the-minimum-and-maximum-number-of-nodes-between-critical-points
#define SOLUTION_CPP_FOLDER_NAME_ID_5916 minimum-operations-to-convert-number
#define SOLUTION_CPP_FOLDER_NAME_ID_5917 check-if-an-original-string-exists-given-two-encoded-strings
#define SOLUTION_CPP_FOLDER_NAME_ID_5918 count-vowel-substrings-of-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_5919 vowels-of-all-substrings
#define SOLUTION_CPP_FOLDER_NAME_ID_5920 minimized-maximum-of-products-distributed-to-any-store
#define SOLUTION_CPP_FOLDER_NAME_ID_5921 maximum-path-quality-of-a-graph
#define SOLUTION_CPP_FOLDER_NAME_ID_5938 find-target-indices-after-sorting-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5939 k-radius-subarray-averages
#define SOLUTION_CPP_FOLDER_NAME_ID_5940 removing-minimum-and-maximum-from-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5941 find-all-people-with-secret
#define SOLUTION_CPP_FOLDER_NAME_ID_5952 rings-and-rods
#define SOLUTION_CPP_FOLDER_NAME_ID_5953 sum-of-subarray-ranges
#define SOLUTION_CPP_FOLDER_NAME_ID_5954 watering-plants-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_5955 maximum-fruits-harvested-after-at-most-k-steps
#define SOLUTION_CPP_FOLDER_NAME_ID_5956 find-first-palindromic-string-in-the-array
#define SOLUTION_CPP_FOLDER_NAME_ID_5957 adding-spaces-to-a-string
#define SOLUTION_CPP_FOLDER_NAME_ID_5958 number-of-smooth-descent-periods-of-a-stock
#define SOLUTION_CPP_FOLDER_NAME_ID_5959 minimum-operations-to-make-the-array-k-increasing
#define SOLUTION_CPP_FOLDER_NAME_ID_5967 check-if-all-as-appears-before-all-bs
#define SOLUTION_CPP_FOLDER_NAME_ID_5968 number-of-laser-beams-in-a-bank
#define SOLUTION_CPP_FOLDER_NAME_ID_5969 destroying-asteroids
#define SOLUTION_CPP_FOLDER_NAME_ID_5970 maximum-employees-to-be-invited-to-a-meeting
#define SOLUTION_CPP_FOLDER_NAME_ID_5976 check-if-every-row-and-column-contains-all-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_5977 minimum-swaps-to-group-all-1s-together-ii
#define SOLUTION_CPP_FOLDER_NAME_ID_5978 count-words-obtained-after-adding-a-letter
#define SOLUTION_CPP_FOLDER_NAME_ID_5979 earliest-possible-day-of-full-bloom
#define SOLUTION_CPP_FOLDER_NAME_ID_5980 divide-a-string-into-groups-of-size-k
#define SOLUTION_CPP_FOLDER_NAME_ID_5982 solving-questions-with-brainpower
#define SOLUTION_CPP_FOLDER_NAME_ID_5983 maximum-running-time-of-n-computers
#define SOLUTION_CPP_FOLDER_NAME_ID_6000 sort-even-and-odd-indices-independently
#define SOLUTION_CPP_FOLDER_NAME_ID_6001 smallest-value-of-the-rearranged-number
#define SOLUTION_CPP_FOLDER_NAME_ID_6002 design-bitset
#define SOLUTION_CPP_FOLDER_NAME_ID_6003 minimum-time-to-remove-all-cars-containing-illegal-goods
#define SOLUTION_CPP_FOLDER_NAME_ID_100263 happy-new-year-2020-bomb
#define SOLUTION_CPP_FOLDER_NAME_ID_100264 how-many-apples-lc
#define SOLUTION_CPP_FOLDER_NAME_ID_100265 qqqqqqqqqqqqqqqys-warm-up-question
#define SOLUTION_CPP_FOLDER_NAME_ID_100266 one-day-of-otaku
#define SOLUTION_CPP_FOLDER_NAME_ID_100267 collect-beads
#define SOLUTION_CPP_FOLDER_NAME_ID_100269 werewolves-of-leetcode
#define SOLUTION_CPP_FOLDER_NAME_ID_100272 happy-new-year-lol
#define SOLUTION_CPP_FOLDER_NAME_ID_1000002 find-hidden-info-UGC
#define SOLUTION_CPP_FOLDER_NAME_ID_1000080 WqXACV
#define SOLUTION_CPP_FOLDER_NAME_ID_1000081 YesdPw
#define SOLUTION_CPP_FOLDER_NAME_ID_1000082 Ju9Xwi
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_01 guess-numbers
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_02 deep-dark-fraction
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_03 programmable-robot
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_04 broken-board-dominoes
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_05 coin-bonus
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_06 na-ying-bi
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_07 chuan-di-xin-xi
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_08 ju-qing-hong-fa-shi-jian
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_09 zui-xiao-tiao-yue-ci-shu
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_10 er-cha-shu-ren-wu-diao-du
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_11 qi-wang-ge-shu-tong-ji
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_12 xiao-zhang-shua-ti-ji-hua
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_13 xun-bao
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_14 qie-fen-shu-zu
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_15 you-le-yuan-de-mi-gong
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_16 you-le-yuan-de-you-lan-ji-hua
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_17 nGK0Fy
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_18 2vYnGI
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_19 UlBDOe
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_20 meChtZ
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_21 Za25hA
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_22 ccw6C7
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_23 er94lq
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_24 5TxKeK
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_25 Uh984O
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_26 hSRGyL
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_27 IQvJ9i
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_28 4xy4Wx
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_29 SNJvJP
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_30 p0NxJO
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_31 Db3wC1
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_32 t3fKg1
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_33 o8SXZn
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_34 er-cha-shu-ran-se-UGC
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_35 DFPeFJ
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_36 Up5XYM
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_37 zui-xiao-ju-xing-mian-ji
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_38 7rLGCR
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_39 0jQkd0
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_40 uOAnQW
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_41 fHi6rV
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_42 vFjcfV
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_43 Y1VbOX
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_44 sZ59z6
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_45 kplEvH
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_46 05ZEDJ
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_47 oPs9Bm
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_48 fsa7oZ
#define SOLUTION_CPP_FOLDER_NAME_ID_LCP_49 K8GULz
|
c4881a954b571d8fb864761a1e4b38e88047aa26
|
7744859512f027ef0da8b1bde0f8518e631b98eb
|
/soh/assets/objects/object_gi_shield_3/object_gi_shield_3.h
|
dc7cdc4c0ea4d5467c7516e52f39a49abe552e17
|
[] |
no_license
|
HarbourMasters/Shipwright
|
7f70b9470e4f9a117f3fe2d6e4deb776b8742182
|
0e7c6585239c0d7ea2c039b8b8cb7eaedf8928a9
|
refs/heads/develop
| 2023-08-31T20:50:56.253521
| 2023-08-30T17:34:06
| 2023-08-30T17:34:06
| 472,575,717
| 2,104
| 459
| null | 2023-09-14T20:29:01
| 2022-03-22T01:42:52
|
C
|
UTF-8
|
C
| false
| false
| 784
|
h
|
object_gi_shield_3.h
|
#pragma once
#include "align_asset_macro.h"
#define dgGiMirrorShieldDL "__OTR__objects/object_gi_shield_3/gGiMirrorShieldDL"
static const ALIGN_ASSET(2) char gGiMirrorShieldDL[] = dgGiMirrorShieldDL;
#define dgGiMirrorShieldSymbolDL "__OTR__objects/object_gi_shield_3/gGiMirrorShieldSymbolDL"
static const ALIGN_ASSET(2) char gGiMirrorShieldSymbolDL[] = dgGiMirrorShieldSymbolDL;
#define dobject_gi_shield_3Tex_000000 "__OTR__objects/object_gi_shield_3/object_gi_shield_3Tex_000000"
static const ALIGN_ASSET(2) char object_gi_shield_3Tex_000000[] = dobject_gi_shield_3Tex_000000;
#define dobject_gi_shield_3Tex_000400 "__OTR__objects/object_gi_shield_3/object_gi_shield_3Tex_000400"
static const ALIGN_ASSET(2) char object_gi_shield_3Tex_000400[] = dobject_gi_shield_3Tex_000400;
|
e0ce36a160dc6138ca7eda4c04f1bc55850c837b
|
99bdb3251fecee538e0630f15f6574054dfc1468
|
/bsp/nuvoton/libraries/ma35/StdDriver/inc/nu_gpio.h
|
ad033cb432d91f9923fa518b64fa6d7a416f1c3b
|
[
"Zlib",
"LicenseRef-scancode-proprietary-license",
"MIT",
"BSD-3-Clause",
"X11",
"BSD-4-Clause-UC",
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] |
permissive
|
RT-Thread/rt-thread
|
03a7c52c2aeb1b06a544143b0e803d72f47d1ece
|
3602f891211904a27dcbd51e5ba72fefce7326b2
|
refs/heads/master
| 2023-09-01T04:10:20.295801
| 2023-08-31T16:20:55
| 2023-08-31T16:20:55
| 7,408,108
| 9,599
| 5,805
|
Apache-2.0
| 2023-09-14T13:37:26
| 2013-01-02T14:49:21
|
C
|
UTF-8
|
C
| false
| false
| 41,663
|
h
|
nu_gpio.h
|
/**************************************************************************//**
* @file GPIO.h
* @brief GPIO driver header file
*
* SPDX-License-Identifier: Apache-2.0
* @copyright (C) 2020 Nuvoton Technology Corp. All rights reserved.
******************************************************************************/
#ifndef __NU_GPIO_H__
#define __NU_GPIO_H__
#ifdef __cplusplus
extern "C"
{
#endif
/** @addtogroup Standard_Driver Standard Driver
@{
*/
/** @addtogroup GPIO_Driver GPIO Driver
@{
*/
/** @addtogroup GPIO_EXPORTED_CONSTANTS GPIO Exported Constants
@{
*/
#define GPIO_PIN_MAX 16UL /*!< Specify Maximum Pins of Each GPIO Port \hideinitializer */
/*---------------------------------------------------------------------------------------------------------*/
/* GPIO_MODE Constant Definitions */
/*---------------------------------------------------------------------------------------------------------*/
#define GPIO_MODE_INPUT 0x0UL /*!< Input Mode \hideinitializer */
#define GPIO_MODE_OUTPUT 0x1UL /*!< Output Mode \hideinitializer */
#define GPIO_MODE_OPEN_DRAIN 0x2UL /*!< Open-Drain Mode \hideinitializer */
#define GPIO_MODE_QUASI 0x3UL /*!< Quasi-bidirectional Mode \hideinitializer */
/*---------------------------------------------------------------------------------------------------------*/
/* GPIO Interrupt Type Constant Definitions */
/*---------------------------------------------------------------------------------------------------------*/
#define GPIO_INT_RISING 0x00010000UL /*!< Interrupt enable by Input Rising Edge \hideinitializer */
#define GPIO_INT_FALLING 0x00000001UL /*!< Interrupt enable by Input Falling Edge \hideinitializer */
#define GPIO_INT_BOTH_EDGE 0x00010001UL /*!< Interrupt enable by both Rising Edge and Falling Edge \hideinitializer */
#define GPIO_INT_HIGH 0x01010000UL /*!< Interrupt enable by Level-High \hideinitializer */
#define GPIO_INT_LOW 0x01000001UL /*!< Interrupt enable by Level-Level \hideinitializer */
/*---------------------------------------------------------------------------------------------------------*/
/* GPIO_INTTYPE Constant Definitions */
/*---------------------------------------------------------------------------------------------------------*/
#define GPIO_INTTYPE_EDGE 0UL /*!< GPIO_INTTYPE Setting for Edge Trigger Mode \hideinitializer */
#define GPIO_INTTYPE_LEVEL 1UL /*!< GPIO_INTTYPE Setting for Edge Level Mode \hideinitializer */
/*---------------------------------------------------------------------------------------------------------*/
/* GPIO Slew Rate Type Constant Definitions */
/*---------------------------------------------------------------------------------------------------------*/
#define GPIO_SLEWCTL_NORMAL 0x0UL /*!< GPIO slew setting for normal Mode \hideinitializer */
#define GPIO_SLEWCTL_HIGH 0x1UL /*!< GPIO slew setting for high Mode \hideinitializer */
#define GPIO_SLEWCTL_FAST 0x2UL /*!< GPIO slew setting for fast Mode \hideinitializer */
/*---------------------------------------------------------------------------------------------------------*/
/* GPIO Pull-up And Pull-down Type Constant Definitions */
/*---------------------------------------------------------------------------------------------------------*/
#define GPIO_PUSEL_DISABLE 0x0UL /*!< GPIO PUSEL setting for Disable Mode \hideinitializer */
#define GPIO_PUSEL_PULL_UP 0x1UL /*!< GPIO PUSEL setting for Pull-up Mode \hideinitializer */
#define GPIO_PUSEL_PULL_DOWN 0x2UL /*!< GPIO PUSEL setting for Pull-down Mode \hideinitializer */
/*---------------------------------------------------------------------------------------------------------*/
/* GPIO_DBCTL Constant Definitions */
/*---------------------------------------------------------------------------------------------------------*/
#define GPIO_DBCTL_ICLK_ON 0x00000020UL /*!< GPIO_DBCTL setting for all IO pins edge detection circuit is always active after reset \hideinitializer */
#define GPIO_DBCTL_ICLK_OFF 0x00000000UL /*!< GPIO_DBCTL setting for edge detection circuit is active only if IO pin corresponding GPIOx_IEN bit is set to 1 \hideinitializer */
#define GPIO_DBCTL_DBCLKSRC_LIRC 0x00000010UL /*!< GPIO_DBCTL setting for de-bounce counter clock source is the internal 10 kHz \hideinitializer */
#define GPIO_DBCTL_DBCLKSRC_HXT 0x00000000UL /*!< GPIO_DBCTL setting for de-bounce counter clock source is the HCLK \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_1 0x00000000UL /*!< GPIO_DBCTL setting for sampling cycle = 1 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_2 0x00000001UL /*!< GPIO_DBCTL setting for sampling cycle = 2 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_4 0x00000002UL /*!< GPIO_DBCTL setting for sampling cycle = 4 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_8 0x00000003UL /*!< GPIO_DBCTL setting for sampling cycle = 8 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_16 0x00000004UL /*!< GPIO_DBCTL setting for sampling cycle = 16 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_32 0x00000005UL /*!< GPIO_DBCTL setting for sampling cycle = 32 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_64 0x00000006UL /*!< GPIO_DBCTL setting for sampling cycle = 64 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_128 0x00000007UL /*!< GPIO_DBCTL setting for sampling cycle = 128 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_256 0x00000008UL /*!< GPIO_DBCTL setting for sampling cycle = 256 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_512 0x00000009UL /*!< GPIO_DBCTL setting for sampling cycle = 512 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_1024 0x0000000AUL /*!< GPIO_DBCTL setting for sampling cycle = 1024 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_2048 0x0000000BUL /*!< GPIO_DBCTL setting for sampling cycle = 2048 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_4096 0x0000000CUL /*!< GPIO_DBCTL setting for sampling cycle = 4096 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_8192 0x0000000DUL /*!< GPIO_DBCTL setting for sampling cycle = 8192 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_16384 0x0000000EUL /*!< GPIO_DBCTL setting for sampling cycle = 16384 clocks \hideinitializer */
#define GPIO_DBCTL_DBCLKSEL_32768 0x0000000FUL /*!< GPIO_DBCTL setting for sampling cycle = 32768 clocks \hideinitializer */
/* Define GPIO Pin Data Input/Output. It could be used to control each I/O pin by pin address mapping.
Example 1:
PA0 = 1;
It is used to set GPIO PA.0 to high;
Example 2:
if (PA0)
PA0 = 0;
If GPIO PA.0 pin status is high, then set GPIO PA.0 data output to low.
*/
#define GPIO_PIN_DATA(port, pin) (*((volatile uint32_t *)((GPIO_PIN_DATA_BASE+(0x40*(port))) + ((pin)<<2)))) /*!< Pin Data Input/Output \hideinitializer */
#define PA0 GPIO_PIN_DATA(0, 0 ) /*!< Specify PA.0 Pin Data Input/Output \hideinitializer */
#define PA1 GPIO_PIN_DATA(0, 1 ) /*!< Specify PA.1 Pin Data Input/Output \hideinitializer */
#define PA2 GPIO_PIN_DATA(0, 2 ) /*!< Specify PA.2 Pin Data Input/Output \hideinitializer */
#define PA3 GPIO_PIN_DATA(0, 3 ) /*!< Specify PA.3 Pin Data Input/Output \hideinitializer */
#define PA4 GPIO_PIN_DATA(0, 4 ) /*!< Specify PA.4 Pin Data Input/Output \hideinitializer */
#define PA5 GPIO_PIN_DATA(0, 5 ) /*!< Specify PA.5 Pin Data Input/Output \hideinitializer */
#define PA6 GPIO_PIN_DATA(0, 6 ) /*!< Specify PA.6 Pin Data Input/Output \hideinitializer */
#define PA7 GPIO_PIN_DATA(0, 7 ) /*!< Specify PA.7 Pin Data Input/Output \hideinitializer */
#define PA8 GPIO_PIN_DATA(0, 8 ) /*!< Specify PA.8 Pin Data Input/Output \hideinitializer */
#define PA9 GPIO_PIN_DATA(0, 9 ) /*!< Specify PA.9 Pin Data Input/Output \hideinitializer */
#define PA10 GPIO_PIN_DATA(0, 10) /*!< Specify PA.10 Pin Data Input/Output \hideinitializer */
#define PA11 GPIO_PIN_DATA(0, 11) /*!< Specify PA.11 Pin Data Input/Output \hideinitializer */
#define PA12 GPIO_PIN_DATA(0, 12) /*!< Specify PA.12 Pin Data Input/Output \hideinitializer */
#define PA13 GPIO_PIN_DATA(0, 13) /*!< Specify PA.13 Pin Data Input/Output \hideinitializer */
#define PA14 GPIO_PIN_DATA(0, 14) /*!< Specify PA.14 Pin Data Input/Output \hideinitializer */
#define PA15 GPIO_PIN_DATA(0, 15) /*!< Specify PA.15 Pin Data Input/Output \hideinitializer */
#define PB0 GPIO_PIN_DATA(1, 0 ) /*!< Specify PB.0 Pin Data Input/Output \hideinitializer */
#define PB1 GPIO_PIN_DATA(1, 1 ) /*!< Specify PB.1 Pin Data Input/Output \hideinitializer */
#define PB2 GPIO_PIN_DATA(1, 2 ) /*!< Specify PB.2 Pin Data Input/Output \hideinitializer */
#define PB3 GPIO_PIN_DATA(1, 3 ) /*!< Specify PB.3 Pin Data Input/Output \hideinitializer */
#define PB4 GPIO_PIN_DATA(1, 4 ) /*!< Specify PB.4 Pin Data Input/Output \hideinitializer */
#define PB5 GPIO_PIN_DATA(1, 5 ) /*!< Specify PB.5 Pin Data Input/Output \hideinitializer */
#define PB6 GPIO_PIN_DATA(1, 6 ) /*!< Specify PB.6 Pin Data Input/Output \hideinitializer */
#define PB7 GPIO_PIN_DATA(1, 7 ) /*!< Specify PB.7 Pin Data Input/Output \hideinitializer */
#define PB8 GPIO_PIN_DATA(1, 8 ) /*!< Specify PB.8 Pin Data Input/Output \hideinitializer */
#define PB9 GPIO_PIN_DATA(1, 9 ) /*!< Specify PB.9 Pin Data Input/Output \hideinitializer */
#define PB10 GPIO_PIN_DATA(1, 10) /*!< Specify PB.10 Pin Data Input/Output \hideinitializer */
#define PB11 GPIO_PIN_DATA(1, 11) /*!< Specify PB.11 Pin Data Input/Output \hideinitializer */
#define PB12 GPIO_PIN_DATA(1, 12) /*!< Specify PB.12 Pin Data Input/Output \hideinitializer */
#define PB13 GPIO_PIN_DATA(1, 13) /*!< Specify PB.13 Pin Data Input/Output \hideinitializer */
#define PB14 GPIO_PIN_DATA(1, 14) /*!< Specify PB.14 Pin Data Input/Output \hideinitializer */
#define PB15 GPIO_PIN_DATA(1, 15) /*!< Specify PB.15 Pin Data Input/Output \hideinitializer */
#define PC0 GPIO_PIN_DATA(2, 0 ) /*!< Specify PC.0 Pin Data Input/Output \hideinitializer */
#define PC1 GPIO_PIN_DATA(2, 1 ) /*!< Specify PC.1 Pin Data Input/Output \hideinitializer */
#define PC2 GPIO_PIN_DATA(2, 2 ) /*!< Specify PC.2 Pin Data Input/Output \hideinitializer */
#define PC3 GPIO_PIN_DATA(2, 3 ) /*!< Specify PC.3 Pin Data Input/Output \hideinitializer */
#define PC4 GPIO_PIN_DATA(2, 4 ) /*!< Specify PC.4 Pin Data Input/Output \hideinitializer */
#define PC5 GPIO_PIN_DATA(2, 5 ) /*!< Specify PC.5 Pin Data Input/Output \hideinitializer */
#define PC6 GPIO_PIN_DATA(2, 6 ) /*!< Specify PC.6 Pin Data Input/Output \hideinitializer */
#define PC7 GPIO_PIN_DATA(2, 7 ) /*!< Specify PC.7 Pin Data Input/Output \hideinitializer */
#define PC8 GPIO_PIN_DATA(2, 8 ) /*!< Specify PC.8 Pin Data Input/Output \hideinitializer */
#define PC9 GPIO_PIN_DATA(2, 9 ) /*!< Specify PC.9 Pin Data Input/Output \hideinitializer */
#define PC10 GPIO_PIN_DATA(2, 10) /*!< Specify PC.10 Pin Data Input/Output \hideinitializer */
#define PC11 GPIO_PIN_DATA(2, 11) /*!< Specify PC.11 Pin Data Input/Output \hideinitializer */
#define PC12 GPIO_PIN_DATA(2, 12) /*!< Specify PC.12 Pin Data Input/Output \hideinitializer */
#define PC13 GPIO_PIN_DATA(2, 13) /*!< Specify PC.13 Pin Data Input/Output \hideinitializer */
#define PC14 GPIO_PIN_DATA(2, 14) /*!< Specify PC.14 Pin Data Input/Output \hideinitializer */
#define PD0 GPIO_PIN_DATA(3, 0 ) /*!< Specify PD.0 Pin Data Input/Output \hideinitializer */
#define PD1 GPIO_PIN_DATA(3, 1 ) /*!< Specify PD.1 Pin Data Input/Output \hideinitializer */
#define PD2 GPIO_PIN_DATA(3, 2 ) /*!< Specify PD.2 Pin Data Input/Output \hideinitializer */
#define PD3 GPIO_PIN_DATA(3, 3 ) /*!< Specify PD.3 Pin Data Input/Output \hideinitializer */
#define PD4 GPIO_PIN_DATA(3, 4 ) /*!< Specify PD.4 Pin Data Input/Output \hideinitializer */
#define PD5 GPIO_PIN_DATA(3, 5 ) /*!< Specify PD.5 Pin Data Input/Output \hideinitializer */
#define PD6 GPIO_PIN_DATA(3, 6 ) /*!< Specify PD.6 Pin Data Input/Output \hideinitializer */
#define PD7 GPIO_PIN_DATA(3, 7 ) /*!< Specify PD.7 Pin Data Input/Output \hideinitializer */
#define PD8 GPIO_PIN_DATA(3, 8 ) /*!< Specify PD.8 Pin Data Input/Output \hideinitializer */
#define PD9 GPIO_PIN_DATA(3, 9 ) /*!< Specify PD.9 Pin Data Input/Output \hideinitializer */
#define PD10 GPIO_PIN_DATA(3, 10) /*!< Specify PD.10 Pin Data Input/Output \hideinitializer */
#define PD11 GPIO_PIN_DATA(3, 11) /*!< Specify PD.11 Pin Data Input/Output \hideinitializer */
#define PD12 GPIO_PIN_DATA(3, 12) /*!< Specify PD.12 Pin Data Input/Output \hideinitializer */
#define PD13 GPIO_PIN_DATA(3, 13) /*!< Specify PD.13 Pin Data Input/Output \hideinitializer */
#define PD14 GPIO_PIN_DATA(3, 14) /*!< Specify PD.14 Pin Data Input/Output \hideinitializer */
#define PE0 GPIO_PIN_DATA(4, 0 ) /*!< Specify PE.0 Pin Data Input/Output \hideinitializer */
#define PE1 GPIO_PIN_DATA(4, 1 ) /*!< Specify PE.1 Pin Data Input/Output \hideinitializer */
#define PE2 GPIO_PIN_DATA(4, 2 ) /*!< Specify PE.2 Pin Data Input/Output \hideinitializer */
#define PE3 GPIO_PIN_DATA(4, 3 ) /*!< Specify PE.3 Pin Data Input/Output \hideinitializer */
#define PE4 GPIO_PIN_DATA(4, 4 ) /*!< Specify PE.4 Pin Data Input/Output \hideinitializer */
#define PE5 GPIO_PIN_DATA(4, 5 ) /*!< Specify PE.5 Pin Data Input/Output \hideinitializer */
#define PE6 GPIO_PIN_DATA(4, 6 ) /*!< Specify PE.6 Pin Data Input/Output \hideinitializer */
#define PE7 GPIO_PIN_DATA(4, 7 ) /*!< Specify PE.7 Pin Data Input/Output \hideinitializer */
#define PE8 GPIO_PIN_DATA(4, 8 ) /*!< Specify PE.8 Pin Data Input/Output \hideinitializer */
#define PE9 GPIO_PIN_DATA(4, 9 ) /*!< Specify PE.9 Pin Data Input/Output \hideinitializer */
#define PE10 GPIO_PIN_DATA(4, 10) /*!< Specify PE.10 Pin Data Input/Output \hideinitializer */
#define PE11 GPIO_PIN_DATA(4, 11) /*!< Specify PE.11 Pin Data Input/Output \hideinitializer */
#define PE12 GPIO_PIN_DATA(4, 12) /*!< Specify PE.12 Pin Data Input/Output \hideinitializer */
#define PE13 GPIO_PIN_DATA(4, 13) /*!< Specify PE.13 Pin Data Input/Output \hideinitializer */
#define PE14 GPIO_PIN_DATA(4, 14) /*!< Specify PE.14 Pin Data Input/Output \hideinitializer */
#define PE15 GPIO_PIN_DATA(4, 15) /*!< Specify PE.15 Pin Data Input/Output \hideinitializer */
#define PF0 GPIO_PIN_DATA(5, 0 ) /*!< Specify PF.0 Pin Data Input/Output \hideinitializer */
#define PF1 GPIO_PIN_DATA(5, 1 ) /*!< Specify PF.1 Pin Data Input/Output \hideinitializer */
#define PF2 GPIO_PIN_DATA(5, 2 ) /*!< Specify PF.2 Pin Data Input/Output \hideinitializer */
#define PF3 GPIO_PIN_DATA(5, 3 ) /*!< Specify PF.3 Pin Data Input/Output \hideinitializer */
#define PF4 GPIO_PIN_DATA(5, 4 ) /*!< Specify PF.4 Pin Data Input/Output \hideinitializer */
#define PF5 GPIO_PIN_DATA(5, 5 ) /*!< Specify PF.5 Pin Data Input/Output \hideinitializer */
#define PF6 GPIO_PIN_DATA(5, 6 ) /*!< Specify PF.6 Pin Data Input/Output \hideinitializer */
#define PF7 GPIO_PIN_DATA(5, 7 ) /*!< Specify PF.7 Pin Data Input/Output \hideinitializer */
#define PF8 GPIO_PIN_DATA(5, 8 ) /*!< Specify PF.8 Pin Data Input/Output \hideinitializer */
#define PF9 GPIO_PIN_DATA(5, 9 ) /*!< Specify PF.9 Pin Data Input/Output \hideinitializer */
#define PF10 GPIO_PIN_DATA(5, 10) /*!< Specify PF.10 Pin Data Input/Output \hideinitializer */
#define PF11 GPIO_PIN_DATA(5, 11) /*!< Specify PF.11 Pin Data Input/Output \hideinitializer */
#define PG0 GPIO_PIN_DATA(6, 0 ) /*!< Specify PG.0 Pin Data Input/Output \hideinitializer */
#define PG1 GPIO_PIN_DATA(6, 1 ) /*!< Specify PG.1 Pin Data Input/Output \hideinitializer */
#define PG2 GPIO_PIN_DATA(6, 2 ) /*!< Specify PG.2 Pin Data Input/Output \hideinitializer */
#define PG3 GPIO_PIN_DATA(6, 3 ) /*!< Specify PG.3 Pin Data Input/Output \hideinitializer */
#define PG4 GPIO_PIN_DATA(6, 4 ) /*!< Specify PG.4 Pin Data Input/Output \hideinitializer */
#define PG5 GPIO_PIN_DATA(6, 5 ) /*!< Specify PG.5 Pin Data Input/Output \hideinitializer */
#define PG6 GPIO_PIN_DATA(6, 6 ) /*!< Specify PG.6 Pin Data Input/Output \hideinitializer */
#define PG7 GPIO_PIN_DATA(6, 7 ) /*!< Specify PG.7 Pin Data Input/Output \hideinitializer */
#define PG8 GPIO_PIN_DATA(6, 8 ) /*!< Specify PG.8 Pin Data Input/Output \hideinitializer */
#define PG9 GPIO_PIN_DATA(6, 9 ) /*!< Specify PG.9 Pin Data Input/Output \hideinitializer */
#define PG10 GPIO_PIN_DATA(6, 10) /*!< Specify PG.10 Pin Data Input/Output \hideinitializer */
#define PG11 GPIO_PIN_DATA(6, 11) /*!< Specify PG.11 Pin Data Input/Output \hideinitializer */
#define PG12 GPIO_PIN_DATA(6, 12) /*!< Specify PG.12 Pin Data Input/Output \hideinitializer */
#define PG13 GPIO_PIN_DATA(6, 13) /*!< Specify PG.13 Pin Data Input/Output \hideinitializer */
#define PG14 GPIO_PIN_DATA(6, 14) /*!< Specify PG.14 Pin Data Input/Output \hideinitializer */
#define PG15 GPIO_PIN_DATA(6, 15) /*!< Specify PG.15 Pin Data Input/Output \hideinitializer */
#define PH0 GPIO_PIN_DATA(7, 0 ) /*!< Specify PH.0 Pin Data Input/Output \hideinitializer */
#define PH1 GPIO_PIN_DATA(7, 1 ) /*!< Specify PH.1 Pin Data Input/Output \hideinitializer */
#define PH2 GPIO_PIN_DATA(7, 2 ) /*!< Specify PH.2 Pin Data Input/Output \hideinitializer */
#define PH3 GPIO_PIN_DATA(7, 3 ) /*!< Specify PH.3 Pin Data Input/Output \hideinitializer */
#define PH4 GPIO_PIN_DATA(7, 4 ) /*!< Specify PH.4 Pin Data Input/Output \hideinitializer */
#define PH5 GPIO_PIN_DATA(7, 5 ) /*!< Specify PH.5 Pin Data Input/Output \hideinitializer */
#define PH6 GPIO_PIN_DATA(7, 6 ) /*!< Specify PH.6 Pin Data Input/Output \hideinitializer */
#define PH7 GPIO_PIN_DATA(7, 7 ) /*!< Specify PH.7 Pin Data Input/Output \hideinitializer */
#define PH8 GPIO_PIN_DATA(7, 8 ) /*!< Specify PH.8 Pin Data Input/Output \hideinitializer */
#define PH9 GPIO_PIN_DATA(7, 9 ) /*!< Specify PH.9 Pin Data Input/Output \hideinitializer */
#define PH10 GPIO_PIN_DATA(7, 10) /*!< Specify PH.10 Pin Data Input/Output \hideinitializer */
#define PH11 GPIO_PIN_DATA(7, 11) /*!< Specify PH.11 Pin Data Input/Output \hideinitializer */
#define PH12 GPIO_PIN_DATA(7, 12) /*!< Specify PH.12 Pin Data Input/Output \hideinitializer */
#define PH13 GPIO_PIN_DATA(7, 13) /*!< Specify PH.13 Pin Data Input/Output \hideinitializer */
#define PH14 GPIO_PIN_DATA(7, 14) /*!< Specify PH.14 Pin Data Input/Output \hideinitializer */
#define PH15 GPIO_PIN_DATA(7, 15) /*!< Specify PH.15 Pin Data Input/Output \hideinitializer */
#define PI0 GPIO_PIN_DATA(8, 0 ) /*!< Specify PI.0 Pin Data Input/Output \hideinitializer */
#define PI1 GPIO_PIN_DATA(8, 1 ) /*!< Specify PI.1 Pin Data Input/Output \hideinitializer */
#define PI2 GPIO_PIN_DATA(8, 2 ) /*!< Specify PI.2 Pin Data Input/Output \hideinitializer */
#define PI3 GPIO_PIN_DATA(8, 3 ) /*!< Specify PI.3 Pin Data Input/Output \hideinitializer */
#define PI4 GPIO_PIN_DATA(8, 4 ) /*!< Specify PI.4 Pin Data Input/Output \hideinitializer */
#define PI5 GPIO_PIN_DATA(8, 5 ) /*!< Specify PI.5 Pin Data Input/Output \hideinitializer */
#define PI6 GPIO_PIN_DATA(8, 6 ) /*!< Specify PI.6 Pin Data Input/Output \hideinitializer */
#define PI7 GPIO_PIN_DATA(8, 7 ) /*!< Specify PI.7 Pin Data Input/Output \hideinitializer */
#define PI8 GPIO_PIN_DATA(8, 8 ) /*!< Specify PI.8 Pin Data Input/Output \hideinitializer */
#define PI9 GPIO_PIN_DATA(8, 9 ) /*!< Specify PI.9 Pin Data Input/Output \hideinitializer */
#define PI10 GPIO_PIN_DATA(8, 10) /*!< Specify PI.10 Pin Data Input/Output \hideinitializer */
#define PI11 GPIO_PIN_DATA(8, 11) /*!< Specify PI.11 Pin Data Input/Output \hideinitializer */
#define PI12 GPIO_PIN_DATA(8, 12) /*!< Specify PI.12 Pin Data Input/Output \hideinitializer */
#define PI13 GPIO_PIN_DATA(8, 13) /*!< Specify PI.13 Pin Data Input/Output \hideinitializer */
#define PI14 GPIO_PIN_DATA(8, 14) /*!< Specify PI.14 Pin Data Input/Output \hideinitializer */
#define PI15 GPIO_PIN_DATA(8, 15) /*!< Specify PI.15 Pin Data Input/Output \hideinitializer */
#define PJ0 GPIO_PIN_DATA(9, 0 ) /*!< Specify PJ.0 Pin Data Input/Output \hideinitializer */
#define PJ1 GPIO_PIN_DATA(9, 1 ) /*!< Specify PJ.1 Pin Data Input/Output \hideinitializer */
#define PJ2 GPIO_PIN_DATA(9, 2 ) /*!< Specify PJ.2 Pin Data Input/Output \hideinitializer */
#define PJ3 GPIO_PIN_DATA(9, 3 ) /*!< Specify PJ.3 Pin Data Input/Output \hideinitializer */
#define PJ4 GPIO_PIN_DATA(9, 4 ) /*!< Specify PJ.4 Pin Data Input/Output \hideinitializer */
#define PJ5 GPIO_PIN_DATA(9, 5 ) /*!< Specify PJ.5 Pin Data Input/Output \hideinitializer */
#define PJ6 GPIO_PIN_DATA(9, 6 ) /*!< Specify PJ.6 Pin Data Input/Output \hideinitializer */
#define PJ7 GPIO_PIN_DATA(9, 7 ) /*!< Specify PJ.7 Pin Data Input/Output \hideinitializer */
#define PJ8 GPIO_PIN_DATA(9, 8 ) /*!< Specify PJ.8 Pin Data Input/Output \hideinitializer */
#define PJ9 GPIO_PIN_DATA(9, 9 ) /*!< Specify PJ.9 Pin Data Input/Output \hideinitializer */
#define PJ10 GPIO_PIN_DATA(9, 10) /*!< Specify PJ.10 Pin Data Input/Output \hideinitializer */
#define PJ11 GPIO_PIN_DATA(9, 11) /*!< Specify PJ.11 Pin Data Input/Output \hideinitializer */
#define PJ12 GPIO_PIN_DATA(9, 12) /*!< Specify PJ.12 Pin Data Input/Output \hideinitializer */
#define PJ13 GPIO_PIN_DATA(9, 13) /*!< Specify PJ.13 Pin Data Input/Output \hideinitializer */
#define PJ14 GPIO_PIN_DATA(9, 14) /*!< Specify PJ.14 Pin Data Input/Output \hideinitializer */
#define PJ15 GPIO_PIN_DATA(9, 15) /*!< Specify PJ.15 Pin Data Input/Output \hideinitializer */
#define PK0 GPIO_PIN_DATA(10 , 0 ) /*!< Specify PK.0 Pin Data Input/Output \hideinitializer */
#define PK1 GPIO_PIN_DATA(10 , 1 ) /*!< Specify PK.1 Pin Data Input/Output \hideinitializer */
#define PK2 GPIO_PIN_DATA(10 , 2 ) /*!< Specify PK.2 Pin Data Input/Output \hideinitializer */
#define PK3 GPIO_PIN_DATA(10 , 3 ) /*!< Specify PK.3 Pin Data Input/Output \hideinitializer */
#define PK4 GPIO_PIN_DATA(10 , 4 ) /*!< Specify PK.4 Pin Data Input/Output \hideinitializer */
#define PK5 GPIO_PIN_DATA(10 , 5 ) /*!< Specify PK.5 Pin Data Input/Output \hideinitializer */
#define PK6 GPIO_PIN_DATA(10 , 6 ) /*!< Specify PK.6 Pin Data Input/Output \hideinitializer */
#define PK7 GPIO_PIN_DATA(10 , 7 ) /*!< Specify PK.7 Pin Data Input/Output \hideinitializer */
#define PK8 GPIO_PIN_DATA(10 , 8 ) /*!< Specify PK.8 Pin Data Input/Output \hideinitializer */
#define PK9 GPIO_PIN_DATA(10 , 9 ) /*!< Specify PK.9 Pin Data Input/Output \hideinitializer */
#define PK10 GPIO_PIN_DATA(10 , 10) /*!< Specify PK.10 Pin Data Input/Output \hideinitializer */
#define PK11 GPIO_PIN_DATA(10 , 11) /*!< Specify PK.11 Pin Data Input/Output \hideinitializer */
#define PK12 GPIO_PIN_DATA(10 , 12) /*!< Specify PK.12 Pin Data Input/Output \hideinitializer */
#define PK13 GPIO_PIN_DATA(10 , 13) /*!< Specify PK.13 Pin Data Input/Output \hideinitializer */
#define PK14 GPIO_PIN_DATA(10 , 14) /*!< Specify PK.14 Pin Data Input/Output \hideinitializer */
#define PK15 GPIO_PIN_DATA(10 , 15) /*!< Specify PK.15 Pin Data Input/Output \hideinitializer */
#define PL0 GPIO_PIN_DATA(11, 0 ) /*!< Specify PL.0 Pin Data Input/Output \hideinitializer */
#define PL1 GPIO_PIN_DATA(11, 1 ) /*!< Specify PL.1 Pin Data Input/Output \hideinitializer */
#define PL2 GPIO_PIN_DATA(11, 2 ) /*!< Specify PL.2 Pin Data Input/Output \hideinitializer */
#define PL3 GPIO_PIN_DATA(11, 3 ) /*!< Specify PL.3 Pin Data Input/Output \hideinitializer */
#define PL4 GPIO_PIN_DATA(11, 4 ) /*!< Specify PL.4 Pin Data Input/Output \hideinitializer */
#define PL5 GPIO_PIN_DATA(11, 5 ) /*!< Specify PL.5 Pin Data Input/Output \hideinitializer */
#define PL6 GPIO_PIN_DATA(11, 6 ) /*!< Specify PL.6 Pin Data Input/Output \hideinitializer */
#define PL7 GPIO_PIN_DATA(11, 7 ) /*!< Specify PL.7 Pin Data Input/Output \hideinitializer */
#define PL8 GPIO_PIN_DATA(11, 8 ) /*!< Specify PL.8 Pin Data Input/Output \hideinitializer */
#define PL9 GPIO_PIN_DATA(11, 9 ) /*!< Specify PL.9 Pin Data Input/Output \hideinitializer */
#define PL10 GPIO_PIN_DATA(11, 10) /*!< Specify PL.10 Pin Data Input/Output \hideinitializer */
#define PL11 GPIO_PIN_DATA(11, 11) /*!< Specify PL.11 Pin Data Input/Output \hideinitializer */
#define PL12 GPIO_PIN_DATA(11, 12) /*!< Specify PL.12 Pin Data Input/Output \hideinitializer */
#define PL13 GPIO_PIN_DATA(11, 13) /*!< Specify PL.13 Pin Data Input/Output \hideinitializer */
#define PL14 GPIO_PIN_DATA(11, 14) /*!< Specify PL.14 Pin Data Input/Output \hideinitializer */
#define PL15 GPIO_PIN_DATA(11, 15) /*!< Specify PL.15 Pin Data Input/Output \hideinitializer */
#define PM0 GPIO_PIN_DATA(12, 0 ) /*!< Specify PH.0 Pin Data Input/Output \hideinitializer */
#define PM1 GPIO_PIN_DATA(12, 1 ) /*!< Specify PH.1 Pin Data Input/Output \hideinitializer */
#define PM2 GPIO_PIN_DATA(12, 2 ) /*!< Specify PH.2 Pin Data Input/Output \hideinitializer */
#define PM3 GPIO_PIN_DATA(12, 3 ) /*!< Specify PH.3 Pin Data Input/Output \hideinitializer */
#define PM4 GPIO_PIN_DATA(12, 4 ) /*!< Specify PH.4 Pin Data Input/Output \hideinitializer */
#define PM5 GPIO_PIN_DATA(12, 5 ) /*!< Specify PH.5 Pin Data Input/Output \hideinitializer */
#define PM6 GPIO_PIN_DATA(12, 6 ) /*!< Specify PH.6 Pin Data Input/Output \hideinitializer */
#define PM7 GPIO_PIN_DATA(12, 7 ) /*!< Specify PH.7 Pin Data Input/Output \hideinitializer */
#define PM8 GPIO_PIN_DATA(12, 8 ) /*!< Specify PH.8 Pin Data Input/Output \hideinitializer */
#define PM9 GPIO_PIN_DATA(12, 9 ) /*!< Specify PH.9 Pin Data Input/Output \hideinitializer */
#define PM10 GPIO_PIN_DATA(12, 10) /*!< Specify PH.10 Pin Data Input/Output \hideinitializer */
#define PM11 GPIO_PIN_DATA(12, 11) /*!< Specify PH.11 Pin Data Input/Output \hideinitializer */
#define PM12 GPIO_PIN_DATA(12, 12) /*!< Specify PH.12 Pin Data Input/Output \hideinitializer */
#define PM13 GPIO_PIN_DATA(12, 13) /*!< Specify PH.13 Pin Data Input/Output \hideinitializer */
#define PM14 GPIO_PIN_DATA(12, 14) /*!< Specify PH.14 Pin Data Input/Output \hideinitializer */
#define PM15 GPIO_PIN_DATA(12, 15) /*!< Specify PH.15 Pin Data Input/Output \hideinitializer */
#define PN0 GPIO_PIN_DATA(13, 0 ) /*!< Specify PH.0 Pin Data Input/Output \hideinitializer */
#define PN1 GPIO_PIN_DATA(13, 1 ) /*!< Specify PH.1 Pin Data Input/Output \hideinitializer */
#define PN2 GPIO_PIN_DATA(13, 2 ) /*!< Specify PH.2 Pin Data Input/Output \hideinitializer */
#define PN3 GPIO_PIN_DATA(13, 3 ) /*!< Specify PH.3 Pin Data Input/Output \hideinitializer */
#define PN4 GPIO_PIN_DATA(13, 4 ) /*!< Specify PH.4 Pin Data Input/Output \hideinitializer */
#define PN5 GPIO_PIN_DATA(13, 5 ) /*!< Specify PH.5 Pin Data Input/Output \hideinitializer */
#define PN6 GPIO_PIN_DATA(13, 6 ) /*!< Specify PH.6 Pin Data Input/Output \hideinitializer */
#define PN7 GPIO_PIN_DATA(13, 7 ) /*!< Specify PH.7 Pin Data Input/Output \hideinitializer */
#define PN8 GPIO_PIN_DATA(13, 8 ) /*!< Specify PH.8 Pin Data Input/Output \hideinitializer */
#define PN9 GPIO_PIN_DATA(13, 9 ) /*!< Specify PH.9 Pin Data Input/Output \hideinitializer */
#define PN10 GPIO_PIN_DATA(13, 10) /*!< Specify PH.10 Pin Data Input/Output \hideinitializer */
#define PN11 GPIO_PIN_DATA(13, 11) /*!< Specify PH.11 Pin Data Input/Output \hideinitializer */
#define PN12 GPIO_PIN_DATA(13, 12) /*!< Specify PH.12 Pin Data Input/Output \hideinitializer */
#define PN13 GPIO_PIN_DATA(13, 13) /*!< Specify PH.13 Pin Data Input/Output \hideinitializer */
#define PN14 GPIO_PIN_DATA(13, 14) /*!< Specify PH.14 Pin Data Input/Output \hideinitializer */
#define PN15 GPIO_PIN_DATA(13, 15) /*!< Specify PH.15 Pin Data Input/Output \hideinitializer */
/*@}*/ /* end of group GPIO_EXPORTED_CONSTANTS */
/** @addtogroup GPIO_EXPORTED_FUNCTIONS GPIO Exported Functions
@{
*/
/**
* @brief Clear GPIO Pin Interrupt Flag
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
*
* @return None
*
* @details Clear the interrupt status of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_CLR_INT_FLAG(port, u32PinMask) ((port)->INTSRC = (u32PinMask))
/**
* @brief Disable Pin De-bounce Function
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
*
* @return None
*
* @details Disable the interrupt de-bounce function of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_DISABLE_DEBOUNCE(port, u32PinMask) ((port)->DBEN &= ~(u32PinMask))
/**
* @brief Enable Pin De-bounce Function
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG or PH.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
* @return None
*
* @details Enable the interrupt de-bounce function of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_ENABLE_DEBOUNCE(port, u32PinMask) ((port)->DBEN |= (u32PinMask))
/**
* @brief Disable I/O Digital Input Path
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
*
* @return None
*
* @details Disable I/O digital input path of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_DISABLE_DIGITAL_PATH(port, u32PinMask) ((port)->DINOFF |= ((u32PinMask)<<16))
/**
* @brief Enable I/O Digital Input Path
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG or PH.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
*
* @return None
*
* @details Enable I/O digital input path of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_ENABLE_DIGITAL_PATH(port, u32PinMask) ((port)->DINOFF &= ~((u32PinMask)<<16))
/**
* @brief Disable I/O DOUT mask
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
*
* @return None
*
* @details Disable I/O DOUT mask of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_DISABLE_DOUT_MASK(port, u32PinMask) ((port)->DATMSK &= ~(u32PinMask))
/**
* @brief Enable I/O DOUT mask
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG or PH.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
*
* @return None
*
* @details Enable I/O DOUT mask of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_ENABLE_DOUT_MASK(port, u32PinMask) ((port)->DATMSK |= (u32PinMask))
/**
* @brief Get GPIO Pin Interrupt Flag
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32PinMask The single or multiple pins of specified GPIO port.
* It could be BIT0 ~ BIT15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be BIT0 ~ BIT13 for PE GPIO port.
* It could be BIT0 ~ BIT11 for PG GPIO port.
*
* @retval 0 No interrupt at specified GPIO pin
* @retval 1 The specified GPIO pin generate an interrupt
*
* @details Get the interrupt status of specified GPIO pin.
* \hideinitializer
*/
#define GPIO_GET_INT_FLAG(port, u32PinMask) ((port)->INTSRC & (u32PinMask))
/**
* @brief Set De-bounce Sampling Cycle Time
*
* @param[in] u32Port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32ClkSrc The de-bounce counter clock source. It could be GPIO_DBCTL_DBCLKSRC_HXT or GPIO_DBCTL_DBCLKSRC_LIRC.
* @param[in] u32ClkSel The de-bounce sampling cycle selection. It could be
* - \ref GPIO_DBCTL_DBCLKSEL_1
* - \ref GPIO_DBCTL_DBCLKSEL_2
* - \ref GPIO_DBCTL_DBCLKSEL_4
* - \ref GPIO_DBCTL_DBCLKSEL_8
* - \ref GPIO_DBCTL_DBCLKSEL_16
* - \ref GPIO_DBCTL_DBCLKSEL_32
* - \ref GPIO_DBCTL_DBCLKSEL_64
* - \ref GPIO_DBCTL_DBCLKSEL_128
* - \ref GPIO_DBCTL_DBCLKSEL_256
* - \ref GPIO_DBCTL_DBCLKSEL_512
* - \ref GPIO_DBCTL_DBCLKSEL_1024
* - \ref GPIO_DBCTL_DBCLKSEL_2048
* - \ref GPIO_DBCTL_DBCLKSEL_4096
* - \ref GPIO_DBCTL_DBCLKSEL_8192
* - \ref GPIO_DBCTL_DBCLKSEL_16384
* - \ref GPIO_DBCTL_DBCLKSEL_32768
*
* @return None
*
* @details Set the interrupt de-bounce sampling cycle time based on the debounce counter clock source. \n
* Example: _GPIO_SET_DEBOUNCE_TIME(GPIO_DBCTL_DBCLKSRC_LIRC, GPIO_DBCTL_DBCLKSEL_4). \n
* It's meaning the De-debounce counter clock source is internal 10 KHz and sampling cycle selection is 4. \n
* Then the target de-bounce sampling cycle time is (4)*(1/(10*1000)) s = 4*0.0001 s = 400 us,
* and system will sampling interrupt input once per 00 us.
* \hideinitializer
*/
#define GPIO_SET_DEBOUNCE_TIME(u32Port, u32ClkSrc, u32ClkSel) (u32Port->DBCTL = (GPIO_DBCTL_ICLKON_Msk | (u32ClkSrc) | (u32ClkSel)))
/**
* @brief Get GPIO Port IN Data
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
*
* @return The specified port data
*
* @details Get the PIN register of specified GPIO port.
* \hideinitializer
*/
#define GPIO_GET_IN_DATA(port) ((port)->PIN)
/**
* @brief Set GPIO Port OUT Data
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32Data GPIO port data.
*
* @return None
*
* @details Set the Data into specified GPIO port.
* \hideinitializer
*/
#define GPIO_SET_OUT_DATA(port, u32Data) ((port)->DOUT = (u32Data))
/**
* @brief Toggle Specified GPIO pin
*
* @param[in] u32Pin Pxy
*
* @return None
*
* @details Toggle the specified GPIO pint.
* \hideinitializer
*/
#define GPIO_TOGGLE(u32Pin) ((u32Pin) ^= 1)
/**
* @brief Enable External GPIO interrupt
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32Pin The pin of specified GPIO port.
* It could be 0 ~ 15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be 0 ~ 13 for PE GPIO port.
* It could be 0 ~ 11 for PG GPIO port.
* @param[in] u32IntAttribs The interrupt attribute of specified GPIO pin. It could be \n
* GPIO_INT_RISING, GPIO_INT_FALLING, GPIO_INT_BOTH_EDGE, GPIO_INT_HIGH, GPIO_INT_LOW.
*
* @return None
*
* @details This function is used to enable specified GPIO pin interrupt.
* \hideinitializer
*/
#define GPIO_EnableEINT GPIO_EnableInt
/**
* @brief Disable External GPIO interrupt
*
* @param[in] port GPIO port. It could be PA, PB, PC, PD, PE, PF, PG, PH, PI, PJ, PK,PL, PM and PN.
* @param[in] u32Pin The pin of specified GPIO port.
* It could be 0 ~ 15 for PA, PB, PC, PD, PF and PH GPIO port.
* It could be 0 ~ 13 for PE GPIO port.
* It could be 0 ~ 11 for PG GPIO port.
*
* @return None
*
* @details This function is used to enable specified GPIO pin interrupt.
* \hideinitializer
*/
#define GPIO_DisableEINT GPIO_DisableInt
void GPIO_SetMode(GPIO_T *port, uint32_t u32PinMask, uint32_t u32Mode);
void GPIO_EnableInt(GPIO_T *port, uint32_t u32Pin, uint32_t u32IntAttribs);
void GPIO_DisableInt(GPIO_T *port, uint32_t u32Pin);
void GPIO_SetSlewCtl(GPIO_T *port, uint32_t u32PinMask, uint32_t u32Mode);
void GPIO_SetPullCtl(GPIO_T *port, uint32_t u32PinMask, uint32_t u32Mode);
void GPIO_SetDrivingCtl(GPIO_T *port, uint32_t u32PinMask, uint32_t u32Driving);
void GPIO_SetSchmittTriggere(GPIO_T *port, uint32_t u32PinMask, uint32_t u32SchmittTrigger);
void GPIO_SetPowerMode(GPIO_T *port, uint32_t u32PinMask, uint32_t u32PowerMode);
uint32_t GPIO_GetPowerMode(GPIO_T *port, uint32_t u32PinNo);
uint32_t GPIO_GetSchmittTriggere(GPIO_T *port, uint32_t u32PinNo);
uint32_t GPIO_GetDrivingCtl(GPIO_T *port, uint32_t u32PinNo);
/*@}*/ /* end of group GPIO_EXPORTED_FUNCTIONS */
/*@}*/ /* end of group GPIO_Driver */
/*@}*/ /* end of group Standard_Driver */
#ifdef __cplusplus
}
#endif
#endif /* __GPIO_H__ */
|
7f176ee952643a4b46925ee9933e0f26c6b6d5c9
|
9ceacf33fd96913cac7ef15492c126d96cae6911
|
/regress/sys/kern/select/select_close.c
|
81d58ecddd5feaa0badef75dabc895f9f925d34a
|
[] |
no_license
|
openbsd/src
|
ab97ef834fd2d5a7f6729814665e9782b586c130
|
9e79f3a0ebd11a25b4bff61e900cb6de9e7795e9
|
refs/heads/master
| 2023-09-02T18:54:56.624627
| 2023-09-02T15:16:12
| 2023-09-02T15:16:12
| 66,966,208
| 3,394
| 1,235
| null | 2023-08-08T02:42:25
| 2016-08-30T18:18:25
|
C
|
UTF-8
|
C
| false
| false
| 2,838
|
c
|
select_close.c
|
/* $OpenBSD: select_close.c,v 1.3 2021/12/24 10:22:41 visa Exp $ */
/*
* Copyright (c) 2021 Visa Hankala
*
* Permission to use, copy, modify, and 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.
*/
/*
* Test behaviour when a monitored file descriptor is closed by another thread.
*
* Note that this case is not defined by POSIX.
*/
#include <sys/types.h>
#include <sys/select.h>
#include <sys/socket.h>
#include <assert.h>
#include <err.h>
#include <errno.h>
#include <pthread.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
static int barrier[2];
static int sock[2];
static void *
thread_main(void *arg)
{
fd_set rfds;
int ret;
char b;
FD_ZERO(&rfds);
FD_SET(sock[1], &rfds);
ret = select(sock[1] + 1, &rfds, NULL, NULL, NULL);
assert(ret == 1);
assert(FD_ISSET(sock[1], &rfds));
/* Drain data to prevent subsequent wakeups. */
read(sock[1], &b, 1);
/* Sync with parent thread. */
write(barrier[1], "y", 1);
read(barrier[1], &b, 1);
FD_ZERO(&rfds);
FD_SET(sock[1], &rfds);
ret = select(sock[1] + 1, &rfds, NULL, NULL, NULL);
assert(ret == -1);
assert(errno == EBADF);
return NULL;
}
int
main(void)
{
pthread_t t;
int ret, saved_fd;
char b;
/* Enforce test timeout. */
alarm(10);
if (socketpair(AF_UNIX, SOCK_STREAM, 0, barrier) == -1)
err(1, "can't create socket pair");
if (socketpair(AF_UNIX, SOCK_STREAM, 0, sock) == -1)
err(1, "can't create socket pair");
ret = pthread_create(&t, NULL, thread_main, NULL);
if (ret != 0) {
fprintf(stderr, "can't start thread: %s\n", strerror(ret));
return 1;
}
/* Let the thread settle in select(). */
usleep(100000);
/* Awaken poll(). */
write(sock[0], "x", 1);
/* Wait until the thread has left select(). */
read(barrier[0], &b, 1);
/*
* Close and restore the fd that the thread has polled.
* This creates a pending badfd knote in the kernel.
*/
saved_fd = dup(sock[1]);
close(sock[1]);
dup2(saved_fd, sock[1]);
close(saved_fd);
/* Let the thread continue. */
write(barrier[0], "x", 1);
/* Let the thread settle in select(). */
usleep(100000);
/* Close the fd to awaken select(). */
close(sock[1]);
pthread_join(t, NULL);
close(sock[0]);
return 0;
}
|
1c3cd56ed66c7afd60e20d19bd4d2a441115ea8f
|
5afa01fb706bc29154491c441ec801585622e38c
|
/verification/cbmc/proofs/aws_priority_queue_push/aws_priority_queue_push_harness.c
|
85cd377ec7983ccb7fb9c379c1e50d3d97e32a86
|
[
"Apache-2.0",
"BSD-3-Clause",
"GPL-2.0-only"
] |
permissive
|
awslabs/aws-c-common
|
5af461d3b3586a569a1809c7b8f32091eec1a151
|
4dcc41cf4d1f868dcdd622c65c09bda972f75ad2
|
refs/heads/main
| 2023-08-29T14:07:10.856557
| 2023-08-25T07:40:54
| 2023-08-25T07:40:54
| 117,142,517
| 249
| 159
|
Apache-2.0
| 2023-09-12T19:02:25
| 2018-01-11T19:17:12
|
C
|
UTF-8
|
C
| false
| false
| 921
|
c
|
aws_priority_queue_push_harness.c
|
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/common/priority_queue.h>
#include <proof_helpers/make_common_data_structures.h>
void aws_priority_queue_push_harness() {
/* Data structure */
struct aws_priority_queue queue;
/* Assumptions */
__CPROVER_assume(aws_priority_queue_is_bounded(&queue, MAX_INITIAL_ITEM_ALLOCATION, MAX_ITEM_SIZE));
ensure_priority_queue_has_allocated_members(&queue);
__CPROVER_assume(aws_priority_queue_is_valid(&queue));
void *item = malloc(queue.container.item_size);
/* Assume the function preconditions */
__CPROVER_assume(item && AWS_MEM_IS_READABLE(item, queue.container.item_size));
/* Perform operation under verification */
aws_priority_queue_push(&queue, item);
/* Assert the postconditions */
assert(aws_priority_queue_is_valid(&queue));
}
|
fec03978a5e1306c7fa292d0f458048e23d7adec
|
7ca8ffcdfb39ab4ffc2d8ff291e46ffabc8db6a2
|
/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/main/native/container-executor/impl/main.c
|
1b91e8a3d6cd06a9178c05ee2c0cd2d7fc620154
|
[
"CC-PDDC",
"CC0-1.0",
"CC-BY-3.0",
"LicenseRef-scancode-unknown-license-reference",
"LGPL-2.1-only",
"LicenseRef-scancode-other-permissive",
"CDDL-1.0",
"GCC-exception-3.1",
"MIT",
"EPL-1.0",
"Classpath-exception-2.0",
"BSD-3-Clause",
"GPL-2.0-only",
"Apache-2.0",
"LicenseRef-scancode-public-domain",
"LicenseRef-scancode-jdom",
"CDDL-1.1",
"BSD-2-Clause",
"LicenseRef-scancode-unknown"
] |
permissive
|
apache/hadoop
|
ea2a4a370dd00d4a3806dd38df5b3cf6fd5b2c64
|
42b4525f75b828bf58170187f030b08622e238ab
|
refs/heads/trunk
| 2023-08-18T07:29:26.346912
| 2023-08-17T16:56:34
| 2023-08-17T16:56:34
| 23,418,517
| 16,088
| 10,600
|
Apache-2.0
| 2023-09-14T16:59:38
| 2014-08-28T07:00:08
|
Java
|
UTF-8
|
C
| false
| false
| 27,524
|
c
|
main.c
|
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you 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.
*/
#include "config.h"
#include "configuration.h"
#include "container-executor.h"
#include "util.h"
#include "get_executable.h"
#include "modules/gpu/gpu-module.h"
#include "modules/fpga/fpga-module.h"
#include "modules/cgroups/cgroups-operations.h"
#include "modules/devices/devices-module.h"
#include "utils/string-utils.h"
#include "runc/runc.h"
#include "runc/runc_reap.h"
#include <errno.h>
#include <grp.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <signal.h>
static void display_usage(FILE *stream) {
const char* disabled = "[DISABLED]";
const char* enabled = " ";
fputs("Usage: container-executor --checksetup\n"
" container-executor --mount-cgroups <hierarchy> "
"<controller=path>...\n", stream);
const char* de = is_tc_support_enabled() ? enabled : disabled;
fprintf(stream,
"%s container-executor --tc-modify-state <command-file>\n"
"%s container-executor --tc-read-state <command-file>\n"
"%s container-executor --tc-read-stats <command-file>\n",
de, de, de);
de = is_terminal_support_enabled() ? enabled : disabled;
fprintf(stream, "%s container-executor --exec-container <command-file>\n", de);
de = is_docker_support_enabled() ? enabled : disabled;
fprintf(stream, "%s container-executor --run-docker <command-file>\n", de);
fprintf(stream, "%s container-executor --remove-docker-container [hierarchy] <container_id>\n", de);
fprintf(stream, "%s container-executor --inspect-docker-container <container_id>\n", de);
de = is_runc_support_enabled() ? enabled : disabled;
fprintf(stream,
"%s container-executor --run-runc-container <command-file>\n", de);
fprintf(stream,
"%s container-executor --reap-runc-layer-mounts <retain-count>\n", de);
fprintf(stream,
" container-executor <user> <yarn-user> <command> <command-args>\n"
" where command and command-args: \n" \
" initialize container: %2d appid containerid tokens nm-local-dirs "
"nm-log-dirs cmd...\n"
" launch container: %2d appid containerid workdir "
"container-script tokens http-option pidfile nm-local-dirs nm-log-dirs resources ",
INITIALIZE_CONTAINER, LAUNCH_CONTAINER);
if(is_tc_support_enabled()) {
fputs("optional-tc-command-file\n", stream);
} else {
fputs("\n", stream);
}
fputs(
" where http-option is one of:\n"
" --http\n"
" --https keystorepath truststorepath\n", stream);
de = is_docker_support_enabled() ? enabled : disabled;
fprintf(stream,
"%11s launch docker container:%2d appid containerid workdir "
"container-script tokens http-option pidfile nm-local-dirs nm-log-dirs "
"docker-command-file resources ", de, LAUNCH_DOCKER_CONTAINER);
if(is_tc_support_enabled()) {
fputs("optional-tc-command-file\n", stream);
} else {
fputs("\n", stream);
}
fputs(
" where http-option is one of:\n"
" --http\n"
" --https keystorepath truststorepath\n", stream);
fprintf(stream,
" signal container: %2d container-pid signal\n"
" delete as user: %2d relative-path\n"
" list as user: %2d relative-path\n",
SIGNAL_CONTAINER, DELETE_AS_USER, LIST_AS_USER);
if(is_yarn_sysfs_support_enabled()) {
fprintf(stream,
" sync yarn sysfs: %2d app-id nm-local-dirs\n",
SYNC_YARN_SYSFS);
} else {
fprintf(stream,
"[DISABLED] sync yarn sysfs: %2d app-id nm-local-dirs\n",
SYNC_YARN_SYSFS);
}
fflush(stream);
}
/* Sets up log files for normal/error logging */
static void open_log_files() {
if (LOGFILE == NULL) {
LOGFILE = stdout;
if (setvbuf(LOGFILE, NULL, _IOLBF, BUFSIZ)) {
fprintf(LOGFILE, "Failed to invoke setvbuf() for LOGFILE: %s\n", strerror(errno));
fflush(LOGFILE);
exit(ERROR_CALLING_SETVBUF);
}
}
if (ERRORFILE == NULL) {
ERRORFILE = stderr;
if (setvbuf(ERRORFILE, NULL, _IOLBF, BUFSIZ)) {
fprintf(ERRORFILE, "Failed to invoke setvbuf() for ERRORFILE: %s\n", strerror(errno));
fflush(ERRORFILE);
exit(ERROR_CALLING_SETVBUF);
}
}
// There may be a process reading from stdout/stderr, and if it
// exits, we will crash on a SIGPIPE when we try to write to them.
// By ignoring SIGPIPE, we can handle the EPIPE instead of crashing.
signal(SIGPIPE, SIG_IGN);
}
/* Flushes and closes log files */
static void flush_and_close_log_files() {
if (LOGFILE != NULL) {
fflush(LOGFILE);
fclose(LOGFILE);
LOGFILE = NULL;
}
if (ERRORFILE != NULL) {
fflush(ERRORFILE);
fclose(ERRORFILE);
ERRORFILE = NULL;
}
free_executor_configurations();
}
/** Validates the current container-executor setup. Causes program exit
in case of validation failures. Also sets up configuration / group information etc.,
This function is to be called in every invocation of container-executor, irrespective
of whether an explicit checksetup operation is requested. */
static void assert_valid_setup(char *argv0) {
int ret;
char *executable_file = get_executable(argv0);
if (!executable_file || executable_file[0] == 0) {
fprintf(ERRORFILE, "realpath of executable: %s\n",
errno != 0 ? strerror(errno) : "unknown");
flush_and_close_log_files();
exit(INVALID_CONFIG_FILE);
}
char *conf_file = get_config_path(argv0);
if (conf_file == NULL) {
flush_and_close_log_files();
exit(INVALID_CONFIG_FILE);
}
if (check_configuration_permissions(conf_file) != 0) {
flush_and_close_log_files();
exit(INVALID_CONFIG_FILE);
}
read_executor_config(conf_file);
free(conf_file);
// look up the node manager group in the config file
char *nm_group = get_nodemanager_group();
if (nm_group == NULL) {
free(executable_file);
fprintf(ERRORFILE, "Can't get configured value for %s.\n", NM_GROUP_KEY);
flush_and_close_log_files();
exit(INVALID_CONFIG_FILE);
}
struct group *group_info = getgrnam(nm_group);
if (group_info == NULL) {
free(executable_file);
fprintf(ERRORFILE, "Can't get group information for %s - %s.\n", nm_group,
errno != 0 ? strerror(errno) : "unknown");
flush_and_close_log_files();
exit(INVALID_CONFIG_FILE);
}
set_nm_uid(getuid(), group_info->gr_gid);
/*
* if we are running from a setuid executable, make the real uid root
* we're going to ignore this result just in case we aren't.
*/
ret=setuid(0);
/*
* set the real and effective group id to the node manager group
* we're going to ignore this result just in case we aren't
*/
ret=setgid(group_info->gr_gid);
/* make the unused var warning to away */
ret++;
if (check_executor_permissions(executable_file) != 0) {
free(executable_file);
fprintf(ERRORFILE, "Invalid permissions on container-executor binary.\n");
flush_and_close_log_files();
exit(INVALID_CONTAINER_EXEC_PERMISSIONS);
}
free(executable_file);
}
static void display_feature_disabled_message(const char* name) {
fprintf(ERRORFILE, "Feature disabled: %s\n", name);
}
/* Use to store parsed input parameters for various operations */
static struct {
char *cgroups_hierarchy;
char *traffic_control_command_file;
const char *run_as_user_name;
const char *yarn_user_name;
char *local_dirs;
char *log_dirs;
char *resources_key;
char *resources_value;
char **resources_values;
const char *app_id;
const char *container_id;
int https;
const char *keystore_file;
const char *truststore_file;
const char *cred_file;
const char *script_file;
const char *current_dir;
const char *pid_file;
const char *target_dir;
int container_pid;
int signal;
int runc_layer_count;
const char *command_file;
} cmd_input;
static int validate_run_as_user_commands(int argc, char **argv, int *operation);
/* Validates that arguments used in the invocation are valid. In case of validation
failure, an 'errorcode' is returned. In case of successful validation, a zero is
returned and 'operation' is populated based on the operation being requested.
Ideally, we should re-factor container-executor to use a more structured, command
line parsing mechanism (e.g getopt). For the time being, we'll use this manual
validation mechanism so that we don't have to change the invocation interface.
*/
static int validate_arguments(int argc, char **argv , int *operation) {
if (argc < 2) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
/*
* Check if it is a known module, if yes, redirect to module
*/
if (strcmp("--module-gpu", argv[1]) == 0) {
return handle_gpu_request(&update_cgroups_parameters, "gpu", argc - 1,
&argv[1]);
}
if (strcmp("--module-fpga", argv[1]) == 0) {
return handle_fpga_request(&update_cgroups_parameters, "fpga", argc - 1,
&argv[1]);
}
if (strcmp("--module-devices", argv[1]) == 0) {
return handle_devices_request(&update_cgroups_parameters, "devices", argc - 1,
&argv[1]);
}
if (strcmp("--checksetup", argv[1]) == 0) {
*operation = CHECK_SETUP;
return 0;
}
if (strcmp("--mount-cgroups", argv[1]) == 0) {
if (is_mount_cgroups_support_enabled()) {
if (argc < 4) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
cmd_input.cgroups_hierarchy = argv[optind++];
*operation = MOUNT_CGROUPS;
return 0;
} else {
display_feature_disabled_message("mount cgroup");
return FEATURE_DISABLED;
}
}
if (strcmp("--tc-modify-state", argv[1]) == 0) {
if(is_tc_support_enabled()) {
if (argc != 3) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
cmd_input.traffic_control_command_file = argv[optind++];
*operation = TRAFFIC_CONTROL_MODIFY_STATE;
return 0;
} else {
display_feature_disabled_message("traffic control");
return FEATURE_DISABLED;
}
}
if (strcmp("--tc-read-state", argv[1]) == 0) {
if(is_tc_support_enabled()) {
if (argc != 3) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
cmd_input.traffic_control_command_file = argv[optind++];
*operation = TRAFFIC_CONTROL_READ_STATE;
return 0;
} else {
display_feature_disabled_message("traffic control");
return FEATURE_DISABLED;
}
}
if (strcmp("--tc-read-stats", argv[1]) == 0) {
if(is_tc_support_enabled()) {
if (argc != 3) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
cmd_input.traffic_control_command_file = argv[optind++];
*operation = TRAFFIC_CONTROL_READ_STATS;
return 0;
} else {
display_feature_disabled_message("traffic control");
return FEATURE_DISABLED;
}
}
if (strcmp("--exec-container", argv[1]) == 0) {
if(is_terminal_support_enabled()) {
if (argc != 3) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
cmd_input.command_file = argv[optind++];
*operation = EXEC_CONTAINER;
return 0;
} else {
display_feature_disabled_message("feature.terminal.enabled");
return FEATURE_DISABLED;
}
}
if (strcmp("--run-docker", argv[1]) == 0) {
if(is_docker_support_enabled()) {
if (argc != 3) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
cmd_input.command_file = argv[optind++];
*operation = RUN_DOCKER;
return 0;
} else {
display_feature_disabled_message("docker");
return FEATURE_DISABLED;
}
}
if (strcmp("--remove-docker-container", argv[1]) == 0) {
if(is_docker_support_enabled()) {
if ((argc != 3) && (argc != 4)) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
*operation = REMOVE_DOCKER_CONTAINER;
return 0;
} else {
display_feature_disabled_message("docker");
return FEATURE_DISABLED;
}
}
if (strcmp("--inspect-docker-container", argv[1]) == 0) {
if(is_docker_support_enabled()) {
if (argc != 4) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
*operation = INSPECT_DOCKER_CONTAINER;
return 0;
} else {
display_feature_disabled_message("docker");
return FEATURE_DISABLED;
}
}
if (strcmp("--run-runc-container", argv[1]) == 0) {
if (is_runc_support_enabled()) {
if (argc != 3) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
cmd_input.command_file = argv[optind++];
*operation = RUN_RUNC_CONTAINER;
return 0;
} else {
display_feature_disabled_message("runc");
return FEATURE_DISABLED;
}
}
if (strcmp("--reap-runc-layer-mounts", argv[1]) == 0) {
if (is_runc_support_enabled()) {
if (argc != 3) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
optind++;
const char* valstr = argv[optind++];
if (sscanf(valstr, "%d", &cmd_input.runc_layer_count) != 1
|| cmd_input.runc_layer_count < 0) {
fprintf(ERRORFILE, "Bad runc layer count: %s\n", valstr);
return INVALID_COMMAND_PROVIDED;
}
*operation = REAP_RUNC_LAYER_MOUNTS;
return 0;
} else {
display_feature_disabled_message("runc");
return FEATURE_DISABLED;
}
}
/* Now we have to validate 'run as user' operations that don't use
a 'long option' - we should fix this at some point. The validation/argument
parsing here is extensive enough that it done in a separate function */
return validate_run_as_user_commands(argc, argv, operation);
}
/* Parse/validate 'run as user' commands */
static int validate_run_as_user_commands(int argc, char **argv, int *operation) {
/* We need at least the following arguments in order to proceed further :
<user>, <yarn-user> <command> - i.e at argc should be at least 4 */
if (argc < 4) {
display_usage(stdout);
return INVALID_ARGUMENT_NUMBER;
}
cmd_input.run_as_user_name = argv[optind++];
cmd_input.yarn_user_name = argv[optind++];
int command = atoi(argv[optind++]);
fprintf(LOGFILE, "main : command provided %d\n", command);
fprintf(LOGFILE, "main : run as user is %s\n", cmd_input.run_as_user_name);
fprintf(LOGFILE, "main : requested yarn user is %s\n", cmd_input.yarn_user_name);
char * resources = NULL;// key,value pair describing resources
char * resources_key = NULL;
char * resources_value = NULL;
switch (command) {
case INITIALIZE_CONTAINER:
if (argc < 10) {
fprintf(ERRORFILE, "Too few arguments (%d vs 10) for initialize container\n",
argc);
return INVALID_ARGUMENT_NUMBER;
}
cmd_input.app_id = argv[optind++];
cmd_input.container_id = argv[optind++];
if (!validate_container_id(cmd_input.container_id)) {
fprintf(ERRORFILE, "Invalid container id %s\n", cmd_input.container_id);
return INVALID_CONTAINER_ID;
}
cmd_input.cred_file = argv[optind++];
cmd_input.local_dirs = argv[optind++];// good local dirs as a comma separated list
cmd_input.log_dirs = argv[optind++];// good log dirs as a comma separated list
*operation = RUN_AS_USER_INITIALIZE_CONTAINER;
return 0;
case LAUNCH_DOCKER_CONTAINER:
if(is_docker_support_enabled()) {
//kill me now.
if (!(argc >= 14 && argc <= 17)) {
fprintf(ERRORFILE, "Wrong number of arguments (%d vs 14 - 17) for"
" launch docker container\n", argc);
return INVALID_ARGUMENT_NUMBER;
}
cmd_input.app_id = argv[optind++];
cmd_input.container_id = argv[optind++];
cmd_input.current_dir = argv[optind++];
cmd_input.script_file = argv[optind++];
cmd_input.cred_file = argv[optind++];
if (strcmp("--https", argv[optind++]) == 0) {
cmd_input.https = 1;
cmd_input.keystore_file = argv[optind++];
cmd_input.truststore_file = argv[optind++];
} else {
cmd_input.https = 0;
}
cmd_input.pid_file = argv[optind++];
// good local dirs as a comma separated list
cmd_input.local_dirs = argv[optind++];
// good log dirs as a comma separated list
cmd_input.log_dirs = argv[optind++];
cmd_input.command_file = argv[optind++];
//network isolation through tc
if ((argc == 15 && !cmd_input.https) || (argc == 17 && cmd_input.https)) {
if(is_tc_support_enabled()) {
cmd_input.traffic_control_command_file = argv[optind++];
} else {
display_feature_disabled_message("traffic control");
return FEATURE_DISABLED;
}
}
*operation = RUN_AS_USER_LAUNCH_DOCKER_CONTAINER;
return 0;
} else {
display_feature_disabled_message("docker");
return FEATURE_DISABLED;
}
case LAUNCH_CONTAINER:
//kill me now.
if (!(argc >= 14 && argc <= 17)) {
fprintf(ERRORFILE, "Wrong number of arguments (%d vs 14 - 17)"
" for launch container\n", argc);
return INVALID_ARGUMENT_NUMBER;
}
cmd_input.app_id = argv[optind++];
cmd_input.container_id = argv[optind++];
cmd_input.current_dir = argv[optind++];
cmd_input.script_file = argv[optind++];
cmd_input.cred_file = argv[optind++];
if (strcmp("--https", argv[optind++]) == 0) {
cmd_input.https = 1;
cmd_input.keystore_file = argv[optind++];
cmd_input.truststore_file = argv[optind++];
} else {
cmd_input.https = 0;
}
cmd_input.pid_file = argv[optind++];
cmd_input.local_dirs = argv[optind++];// good local dirs as a comma separated list
cmd_input.log_dirs = argv[optind++];// good log dirs as a comma separated list
resources = argv[optind++];// key,value pair describing resources
resources_key = malloc(strlen(resources));
resources_value = malloc(strlen(resources));
if (get_kv_key(resources, resources_key, strlen(resources)) < 0 ||
get_kv_value(resources, resources_value, strlen(resources)) < 0) {
fprintf(ERRORFILE, "Invalid arguments for cgroups resources: %s\n",
resources);
free(resources_key);
free(resources_value);
return INVALID_ARGUMENT_NUMBER;
}
//network isolation through tc
if ((argc == 15 && !cmd_input.https) || (argc == 17 && cmd_input.https)) {
if(is_tc_support_enabled()) {
cmd_input.traffic_control_command_file = argv[optind++];
} else {
display_feature_disabled_message("traffic control");
return FEATURE_DISABLED;
}
}
cmd_input.resources_key = resources_key;
cmd_input.resources_value = resources_value;
cmd_input.resources_values = split(resources_value);
*operation = RUN_AS_USER_LAUNCH_CONTAINER;
return 0;
case SIGNAL_CONTAINER:
if (argc != 6) {
fprintf(ERRORFILE, "Wrong number of arguments (%d vs 6) for " \
"signal container\n", argc);
return INVALID_ARGUMENT_NUMBER;
}
char* end_ptr = NULL;
char* option = argv[optind++];
cmd_input.container_pid = strtol(option, &end_ptr, 10);
if (option == end_ptr || *end_ptr != '\0') {
fprintf(ERRORFILE, "Illegal argument for container pid %s\n", option);
return INVALID_ARGUMENT_NUMBER;
}
option = argv[optind++];
cmd_input.signal = strtol(option, &end_ptr, 10);
if (option == end_ptr || *end_ptr != '\0') {
fprintf(ERRORFILE, "Illegal argument for signal %s\n", option);
return INVALID_ARGUMENT_NUMBER;
}
*operation = RUN_AS_USER_SIGNAL_CONTAINER;
return 0;
case DELETE_AS_USER:
cmd_input.target_dir = argv[optind++];
*operation = RUN_AS_USER_DELETE;
return 0;
case LIST_AS_USER:
cmd_input.target_dir = argv[optind++];
*operation = RUN_AS_USER_LIST;
return 0;
case SYNC_YARN_SYSFS:
cmd_input.app_id = argv[optind++];
cmd_input.local_dirs = argv[optind++];
*operation = RUN_AS_USER_SYNC_YARN_SYSFS;
return 0;
default:
fprintf(ERRORFILE, "Invalid command %d not supported.\n",command);
return INVALID_COMMAND_PROVIDED;
}
}
int main(int argc, char **argv) {
open_log_files();
assert_valid_setup(argv[0]);
int operation = -1;
int exit_code = 0;
exit_code = validate_arguments(argc, argv, &operation);
if (exit_code != 0 || operation == -1) {
// if operation is still -1, the work was done in validate_arguments
// e.g. for --module-gpu
goto cleanup;
}
switch (operation) {
case CHECK_SETUP:
//we already did this
exit_code = 0;
break;
case MOUNT_CGROUPS:
exit_code = 0;
while (optind < argc && exit_code == 0) {
exit_code = mount_cgroup(argv[optind++], cmd_input.cgroups_hierarchy);
}
break;
case TRAFFIC_CONTROL_MODIFY_STATE:
exit_code = traffic_control_modify_state(cmd_input.traffic_control_command_file);
break;
case TRAFFIC_CONTROL_READ_STATE:
exit_code = traffic_control_read_state(cmd_input.traffic_control_command_file);
break;
case TRAFFIC_CONTROL_READ_STATS:
exit_code = traffic_control_read_stats(cmd_input.traffic_control_command_file);
break;
case EXEC_CONTAINER:
exit_code = exec_container(cmd_input.command_file);
break;
case RUN_DOCKER:
exit_code = run_docker(cmd_input.command_file);
break;
case REMOVE_DOCKER_CONTAINER:
exit_code = remove_docker_container(argv + optind, argc - optind);
break;
case INSPECT_DOCKER_CONTAINER:
exit_code = exec_docker_command("inspect", argv + optind, argc - optind);
break;
case RUN_AS_USER_INITIALIZE_CONTAINER:
exit_code = set_user(cmd_input.run_as_user_name);
if (exit_code != 0) {
break;
}
exit_code = initialize_app(cmd_input.yarn_user_name,
cmd_input.app_id,
cmd_input.container_id,
cmd_input.cred_file,
split(cmd_input.local_dirs),
split(cmd_input.log_dirs),
argv + optind);
break;
case RUN_AS_USER_LAUNCH_DOCKER_CONTAINER:
if (cmd_input.traffic_control_command_file != NULL) {
//apply tc rules before switching users and launching the container
exit_code = traffic_control_modify_state(cmd_input.traffic_control_command_file);
if( exit_code != 0) {
//failed to apply tc rules - break out before launching the container
break;
}
}
exit_code = set_user(cmd_input.run_as_user_name);
if (exit_code != 0) {
break;
}
exit_code = launch_docker_container_as_user(cmd_input.yarn_user_name,
cmd_input.app_id,
cmd_input.container_id,
cmd_input.current_dir,
cmd_input.script_file,
cmd_input.cred_file,
cmd_input.https,
cmd_input.keystore_file,
cmd_input.truststore_file,
cmd_input.pid_file,
split(cmd_input.local_dirs),
split(cmd_input.log_dirs),
cmd_input.command_file);
break;
case RUN_AS_USER_LAUNCH_CONTAINER:
if (cmd_input.traffic_control_command_file != NULL) {
//apply tc rules before switching users and launching the container
exit_code = traffic_control_modify_state(cmd_input.traffic_control_command_file);
if( exit_code != 0) {
//failed to apply tc rules - break out before launching the container
break;
}
}
exit_code = set_user(cmd_input.run_as_user_name);
if (exit_code != 0) {
break;
}
exit_code = launch_container_as_user(cmd_input.yarn_user_name,
cmd_input.app_id,
cmd_input.container_id,
cmd_input.current_dir,
cmd_input.script_file,
cmd_input.cred_file,
cmd_input.https,
cmd_input.keystore_file,
cmd_input.truststore_file,
cmd_input.pid_file,
split(cmd_input.local_dirs),
split(cmd_input.log_dirs),
cmd_input.resources_key,
cmd_input.resources_values);
free(cmd_input.resources_key);
free(cmd_input.resources_value);
free(cmd_input.resources_values);
break;
case RUN_AS_USER_SIGNAL_CONTAINER:
exit_code = set_user(cmd_input.run_as_user_name);
if (exit_code != 0) {
break;
}
exit_code = signal_container_as_user(cmd_input.yarn_user_name,
cmd_input.container_pid,
cmd_input.signal);
break;
case RUN_AS_USER_DELETE:
exit_code = set_user(cmd_input.run_as_user_name);
if (exit_code != 0) {
break;
}
exit_code = delete_as_user(cmd_input.yarn_user_name,
cmd_input.target_dir,
argv + optind);
break;
case RUN_AS_USER_LIST:
exit_code = set_user(cmd_input.run_as_user_name);
if (exit_code != 0) {
break;
}
exit_code = list_as_user(cmd_input.target_dir);
break;
case RUN_AS_USER_SYNC_YARN_SYSFS:
exit_code = set_user(cmd_input.run_as_user_name);
if (exit_code != 0) {
break;
}
if (is_yarn_sysfs_support_enabled()) {
exit_code = sync_yarn_sysfs(split(cmd_input.local_dirs),
cmd_input.run_as_user_name, cmd_input.yarn_user_name,
cmd_input.app_id);
} else {
exit_code = FEATURE_DISABLED;
}
break;
case RUN_RUNC_CONTAINER:
exit_code = run_runc_container(cmd_input.command_file);
break;
case REAP_RUNC_LAYER_MOUNTS:
exit_code = reap_runc_layer_mounts(cmd_input.runc_layer_count);
break;
default:
fprintf(ERRORFILE, "Unexpected operation code: %d\n", operation);
exit_code = INVALID_COMMAND_PROVIDED;
break;
}
cleanup:
if (exit_code) {
fprintf(ERRORFILE, "Nonzero exit code=%d, error message='%s'\n", exit_code,
get_error_message(exit_code));
}
flush_and_close_log_files();
return exit_code;
}
|
7191b4907ca1e5985707295287d19d9af6efaee6
|
8fe1d3a1ab8de1d763579f7c585cfa65d1b32855
|
/Strings/slides/representacao_de_strings/ctype.c
|
6010f64ced9c30259941b9f23ea0f9fc0ab9cb8e
|
[] |
no_license
|
edsomjr/TEP
|
1920655075227e335e85741e2bbc2845177cf76e
|
f5885e1089ea9371777805b742ae22b4d67c8c48
|
refs/heads/master
| 2023-07-19T14:25:11.132962
| 2023-07-07T22:04:28
| 2023-07-07T22:04:28
| 63,184,807
| 389
| 178
| null | 2023-09-13T16:05:58
| 2016-07-12T18:57:19
|
TeX
|
UTF-8
|
C
| false
| false
| 669
|
c
|
ctype.c
|
#include <stdio.h>
#include <ctype.h>
int main()
{
char a[] = "Test with numbers: 0x1234";
int r;
a[0] = tolower(a[0]); // a = "test with numbers: 0x1234"
a[10] = toupper(a[10]); // a = "test with Numbers: 0x1234"
r = isalpha(a[0]); // r != 0, 't' é alfabético
r = isalpha(a[19]); // r = 0, '0' não é alfabético
r = isalnum(a[19]); // r != 0, '0' é alfanumérico
r = isblank(a[18]); // r != 0, ' ' é um espaço em branco
r = isdigit(a[1]); // r = 0, 'e' não é um dígito decimal
r = isxdigit(a[1]); // r != 0, 'e' é um dígito hexadecimal
return 0;
}
|
36687d905e121f0d57e28c4d408d1b354d3b8807
|
c4bdd56ae6aa015af6502be7d517151fe67fe031
|
/image.c
|
219da3c0319e952e00ccf15ac985cb7738e4158c
|
[] |
no_license
|
S-LucasSerrano/miniLibX_sample
|
0bdfe8df38ab5fac72f6d24f108b5a5bca7dc7bb
|
d885944808d28f83e9e1019e6c68c27c310c86c7
|
refs/heads/main
| 2023-06-25T02:03:39.100365
| 2021-07-30T14:51:45
| 2021-07-30T14:51:45
| 385,244,765
| 107
| 6
| null | null | null | null |
UTF-8
|
C
| false
| false
| 1,371
|
c
|
image.c
|
#include "mlx_sample.h"
/* Returns an image of <width> x <height> black pixels. */
t_image ft_new_image(void* mlx, int width, int height)
{
t_image img;
/* mlx function that creates and returns a pointer
to an image of the given width and height */
img.reference = mlx_new_image(mlx, width, height);
img.size.x = width;
img.size.x = height;
/* mlx function that returs a pointer to the first pixel of the given image.
* ¡Pixels are not stored in a 2D table, just a single char[] array!
* the fuction also saves in the given pointers:
* the bits per pixel (each pixel is usually 4 chars of the array),
* the line size of the pixels array (the amount of pixels in one line of the image)
* and the endian (info of how the colors are stored) */
img.pixels = mlx_get_data_addr(img.reference, &img.bits_per_pixel, &img.line_size, &img.endian);
return (img);
}
/* Returns an image with the sprite found in <path> */
t_image ft_new_sprite(void *mlx, char *path)
{
t_image img;
/* mlx function that creates and image that contains the xmp file found in the given path.
* It also saves the width and height of the image in the pointers passed as parameters */
img.reference = mlx_xpm_file_to_image(mlx, path, &img.size.x, &img.size.y);
img.pixels = mlx_get_data_addr(img.reference, &img.bits_per_pixel, &img.line_size, &img.endian);
return (img);
}
|
49241636d1f2b6ac911da40ea0dcf7777dda1c35
|
99bdb3251fecee538e0630f15f6574054dfc1468
|
/bsp/phytium/libraries/standalone/drivers/timer/ftimer_tacho/ftimer_tacho_g.c
|
6353f21c6e50220b9ef0550bac262fee1385f157
|
[
"BSD-2-Clause",
"LicenseRef-scancode-unknown-license-reference",
"Zlib",
"LicenseRef-scancode-proprietary-license",
"MIT",
"BSD-3-Clause",
"X11",
"BSD-4-Clause-UC",
"Apache-2.0"
] |
permissive
|
RT-Thread/rt-thread
|
03a7c52c2aeb1b06a544143b0e803d72f47d1ece
|
3602f891211904a27dcbd51e5ba72fefce7326b2
|
refs/heads/master
| 2023-09-01T04:10:20.295801
| 2023-08-31T16:20:55
| 2023-08-31T16:20:55
| 7,408,108
| 9,599
| 5,805
|
Apache-2.0
| 2023-09-14T13:37:26
| 2013-01-02T14:49:21
|
C
|
UTF-8
|
C
| false
| false
| 2,411
|
c
|
ftimer_tacho_g.c
|
/*
* Copyright : (C) 2022 Phytium Information Technology, Inc.
* All Rights Reserved.
*
* This program is OPEN SOURCE software: you can redistribute it and/or modify it
* under the terms of the Phytium Public License as published by the Phytium Technology Co.,Ltd,
* either version 1.0 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 Phytium Public License for more details.
*
*
* FilePath: ftimer_tacho_g.c
* Date: 2022-02-10 14:53:42
* LastEditTime: 2022-02-18 09:09:07
* Description: This file is for timer_tacho static configuration
*
* Modify History:
* Ver Who Date Changes
* ----- ------ -------- --------------------------------------
* 1.0 liushengming 2022/02/18 first commit
*/
/***************************** Include Files *********************************/
#include <string.h>
#include "fparameters.h"
#include "fassert.h"
#include "ftimer_tacho_hw.h"
#include "ftimer_tacho.h"
#define TACHO_PERIOD 1000000 /* 1000000/50000000 = 0.02s*/
/************************** Function Prototypes ******************************/
void FTimerGetDefConfig(u32 timer_id, FTimerTachoConfig *config_p)
{
FASSERT((timer_id < FTIMER_NUM) && (NULL != config_p));
memset(config_p, 0, sizeof(FTimerTachoConfig));
config_p->id = timer_id;
config_p->work_mode = FTIMER_WORK_MODE_TIMER;
config_p->timer_mode = FTIMER_RESTART;
config_p->timer_bits = FTIMER_32_BITS;
config_p->cmp_type = FTIMER_CYC_CMP;
config_p->clear_cnt = FALSE;
config_p->force_load = TRUE;
}
void FTachoGetDefConfig(u32 tacho_id, FTimerTachoConfig *config_p)
{
FASSERT((tacho_id < FTACHO_NUM) && (NULL != config_p));
memset(config_p, 0, sizeof(FTimerTachoConfig));
config_p->id = tacho_id;
config_p->timer_bits = FTIMER_32_BITS;
config_p->work_mode = FTIMER_WORK_MODE_TACHO;
config_p->timer_mode = FTIMER_RESTART;
config_p->edge_mode = FTACHO_RISING_EDGE;
config_p->jitter_level = 0;
config_p->plus_num = TACHO_PERIOD;/*采样周期越长,能够检测到的单位时间脉冲越多,能够检测更小的频率*/
config_p->clear_cnt = FALSE;
config_p->force_load = TRUE;
}
|
a7ba137ac41fc7f8969851be46685d343b11b0fe
|
c21ad867752435377c599fb34df6d9074e2f014d
|
/sql-odbc/src/odfesqlodbc/odbcapi30.c
|
0ecfafde1ad2594d36688db6b4d73981d721a36a
|
[
"LGPL-2.0-only",
"Apache-2.0"
] |
permissive
|
opendistro-for-elasticsearch/sql
|
e7f5c3a4bd232237b837aa7b9c5704c33c80547b
|
a549025e42e71fb3146f0ba2a1705cbd3fa2db9c
|
refs/heads/develop
| 2023-09-03T03:47:50.986152
| 2022-07-14T20:06:32
| 2022-07-14T20:06:32
| 162,486,600
| 639
| 215
|
Apache-2.0
| 2022-07-19T21:52:44
| 2018-12-19T20:20:57
|
Java
|
UTF-8
|
C
| false
| false
| 23,078
|
c
|
odbcapi30.c
|
#include <stdio.h>
#include <string.h>
#include "environ.h"
#include "es_apifunc.h"
#include "es_connection.h"
#include "es_odbc.h"
#include "misc.h"
#include "statement.h"
/* SQLAllocConnect/SQLAllocEnv/SQLAllocStmt -> SQLAllocHandle */
RETCODE SQL_API SQLAllocHandle(SQLSMALLINT HandleType, SQLHANDLE InputHandle,
SQLHANDLE *OutputHandle) {
RETCODE ret;
ConnectionClass *conn;
MYLOG(ES_TRACE, "entering\n");
switch (HandleType) {
case SQL_HANDLE_ENV:
ret = ESAPI_AllocEnv(OutputHandle);
break;
case SQL_HANDLE_DBC:
ENTER_ENV_CS((EnvironmentClass *)InputHandle);
ret = ESAPI_AllocConnect(InputHandle, OutputHandle);
LEAVE_ENV_CS((EnvironmentClass *)InputHandle);
break;
case SQL_HANDLE_STMT:
conn = (ConnectionClass *)InputHandle;
ENTER_CONN_CS(conn);
ret = ESAPI_AllocStmt(
InputHandle, OutputHandle,
PODBC_EXTERNAL_STATEMENT | PODBC_INHERIT_CONNECT_OPTIONS);
if (*OutputHandle)
((StatementClass *)(*OutputHandle))->external = 1;
LEAVE_CONN_CS(conn);
break;
case SQL_HANDLE_DESC:
conn = (ConnectionClass *)InputHandle;
ENTER_CONN_CS(conn);
ret = ESAPI_AllocDesc(InputHandle, OutputHandle);
LEAVE_CONN_CS(conn);
MYLOG(ES_DEBUG, "OutputHandle=%p\n", *OutputHandle);
break;
default:
ret = SQL_ERROR;
break;
}
return ret;
}
/* SQLBindParameter/SQLSetParam -> SQLBindParam */
RETCODE SQL_API SQLBindParam(HSTMT StatementHandle,
SQLUSMALLINT ParameterNumber,
SQLSMALLINT ValueType, SQLSMALLINT ParameterType,
SQLULEN LengthPrecision,
SQLSMALLINT ParameterScale, PTR ParameterValue,
SQLLEN *StrLen_or_Ind) {
UNUSED(ParameterNumber, ValueType, ParameterType, LengthPrecision,
ParameterScale, ParameterValue, StrLen_or_Ind);
StatementClass *stmt = (StatementClass *)StatementHandle;
if (stmt == NULL)
return SQL_ERROR;
SC_clear_error(stmt);
SC_set_error(stmt, STMT_NOT_IMPLEMENTED_ERROR,
"Elasticsearch does not support parameters.", "SQLBindParam");
return SQL_ERROR;
}
/* New function */
RETCODE SQL_API SQLCloseCursor(HSTMT StatementHandle) {
StatementClass *stmt = (StatementClass *)StatementHandle;
if(stmt == NULL)
return SQL_ERROR;
RETCODE ret;
MYLOG(ES_TRACE, "entering\n");
if (SC_connection_lost_check(stmt, __FUNCTION__))
return SQL_ERROR;
ENTER_STMT_CS(stmt);
SC_clear_error(stmt);
ret = ESAPI_FreeStmt(StatementHandle, SQL_CLOSE);
LEAVE_STMT_CS(stmt);
return ret;
}
#ifndef UNICODE_SUPPORTXX
/* SQLColAttributes -> SQLColAttribute */
SQLRETURN SQL_API SQLColAttribute(SQLHSTMT StatementHandle,
SQLUSMALLINT ColumnNumber,
SQLUSMALLINT FieldIdentifier,
SQLPOINTER CharacterAttribute,
SQLSMALLINT BufferLength,
SQLSMALLINT *StringLength,
#if defined(_WIN64) || defined(SQLCOLATTRIBUTE_SQLLEN)
SQLLEN *NumericAttribute
#else
SQLPOINTER NumericAttribute
#endif
) {
RETCODE ret;
StatementClass *stmt = (StatementClass *)StatementHandle;
MYLOG(ES_TRACE, "entering\n");
if (SC_connection_lost_check(stmt, __FUNCTION__))
return SQL_ERROR;
ENTER_STMT_CS(stmt);
SC_clear_error(stmt);
ret = ESAPI_ColAttributes(StatementHandle, ColumnNumber, FieldIdentifier,
CharacterAttribute, BufferLength, StringLength,
NumericAttribute);
LEAVE_STMT_CS(stmt);
return ret;
}
#endif /* UNICODE_SUPPORTXX */
/* new function */
RETCODE SQL_API SQLCopyDesc(SQLHDESC SourceDescHandle,
SQLHDESC TargetDescHandle) {
RETCODE ret;
MYLOG(ES_TRACE, "entering\n");
ret = ESAPI_CopyDesc(SourceDescHandle, TargetDescHandle);
return ret;
}
/* SQLTransact -> SQLEndTran */
RETCODE SQL_API SQLEndTran(SQLSMALLINT HandleType, SQLHANDLE Handle,
SQLSMALLINT CompletionType) {
UNUSED(CompletionType);
if (HandleType == SQL_HANDLE_STMT) {
StatementClass *stmt = (StatementClass *)Handle;
if (stmt == NULL)
return SQL_ERROR;
SC_clear_error(stmt);
SC_set_error(stmt, STMT_NOT_IMPLEMENTED_ERROR,
"Transactions are not supported.", "SQLEndTran");
} else if (HandleType == SQL_HANDLE_DBC) {
ConnectionClass *conn = (ConnectionClass *)Handle;
if (conn == NULL)
return SQL_ERROR;
CC_clear_error(conn);
CC_set_error(conn, CONN_NOT_IMPLEMENTED_ERROR,
"Transactions are not supported.", "SQLEndTran");
}
return SQL_ERROR;
}
/* SQLExtendedFetch -> SQLFetchScroll */
RETCODE SQL_API SQLFetchScroll(HSTMT StatementHandle,
SQLSMALLINT FetchOrientation,
SQLLEN FetchOffset) {
CSTR func = "SQLFetchScroll";
StatementClass *stmt = (StatementClass *)StatementHandle;
RETCODE ret = SQL_SUCCESS;
IRDFields *irdopts = SC_get_IRDF(stmt);
SQLUSMALLINT *rowStatusArray = irdopts->rowStatusArray;
SQLULEN *pcRow = irdopts->rowsFetched;
SQLLEN bkmarkoff = 0;
MYLOG(ES_TRACE, "entering %d," FORMAT_LEN "\n", FetchOrientation,
FetchOffset);
if (SC_connection_lost_check(stmt, __FUNCTION__))
return SQL_ERROR;
ENTER_STMT_CS(stmt);
SC_clear_error(stmt);
if (FetchOrientation == SQL_FETCH_BOOKMARK) {
if (stmt->options.bookmark_ptr) {
bkmarkoff = FetchOffset;
FetchOffset = *((Int4 *)stmt->options.bookmark_ptr);
MYLOG(ES_DEBUG,
"bookmark=" FORMAT_LEN " FetchOffset = " FORMAT_LEN "\n",
FetchOffset, bkmarkoff);
} else {
SC_set_error(stmt, STMT_SEQUENCE_ERROR,
"Bookmark isn't specifed yet", func);
ret = SQL_ERROR;
}
}
if (SQL_SUCCESS == ret) {
ARDFields *opts = SC_get_ARDF(stmt);
ret = ESAPI_ExtendedFetch(StatementHandle, FetchOrientation,
FetchOffset, pcRow, rowStatusArray, bkmarkoff,
opts->size_of_rowset);
stmt->transition_status = STMT_TRANSITION_FETCH_SCROLL;
}
LEAVE_STMT_CS(stmt);
if (ret != SQL_SUCCESS)
MYLOG(ES_TRACE, "leaving return = %d\n", ret);
return ret;
}
/* SQLFree(Connect/Env/Stmt) -> SQLFreeHandle */
RETCODE SQL_API SQLFreeHandle(SQLSMALLINT HandleType, SQLHANDLE Handle) {
RETCODE ret;
StatementClass *stmt;
ConnectionClass *conn = NULL;
MYLOG(ES_TRACE, "entering\n");
switch (HandleType) {
case SQL_HANDLE_ENV:
ret = ESAPI_FreeEnv(Handle);
break;
case SQL_HANDLE_DBC:
ret = ESAPI_FreeConnect(Handle);
break;
case SQL_HANDLE_STMT:
stmt = (StatementClass *)Handle;
if (stmt) {
conn = stmt->hdbc;
if (conn)
ENTER_CONN_CS(conn);
}
ret = ESAPI_FreeStmt(Handle, SQL_DROP);
if (conn)
LEAVE_CONN_CS(conn);
break;
case SQL_HANDLE_DESC:
ret = ESAPI_FreeDesc(Handle);
break;
default:
ret = SQL_ERROR;
break;
}
return ret;
}
#ifndef UNICODE_SUPPORTXX
/* new function */
RETCODE SQL_API SQLGetDescField(SQLHDESC DescriptorHandle,
SQLSMALLINT RecNumber,
SQLSMALLINT FieldIdentifier, PTR Value,
SQLINTEGER BufferLength,
SQLINTEGER *StringLength) {
RETCODE ret;
MYLOG(ES_TRACE, "entering\n");
ret = ESAPI_GetDescField(DescriptorHandle, RecNumber, FieldIdentifier,
Value, BufferLength, StringLength);
return ret;
}
/* new function */
RETCODE SQL_API SQLGetDescRec(SQLHDESC DescriptorHandle, SQLSMALLINT RecNumber,
SQLCHAR *Name, SQLSMALLINT BufferLength,
SQLSMALLINT *StringLength, SQLSMALLINT *Type,
SQLSMALLINT *SubType, SQLLEN *Length,
SQLSMALLINT *Precision, SQLSMALLINT *Scale,
SQLSMALLINT *Nullable) {
UNUSED(DescriptorHandle, RecNumber, Name, BufferLength, StringLength, Type,
SubType, Length, Precision, Scale, Nullable);
MYLOG(ES_TRACE, "entering\n");
MYLOG(ES_DEBUG, "Error not implemented\n");
return SQL_ERROR;
}
/* new function */
RETCODE SQL_API SQLGetDiagField(SQLSMALLINT HandleType, SQLHANDLE Handle,
SQLSMALLINT RecNumber,
SQLSMALLINT DiagIdentifier, PTR DiagInfo,
SQLSMALLINT BufferLength,
SQLSMALLINT *StringLength) {
RETCODE ret;
MYLOG(ES_TRACE, "entering Handle=(%u,%p) Rec=%d Id=%d info=(%p,%d)\n",
HandleType, Handle, RecNumber, DiagIdentifier, DiagInfo,
BufferLength);
ret = ESAPI_GetDiagField(HandleType, Handle, RecNumber, DiagIdentifier,
DiagInfo, BufferLength, StringLength);
return ret;
}
/* SQLError -> SQLDiagRec */
RETCODE SQL_API SQLGetDiagRec(SQLSMALLINT HandleType, SQLHANDLE Handle,
SQLSMALLINT RecNumber, SQLCHAR *Sqlstate,
SQLINTEGER *NativeError, SQLCHAR *MessageText,
SQLSMALLINT BufferLength,
SQLSMALLINT *TextLength) {
RETCODE ret;
MYLOG(ES_TRACE, "entering\n");
ret = ESAPI_GetDiagRec(HandleType, Handle, RecNumber, Sqlstate, NativeError,
MessageText, BufferLength, TextLength);
return ret;
}
#endif /* UNICODE_SUPPORTXX */
/* new function */
RETCODE SQL_API SQLGetEnvAttr(HENV EnvironmentHandle, SQLINTEGER Attribute,
PTR Value, SQLINTEGER BufferLength,
SQLINTEGER *StringLength) {
UNUSED(BufferLength, StringLength);
RETCODE ret;
EnvironmentClass *env = (EnvironmentClass *)EnvironmentHandle;
MYLOG(ES_TRACE, "entering " FORMAT_INTEGER "\n", Attribute);
ENTER_ENV_CS(env);
ret = SQL_SUCCESS;
switch (Attribute) {
case SQL_ATTR_CONNECTION_POOLING:
*((unsigned int *)Value) =
EN_is_pooling(env) ? SQL_CP_ONE_PER_DRIVER : SQL_CP_OFF;
break;
case SQL_ATTR_CP_MATCH:
*((unsigned int *)Value) = SQL_CP_RELAXED_MATCH;
break;
case SQL_ATTR_ODBC_VERSION:
*((unsigned int *)Value) =
EN_is_odbc2(env) ? SQL_OV_ODBC2 : SQL_OV_ODBC3;
break;
case SQL_ATTR_OUTPUT_NTS:
*((unsigned int *)Value) = SQL_TRUE;
break;
default:
env->errornumber = CONN_INVALID_ARGUMENT_NO;
ret = SQL_ERROR;
}
LEAVE_ENV_CS(env);
return ret;
}
#ifndef UNICODE_SUPPORTXX
/* SQLGetConnectOption -> SQLGetconnectAttr */
RETCODE SQL_API SQLGetConnectAttr(HDBC ConnectionHandle, SQLINTEGER Attribute,
PTR Value, SQLINTEGER BufferLength,
SQLINTEGER *StringLength) {
RETCODE ret;
MYLOG(ES_TRACE, "entering " FORMAT_UINTEGER "\n", Attribute);
ENTER_CONN_CS((ConnectionClass *)ConnectionHandle);
CC_clear_error((ConnectionClass *)ConnectionHandle);
ret = ESAPI_GetConnectAttr(ConnectionHandle, Attribute, Value, BufferLength,
StringLength);
LEAVE_CONN_CS((ConnectionClass *)ConnectionHandle);
return ret;
}
/* SQLGetStmtOption -> SQLGetStmtAttr */
RETCODE SQL_API SQLGetStmtAttr(HSTMT StatementHandle, SQLINTEGER Attribute,
PTR Value, SQLINTEGER BufferLength,
SQLINTEGER *StringLength) {
RETCODE ret;
StatementClass *stmt = (StatementClass *)StatementHandle;
MYLOG(ES_TRACE, "entering Handle=%p " FORMAT_INTEGER "\n", StatementHandle,
Attribute);
ENTER_STMT_CS(stmt);
SC_clear_error(stmt);
ret = ESAPI_GetStmtAttr(StatementHandle, Attribute, Value, BufferLength,
StringLength);
LEAVE_STMT_CS(stmt);
return ret;
}
/* SQLSetConnectOption -> SQLSetConnectAttr */
RETCODE SQL_API SQLSetConnectAttr(HDBC ConnectionHandle, SQLINTEGER Attribute,
PTR Value, SQLINTEGER StringLength) {
RETCODE ret;
ConnectionClass *conn = (ConnectionClass *)ConnectionHandle;
MYLOG(ES_TRACE, "entering " FORMAT_INTEGER "\n", Attribute);
ENTER_CONN_CS(conn);
CC_clear_error(conn);
ret =
ESAPI_SetConnectAttr(ConnectionHandle, Attribute, Value, StringLength);
LEAVE_CONN_CS(conn);
return ret;
}
/* new function */
RETCODE SQL_API SQLSetDescField(SQLHDESC DescriptorHandle,
SQLSMALLINT RecNumber,
SQLSMALLINT FieldIdentifier, PTR Value,
SQLINTEGER BufferLength) {
RETCODE ret;
MYLOG(ES_TRACE, "entering h=%p rec=%d field=%d val=%p\n", DescriptorHandle,
RecNumber, FieldIdentifier, Value);
ret = ESAPI_SetDescField(DescriptorHandle, RecNumber, FieldIdentifier,
Value, BufferLength);
return ret;
}
/* new fucntion */
RETCODE SQL_API SQLSetDescRec(SQLHDESC DescriptorHandle, SQLSMALLINT RecNumber,
SQLSMALLINT Type, SQLSMALLINT SubType,
SQLLEN Length, SQLSMALLINT Precision,
SQLSMALLINT Scale, PTR Data, SQLLEN *StringLength,
SQLLEN *Indicator) {
UNUSED(DescriptorHandle, RecNumber, Type, SubType, Length, Precision, Scale,
Data, StringLength, Indicator);
MYLOG(ES_TRACE, "entering\n");
MYLOG(ES_DEBUG, "Error not implemented\n");
return SQL_ERROR;
}
#endif /* UNICODE_SUPPORTXX */
/* new function */
RETCODE SQL_API SQLSetEnvAttr(HENV EnvironmentHandle, SQLINTEGER Attribute,
PTR Value, SQLINTEGER StringLength) {
UNUSED(StringLength);
RETCODE ret;
EnvironmentClass *env = (EnvironmentClass *)EnvironmentHandle;
MYLOG(ES_TRACE, "entering att=" FORMAT_INTEGER "," FORMAT_ULEN "\n",
Attribute, (SQLULEN)Value);
ENTER_ENV_CS(env);
switch (Attribute) {
case SQL_ATTR_CONNECTION_POOLING:
switch ((ULONG_PTR)Value) {
case SQL_CP_OFF:
EN_unset_pooling(env);
ret = SQL_SUCCESS;
break;
case SQL_CP_ONE_PER_DRIVER:
EN_set_pooling(env);
ret = SQL_SUCCESS;
break;
default:
ret = SQL_SUCCESS_WITH_INFO;
}
break;
case SQL_ATTR_CP_MATCH:
/* *((unsigned int *) Value) = SQL_CP_RELAXED_MATCH; */
ret = SQL_SUCCESS;
break;
case SQL_ATTR_ODBC_VERSION:
if (SQL_OV_ODBC2 == CAST_UPTR(SQLUINTEGER, Value))
EN_set_odbc2(env);
else
EN_set_odbc3(env);
ret = SQL_SUCCESS;
break;
case SQL_ATTR_OUTPUT_NTS:
if (SQL_TRUE == CAST_UPTR(SQLUINTEGER, Value))
ret = SQL_SUCCESS;
else
ret = SQL_SUCCESS_WITH_INFO;
break;
default:
env->errornumber = CONN_INVALID_ARGUMENT_NO;
ret = SQL_ERROR;
}
if (SQL_SUCCESS_WITH_INFO == ret) {
env->errornumber = CONN_OPTION_VALUE_CHANGED;
env->errormsg = "SetEnv changed to ";
}
LEAVE_ENV_CS(env);
return ret;
}
#ifndef UNICODE_SUPPORTXX
/* SQLSet(Param/Scroll/Stmt)Option -> SQLSetStmtAttr */
RETCODE SQL_API SQLSetStmtAttr(HSTMT StatementHandle, SQLINTEGER Attribute,
PTR Value, SQLINTEGER StringLength) {
StatementClass *stmt = (StatementClass *)StatementHandle;
RETCODE ret;
MYLOG(ES_TRACE, "entering Handle=%p " FORMAT_INTEGER "," FORMAT_ULEN "\n",
StatementHandle, Attribute, (SQLULEN)Value);
ENTER_STMT_CS(stmt);
SC_clear_error(stmt);
ret = ESAPI_SetStmtAttr(StatementHandle, Attribute, Value, StringLength);
LEAVE_STMT_CS(stmt);
return ret;
}
#endif /* UNICODE_SUPPORTXX */
#define SQL_FUNC_ESET(pfExists, uwAPI) \
(*(((UWORD *)(pfExists)) + ((uwAPI) >> 4)) |= (1 << ((uwAPI)&0x000F)))
RETCODE SQL_API ESAPI_GetFunctions30(HDBC hdbc, SQLUSMALLINT fFunction,
SQLUSMALLINT FAR *pfExists) {
ConnectionClass *conn = (ConnectionClass *)hdbc;
CC_clear_error(conn);
if (fFunction != SQL_API_ODBC3_ALL_FUNCTIONS)
return SQL_ERROR;
memset(pfExists, 0, sizeof(UWORD) * SQL_API_ODBC3_ALL_FUNCTIONS_SIZE);
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLALLOCCONNECT); 1 deprecated */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLALLOCENV); 2 deprecated */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLALLOCSTMT); 3 deprecated */
/*
* for (i = SQL_API_SQLBINDCOL; i <= 23; i++) SQL_FUNC_ESET(pfExists,
* i);
*/
SQL_FUNC_ESET(pfExists, SQL_API_SQLBINDCOL); /* 4 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLCANCEL); /* 5 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLCOLATTRIBUTE); /* 6 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLCONNECT); /* 7 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLDESCRIBECOL); /* 8 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLDISCONNECT); /* 9 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLERROR); 10 deprecated */
SQL_FUNC_ESET(pfExists, SQL_API_SQLEXECDIRECT); /* 11 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLEXECUTE); /* 12 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLFETCH); /* 13 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLFREECONNECT); 14 deprecated */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLFREEENV); 15 deprecated */
SQL_FUNC_ESET(pfExists, SQL_API_SQLFREESTMT); /* 16 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETCURSORNAME); /* 17 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLNUMRESULTCOLS); /* 18 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLPREPARE); /* 19 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLROWCOUNT); /* 20 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSETCURSORNAME); /* 21 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLSETPARAM); 22 deprecated */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLTRANSACT); 23 deprecated */
/*
* for (i = 40; i < SQL_API_SQLEXTENDEDFETCH; i++)
* SQL_FUNC_ESET(pfExists, i);
*/
SQL_FUNC_ESET(pfExists, SQL_API_SQLCOLUMNS); /* 40 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLDRIVERCONNECT); /* 41 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLGETCONNECTOPTION); 42 deprecated */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETDATA); /* 43 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETFUNCTIONS); /* 44 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETINFO); /* 45 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLGETSTMTOPTION); 46 deprecated */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETTYPEINFO); /* 47 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLPARAMDATA); /* 48 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLPUTDATA); /* 49 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLSETCONNECTIONOPTION); 50 deprecated */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLSETSTMTOPTION); 51 deprecated */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSPECIALCOLUMNS); /* 52 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSTATISTICS); /* 53 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLTABLES); /* 54 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLDATASOURCES); /* 57 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLDESCRIBEPARAM); /* 58 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLEXTENDEDFETCH); /* 59 deprecated ? */
/*
* for (++i; i < SQL_API_SQLBINDPARAMETER; i++)
* SQL_FUNC_ESET(pfExists, i);
*/
SQL_FUNC_ESET(pfExists, SQL_API_SQLFOREIGNKEYS); /* 60 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLMORERESULTS); /* 61 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLNATIVESQL); /* 62 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLNUMPARAMS); /* 63 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLPARAMOPTIONS); 64 deprecated */
SQL_FUNC_ESET(pfExists, SQL_API_SQLPRIMARYKEYS); /* 65 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLPROCEDURECOLUMNS); /* 66 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLPROCEDURES); /* 67 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSETPOS); /* 68 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLSETSCROLLOPTIONS); 69 deprecated */
SQL_FUNC_ESET(pfExists, SQL_API_SQLTABLEPRIVILEGES); /* 70 */
/* SQL_FUNC_ESET(pfExists, SQL_API_SQLDRIVERS); */ /* 71 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLBINDPARAMETER); /* 72 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLALLOCHANDLE); /* 1001 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLBINDPARAM); /* 1002 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLCLOSECURSOR); /* 1003 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLCOPYDESC); /* 1004 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLENDTRAN); /* 1005 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLFREEHANDLE); /* 1006 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETCONNECTATTR); /* 1007 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETDESCFIELD); /* 1008 */
SQL_FUNC_ESET(pfExists,
SQL_API_SQLGETDIAGFIELD); /* 1010 minimal implementation */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETDIAGREC); /* 1011 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETENVATTR); /* 1012 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLGETSTMTATTR); /* 1014 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSETCONNECTATTR); /* 1016 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSETDESCFIELD); /* 1017 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSETENVATTR); /* 1019 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLSETSTMTATTR); /* 1020 */
SQL_FUNC_ESET(pfExists, SQL_API_SQLFETCHSCROLL); /* 1021 */
return SQL_SUCCESS;
}
RETCODE SQL_API SQLBulkOperations(HSTMT hstmt, SQLSMALLINT operation) {
UNUSED(operation);
StatementClass *stmt = (StatementClass *)hstmt;
if (stmt == NULL)
return SQL_ERROR;
SC_clear_error(stmt);
SC_set_error(stmt, STMT_NOT_IMPLEMENTED_ERROR,
"Bulk operations are not supported.", "SQLBulkOperations");
return SQL_ERROR;
}
|
bd26c79dd603f72986cc12619a00fccdbb430618
|
8447eb38a4fc71b32b6b82a99f7828a2c50621aa
|
/ppu/include/ppu-types.h
|
2902fdb3da2d8b603b099dbf69c5a23e4648d530
|
[
"MIT"
] |
permissive
|
ps3dev/PSL1GHT
|
9ecc1f0a2996b39d35cc98303c58c79966b9388b
|
5bc0961c66a3615c74f15e0c29bbeaa33f867ab3
|
refs/heads/master
| 2023-08-04T06:50:55.256801
| 2023-07-30T13:34:19
| 2023-07-30T13:34:19
| 1,541,223
| 159
| 357
|
MIT
| 2023-07-23T07:26:09
| 2011-03-29T12:34:15
|
C
|
UTF-8
|
C
| false
| false
| 2,529
|
h
|
ppu-types.h
|
#ifndef __PPU_TYPES_H__
#define __PPU_TYPES_H__
#include <stdint.h>
#include <stdbool.h>
#include <stdlib.h>
#include <sys/types.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef uint8_t u8;
typedef uint16_t u16;
typedef uint32_t u32;
typedef uint64_t u64;
typedef int8_t s8;
typedef int16_t s16;
typedef int32_t s32;
typedef int64_t s64;
typedef volatile u8 vu8;
typedef volatile u16 vu16;
typedef volatile u32 vu32;
typedef volatile u64 vu64;
typedef volatile s8 vs8;
typedef volatile s16 vs16;
typedef volatile s32 vs32;
typedef volatile s64 vs64;
typedef float f32;
typedef double f64;
typedef volatile f32 vf32;
typedef volatile f64 vf64;
/* process */
/*! \brief opaque process id */
typedef u32 sys_pid_t;
/*! \brief opaque program segment id */
typedef u32 sys_program_segment_t;
/*! \brief opaque overlay module id */
typedef u32 sys_overlay_t;
typedef u32 sys_addr_t;
typedef u32 sys_mem_id_t;
typedef u32 sys_mem_addr_t;
typedef u32 sys_mem_container_t;
typedef u32 sys_raw_spu_t;
typedef u32 sys_spu_group_t;
typedef u32 sys_spu_thread_t;
typedef s64 system_time_t;
/*! \brief PPU thread identifier. */
typedef u64 sys_ppu_thread_t;
typedef u64 sys_ppu_thread_icontext_t;
typedef u32 sys_interrupt_tag_t;
typedef u64 sys_irqoutlet_id_t;
typedef u32 sys_hw_thread_t;
typedef u32 sys_interrupt_thread_handle_t;
typedef u32 sys_interrupt_handler_handle_t;
typedef u32 sys_cond_t;
/*! \brief Mutex identifier. */
typedef s32 sys_mutex_t;
/*! \brief Event queue id */
typedef u32 sys_event_queue_t;
/*! \brief Event port id */
typedef u32 sys_event_port_t;
/*! \brief IPC key id */
typedef u64 sys_ipc_key_t;
typedef u32 sys_sem_t;
typedef struct _opd64
{
void *func;
void *rtoc;
u64 zero;
} opd64;
typedef struct _opd32
{
u32 func;
u32 rtoc;
} opd32;
typedef union _ieee32
{
u32 u;
f32 f;
} ieee32;
typedef union _ieee64
{
u64 u;
f64 d;
} ieee64;
#ifndef TRUE
#define TRUE 1
#endif
#ifndef FALSE
#define FALSE 0
#endif
#ifndef NULL
#define NULL ((void*)0)
#endif
#define SPU_ALIGNMENT 128
#define SPU_ALIGNSIZE(x) (((x) + 127)&~127)
#define ATTRIBUTE_PRXPTR __attribute__((mode(SI)))
// courtesy of Marcan
#define STACK_ALIGN(type, name, cnt, alignment) u8 _al__##name[((sizeof(type)*(cnt)) + (alignment) + (((sizeof(type)*(cnt))%(alignment)) > 0 ? ((alignment) - ((sizeof(type)*(cnt))%(alignment))) : 0))]; \
type *name = (type*)(((u64)(_al__##name)) + ((alignment) - (((u64)(_al__##name))&((alignment)-1))))
#ifdef __cplusplus
}
#endif
#endif
|
ab49ae429055f78358e0de8db6169ae42f623526
|
309f9b2a66a89c2edcc300129359e8a79c37ceee
|
/include/fiwix/ata.h
|
dde560841164ea5407caf4d51a36cbadbbde5098
|
[
"MIT",
"LicenseRef-scancode-warranty-disclaimer"
] |
permissive
|
mikaku/Fiwix
|
47df5c58aaf9879e2bad6cf6b88d4ed9dfa57392
|
8a1352db07c843e3c53c3aa7f72f518acdab7d7b
|
refs/heads/master
| 2023-09-03T18:38:02.823376
| 2023-09-01T09:43:56
| 2023-09-01T09:43:56
| 129,542,762
| 195
| 18
|
MIT
| 2023-08-16T10:39:20
| 2018-04-14T18:15:22
|
C
|
UTF-8
|
C
| false
| false
| 11,741
|
h
|
ata.h
|
/*
* fiwix/include/fiwix/ata.h
*
* Copyright 2018-2022, Jordi Sanfeliu. All rights reserved.
* Distributed under the terms of the Fiwix License.
*/
#ifndef _FIWIX_ATA_H
#define _FIWIX_ATA_H
#include <fiwix/fs.h>
#include <fiwix/part.h>
#include <fiwix/sigcontext.h>
#include <fiwix/sleep.h>
#define IDE0_IRQ 14 /* primary controller interrupt */
#define IDE1_IRQ 15 /* secondary controller interrupt */
#define IDE0_MAJOR 3 /* 1st controller major number */
#define IDE1_MAJOR 22 /* 2nd controller major number */
#define IDE_MINORS 4 /* max. minors/partitions per unit */
#define IDE_MASTER_MSF 0 /* IDE master minor shift factor */
#define IDE_SLAVE_MSF 6 /* IDE slave minor shift factor */
#define IDE_PRIMARY 0
#define IDE_SECONDARY 1
#define IDE_MASTER 0
#define IDE_SLAVE 1
#define GET_DRIVE_NUM(_dev_) ((MINOR(_dev_) & (1 <<IDE_SLAVE_MSF)) ? IDE_SLAVE : IDE_MASTER)
#define NR_IDE_CTRLS 2 /* IDE controllers */
#define NR_ATA_DRVS 2 /* max. drives per IDE controller */
/* controller addresses */
#define IDE0_BASE 0x1F0 /* primary controller base addr */
#define IDE0_CTRL 0x3F4 /* primary controller control port */
#define IDE1_BASE 0x170 /* secondary controller base addr */
#define IDE1_CTRL 0x374 /* secondary controller control port */
#define IDE_BASE_LEN 7 /* controller address length */
#define ATA_RDY_RETR_LONG 50000 /* long delay for fast CPUs */
#define ATA_RDY_RETR_SHORT 500 /* short delay for slow CPUs */
#define MAX_IDE_ERR 10 /* number of retries */
#define MAX_CD_ERR 5 /* number of retries in CDROMs */
#define SET_ATA_RDY_RETR(retries) \
if((cpu_table.hz / 1000000) <= 100) { \
retries = ATA_RDY_RETR_SHORT; \
} else { \
retries = ATA_RDY_RETR_LONG; \
}
#define WAIT_FOR_DISK (1 * HZ) /* timeout for hard disk */
#define WAIT_FOR_CD (3 * HZ) /* timeout for cdrom */
/* controller registers */
#define ATA_DATA 0x0 /* Data Port Register (R/W) */
#define ATA_ERROR 0x1 /* Error Register (R) */
#define ATA_FEATURES 0x1 /* Features Register (W) */
#define ATA_SECCNT 0x2 /* Sector Count Register (R/W) */
#define ATA_SECTOR 0x3 /* Sector Number Register (R/W) */
#define ATA_LOWLBA 0x3 /* Low Byte of LBA Register (R/W) */
#define ATA_LCYL 0x4 /* Cylinder Low Register (R/W) */
#define ATA_MIDLBA 0x4 /* Mid Byte of LBA Register (R/W) */
#define ATA_HCYL 0x5 /* Cylinder High Register (R/W) */
#define ATA_HIGHLBA 0x5 /* High Byte of LBA Register (R/W) */
#define ATA_DRVHD 0x6 /* Drive/Head Register (R/W) */
#define ATA_STATUS 0x7 /* Status Register (R) */
#define ATA_COMMAND 0x7 /* Command Register (W) */
#define ATA_ALT_STATUS 0x2 /* Alternate Register (R) */
#define ATA_DEV_CTRL 0x2 /* Device Control Register (W) */
/* error register bits */
#define ATA_ERR_AMNF 0x01 /* Address Mark Not Found */
#define ATA_ERR_TK0NF 0x02 /* Track 0 Not Found */
#define ATA_ERR_ABRT 0x04 /* Aborted Command */
#define ATA_ERR_MCR 0x08 /* Media Change Registered */
#define ATA_ERR_IDNF 0x10 /* Sector ID Field Not Found */
#define ATA_ERR_MC 0x20 /* Media Changed */
#define ATA_ERR_UNC 0x40 /* Uncorrectable Data Error */
#define ATA_ERR_BBK 0x80 /* Bad Block */
/* status register bits */
#define ATA_STAT_ERR 0x01 /* an error ocurred */
#define ATA_STAT_SENS 0x02 /* sense data available */
#define ATA_STAT_CORR 0x04 /* a correctable error ocurred */
#define ATA_STAT_DRQ 0x08 /* device is ready to transfer */
#define ATA_STAT_DSC 0x10 /* device requests service o intr. */
#define ATA_STAT_DWF 0x20 /* drive write fault */
#define ATA_STAT_RDY 0x40 /* drive is ready */
#define ATA_STAT_BSY 0x80 /* drive is busy */
#define ATA_CHS_MODE 0xA0 /* select CHS mode */
#define ATA_LBA_MODE 0xE0 /* select LBA mode */
/* alternate & device control register bits */
#define ATA_DEVCTR_DRQ 0x08 /* Data Request */
#define ATA_DEVCTR_NIEN 0x02 /* Disable Interrupt */
#define ATA_DEVCTR_SRST 0x04 /* Software Reset */
/* ATA commands */
#define ATA_READ_PIO 0x20 /* read sector(s) with retries */
#define ATA_READ_MULTIPLE_PIO 0xC4 /* read multiple sectors */
#define ATA_WRITE_PIO 0x30 /* write sector(s) with retries */
#define ATA_WRITE_MULTIPLE_PIO 0xC5 /* write multiple sectors */
#define ATA_READ_DMA 0xC8 /* read data using DMA */
#define ATA_WRITE_DMA 0xCA /* write data using DMA */
#define ATA_SET_MULTIPLE_MODE 0xC6
#define ATA_PACKET 0xA0
#define ATA_IDENTIFY_PACKET 0xA1 /* identify ATAPI device */
#define ATA_IDENTIFY 0xEC /* identify ATA device */
#define ATA_SET_FEATURES 0xEF
/* ATA_SET_FEATURES subcommands */
#define ATA_SET_XFERMODE 0x03 /* set transfer mode */
/* ATAPI commands */
#define ATAPI_TEST_UNIT 0x00
#define ATAPI_REQUEST_SENSE 0x03
#define ATAPI_START_STOP 0x1B
#define ATAPI_MEDIUM_REMOVAL 0x1E
#define ATAPI_READ10 0x28
#define CD_UNLOCK_MEDIUM 0x00 /* allow medium removal */
#define CD_LOCK_MEDIUM 0x01 /* prevent medium removal */
#define CD_EJECT 0x02 /* eject the CD if possible */
#define CD_LOAD 0x03 /* load the CD (closes tray) */
/* ATAPI CD additional sense code */
#define ASC_NOT_READY 0x04
#define ASC_NO_MEDIUM 0x3A
/* capabilities */
#define ATA_SUPPORTS_CFA 0x848A
#define ATA_HAS_DMA 0x100 /* device supports Multi-word DMA */
#define ATA_HAS_LBA 0x200
#define ATA_MIN_LBA 16514064/* sectors limit for using CHS */
/* general configuration bits */
#define ATA_HAS_CURR_VALUES 0x01 /* current logical values are valid */
#define ATA_HAS_ADVANCED_PIO 0x02 /* device supports PIO 3 or 4 */
#define ATA_HAS_UDMA 0x04 /* device supports UDMA */
#define ATA_REMOVABLE 0x80 /* removable media device */
/* ATAPI types */
#define ATAPI_IS_SEQ_ACCESS 0x01 /* sequential-access device */
#define ATAPI_IS_PRINTER 0x02
#define ATAPI_IS_PROCESSOR 0x03
#define ATAPI_IS_WRITE_ONCE 0x04
#define ATAPI_IS_CDROM 0x05
#define ATAPI_IS_SCANNER 0x06
/* ATA drive flags */
#define DRIVE_IS_ATAPI 0x01
#define DRIVE_IS_CFA 0x02
#define DRIVE_IS_DISK 0x04
#define DRIVE_IS_CDROM 0x08
#define DRIVE_REQUIRES_LBA 0x10
#define DRIVE_HAS_RW_MULTIPLE 0x20
#define DRIVE_HAS_DMA 0x40
#define DRIVE_HAS_DATA32 0x80
#define PRDT_MARK_END 0x8000
/* ATA/ATAPI-4 based */
struct ata_drv_ident {
unsigned short int gen_config; /* general configuration bits */
unsigned short int logic_cyls; /* logical cylinders */
unsigned short int reserved2;
unsigned short int logic_heads; /* logical heads */
unsigned short int retired4;
unsigned short int retired5;
unsigned short int logic_spt; /* logical sectors/track */
unsigned short int retired7;
unsigned short int retired8;
unsigned short int retired9;
char serial_number[20]; /* serial number */
unsigned short int vendor_spec20;
unsigned short int buffer_cache;
unsigned short int vendor_spec22; /* reserved */
char firmware_rev[8]; /* firmware version */
char model_number[40]; /* model number */
unsigned short int rw_multiple;
unsigned short int reserved48;
unsigned short int capabilities; /* capabilities */
unsigned short int reserved50;
unsigned short int pio_mode; /* PIO data transfer mode*/
unsigned short int dma_mode;
unsigned short int fields_validity; /* fields validity */
unsigned short int cur_log_cyls; /* current logical cylinders */
unsigned short int cur_log_heads; /* current logical heads */
unsigned short int cur_log_spt; /* current logical sectors/track */
unsigned short int cur_capacity; /* current capacity in sectors */
unsigned short int cur_capacity2; /* 32bit number */
unsigned short int mult_sect_set; /* multiple sector settings */
unsigned short int tot_sectors; /* sectors (LBA only) */
unsigned short int tot_sectors2; /* 32bit number */
unsigned short int singleword_dma;
unsigned short int multiword_dma; /* multiword DMA settings */
unsigned short int adv_pio_modes; /* advanced PIO modes */
unsigned short int min_multiword; /* min. Multiword DMA transfer */
unsigned short int rec_multiword; /* recommended Multiword DMS transfer */
unsigned short int min_pio_wo_fc; /* min. PIO w/o flow control */
unsigned short int min_pio_w_fc; /* min. PIO with flow control */
unsigned short int reserved69;
unsigned short int reserved70;
unsigned short int reserved71;
unsigned short int reserved72;
unsigned short int reserved73;
unsigned short int reserved74;
unsigned short int queue_depth; /* queue depth */
unsigned short int reserved76;
unsigned short int reserved77;
unsigned short int reserved78;
unsigned short int reserved79;
unsigned short int majorver; /* major version number */
unsigned short int minorver; /* minor version number */
unsigned short int cmdset1; /* command set supported */
unsigned short int cmdset2; /* command set supported */
unsigned short int cmdsf_ext; /* command set/feature sup.ext. */
unsigned short int cmdsf_enable1; /* command s/f enabled */
unsigned short int cmdsf_enable2; /* command s/f enabled */
unsigned short int cmdsf_default; /* command s/f default */
unsigned short int ultradma; /* ultra DMA mode */
unsigned short int reserved89;
unsigned short int reserved90;
unsigned short int curapm; /* current APM values */
unsigned short int reserved92_126[35];
unsigned short int r_status_notif; /* removable media status notif. */
unsigned short int security_status; /* security status */
unsigned short int vendor_spec129_159[31];
unsigned short int reserved160_255[96];
};
struct prd {
unsigned int addr; /* physical address of buffer */
unsigned short int size; /* transfer size */
unsigned short int eot; /* End-Of-Table mark */
};
struct ata_xfer {
void (*read_fn)(unsigned int, void *, unsigned int);
int read_cmd;
void (*write_fn)(unsigned int, void *, unsigned int);
int write_cmd;
char copy_raw_factor; /* 2 for 16bit, 4 for 32bit */
struct prd prd_table; /* Physical Region Descriptor table */
unsigned char bm_command; /* bus master command register */
unsigned char bm_status; /* bus master status register */
unsigned char bm_prd_addr; /* bus master PRD table address */
};
struct ata_drv {
int num; /* master or slave */
char *name;
char *dev_name;
unsigned char major; /* major number */
unsigned int flags;
int minor_shift; /* shift factor to get the real minor */
int lba_cyls;
int lba_heads;
short int lba_factor;
unsigned int nr_sects; /* total sectors (LBA) */
int pio_mode;
int dma_mode;
int multi;
struct fs_operations *fsop;
struct ata_drv_ident ident;
struct ata_xfer xfer;
struct partition part_table[NR_PARTITIONS];
};
struct ide {
int channel; /* primary or secondary */
char *name;
int base; /* base address */
int ctrl; /* control port address */
int bm; /* bus master */
short int irq;
int wait_interrupt;
int irq_timeout;
void *timer_fn;
struct pci_device *pci_dev;
struct resource resource;
struct ata_drv drive[NR_ATA_DRVS];
};
extern struct ide *ide_table;
void irq_ide0(int, struct sigcontext *);
void ide0_timer(unsigned int);
void irq_ide1(int, struct sigcontext *);
void ide1_timer(unsigned int);
void ata_error(struct ide *, int);
void ata_delay(void);
void ata_wait400ns(struct ide *);
int ata_wait_state(struct ide *, unsigned char);
int ata_io(struct ide *, struct ata_drv *, __off_t, int);
int ata_wait_irq(struct ide *, int, int);
int ata_select_drv(struct ide *, int, int, unsigned char);
struct ide *get_ide_controller(__dev_t);
void ide_table_init(struct ide *, int);
int ata_channel_init(struct ide *);
int ata_open(struct inode *, struct fd *);
int ata_close(struct inode *, struct fd *);
int ata_read(__dev_t, __blk_t, char *, int);
int ata_write(__dev_t, __blk_t, char *, int);
int ata_ioctl(struct inode *, int, unsigned int);
__loff_t ata_llseek(struct inode *, __loff_t);
void ata_init(void);
#endif /* _FIWIX_ATA_H */
|
41285e47096550349311784f0c089c6340eccee7
|
06052ccd6db697947c1fcbb6ac96eba79c057fea
|
/lambdaLayers/SharpLayer/nodejs/node_modules/sharp/vendor/8.10.6/include/pango-1.0/pango/pango-utils.h
|
04452eb4fcb696750fc5e5073a252d9f8db17c1e
|
[
"MIT",
"Apache-2.0"
] |
permissive
|
venveo/serverless-sharp
|
89e673e8ab727a00a5bb3cf2c8b9b3876caec8db
|
1f64468784763bbf40c32497c35de69406765335
|
refs/heads/master
| 2023-04-15T01:45:01.990626
| 2022-06-29T12:30:07
| 2022-06-29T12:30:07
| 198,690,918
| 165
| 39
|
MIT
| 2023-03-04T04:28:54
| 2019-07-24T18:38:47
|
JavaScript
|
UTF-8
|
C
| false
| false
| 5,668
|
h
|
pango-utils.h
|
/* Pango
* pango-utils.c: Utilities for internal functions and modules
*
* Copyright (C) 2000 Red Hat Software
*
* 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.
*/
#ifndef __PANGO_UTILS_H__
#define __PANGO_UTILS_H__
#include <stdio.h>
#include <glib.h>
#include <pango/pango-font.h>
G_BEGIN_DECLS
PANGO_DEPRECATED
char ** pango_split_file_list (const char *str);
PANGO_DEPRECATED
char *pango_trim_string (const char *str);
PANGO_DEPRECATED
gint pango_read_line (FILE *stream,
GString *str);
PANGO_DEPRECATED
gboolean pango_skip_space (const char **pos);
PANGO_DEPRECATED
gboolean pango_scan_word (const char **pos,
GString *out);
PANGO_DEPRECATED
gboolean pango_scan_string (const char **pos,
GString *out);
PANGO_DEPRECATED
gboolean pango_scan_int (const char **pos,
int *out);
PANGO_DEPRECATED
gboolean pango_parse_enum (GType type,
const char *str,
int *value,
gboolean warn,
char **possible_values);
/* Functions for parsing textual representations
* of PangoFontDescription fields. They return TRUE if the input string
* contains a valid value, which then has been assigned to the corresponding
* field in the PangoFontDescription. If the warn parameter is TRUE,
* a warning is printed (with g_warning) if the string does not
* contain a valid value.
*/
PANGO_AVAILABLE_IN_ALL
gboolean pango_parse_style (const char *str,
PangoStyle *style,
gboolean warn);
PANGO_AVAILABLE_IN_ALL
gboolean pango_parse_variant (const char *str,
PangoVariant *variant,
gboolean warn);
PANGO_AVAILABLE_IN_ALL
gboolean pango_parse_weight (const char *str,
PangoWeight *weight,
gboolean warn);
PANGO_AVAILABLE_IN_ALL
gboolean pango_parse_stretch (const char *str,
PangoStretch *stretch,
gboolean warn);
/* Hint line position and thickness.
*/
PANGO_AVAILABLE_IN_1_12
void pango_quantize_line_geometry (int *thickness,
int *position);
/* A routine from fribidi that we either wrap or provide ourselves.
*/
PANGO_AVAILABLE_IN_1_4
guint8 * pango_log2vis_get_embedding_levels (const gchar *text,
int length,
PangoDirection *pbase_dir);
/* Unicode characters that are zero-width and should not be rendered
* normally.
*/
PANGO_AVAILABLE_IN_1_10
gboolean pango_is_zero_width (gunichar ch) G_GNUC_CONST;
/* Pango version checking */
/* Encode a Pango version as an integer */
/**
* PANGO_VERSION_ENCODE:
* @major: the major component of the version number
* @minor: the minor component of the version number
* @micro: the micro component of the version number
*
* This macro encodes the given Pango version into an integer. The numbers
* returned by %PANGO_VERSION and pango_version() are encoded using this macro.
* Two encoded version numbers can be compared as integers.
*/
#define PANGO_VERSION_ENCODE(major, minor, micro) ( \
((major) * 10000) \
+ ((minor) * 100) \
+ ((micro) * 1))
/* Encoded version of Pango at compile-time */
/**
* PANGO_VERSION:
*
* The version of Pango available at compile-time, encoded using PANGO_VERSION_ENCODE().
*/
/**
* PANGO_VERSION_STRING:
*
* A string literal containing the version of Pango available at compile-time.
*/
/**
* PANGO_VERSION_MAJOR:
*
* The major component of the version of Pango available at compile-time.
*/
/**
* PANGO_VERSION_MINOR:
*
* The minor component of the version of Pango available at compile-time.
*/
/**
* PANGO_VERSION_MICRO:
*
* The micro component of the version of Pango available at compile-time.
*/
#define PANGO_VERSION PANGO_VERSION_ENCODE( \
PANGO_VERSION_MAJOR, \
PANGO_VERSION_MINOR, \
PANGO_VERSION_MICRO)
/* Check that compile-time Pango is as new as required */
/**
* PANGO_VERSION_CHECK:
* @major: the major component of the version number
* @minor: the minor component of the version number
* @micro: the micro component of the version number
*
* Checks that the version of Pango available at compile-time is not older than
* the provided version number.
*/
#define PANGO_VERSION_CHECK(major,minor,micro) \
(PANGO_VERSION >= PANGO_VERSION_ENCODE(major,minor,micro))
/* Return encoded version of Pango at run-time */
PANGO_AVAILABLE_IN_1_16
int pango_version (void) G_GNUC_CONST;
/* Return run-time Pango version as an string */
PANGO_AVAILABLE_IN_1_16
const char * pango_version_string (void) G_GNUC_CONST;
/* Check that run-time Pango is as new as required */
PANGO_AVAILABLE_IN_1_16
const char * pango_version_check (int required_major,
int required_minor,
int required_micro) G_GNUC_CONST;
G_END_DECLS
#endif /* __PANGO_UTILS_H__ */
|
946f802a35cead52a9be146435bf189a0aba78cd
|
0744dcc5394cebf57ebcba343747af6871b67017
|
/apps/examples/board_specific_demo/ameba_cmsis_nn_demo/TestData/int16xint8_dilation_1/output_ref_data.h
|
df73802b95859de1b4e95032f5e60db6b1fd8b1f
|
[
"Apache-2.0",
"BSD-3-Clause",
"MIT"
] |
permissive
|
Samsung/TizenRT
|
96abf62f1853f61fcf91ff14671a5e0c6ca48fdb
|
1a5c2e00a4b1bbf4c505bbf5cc6a8259e926f686
|
refs/heads/master
| 2023-08-31T08:59:33.327998
| 2023-08-08T06:09:20
| 2023-08-31T04:38:20
| 82,517,252
| 590
| 719
|
Apache-2.0
| 2023-09-14T06:54:49
| 2017-02-20T04:38:30
|
C
|
UTF-8
|
C
| false
| false
| 15,908
|
h
|
output_ref_data.h
|
/*
* Copyright (C) 2010-2020 Arm Limited or its affiliates. All rights reserved.
*
* SPDX-License-Identifier: Apache-2.0
*
* 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
*
* 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.
*/
// Generated by generate_test_data.py using TFL version 2.6.0 as reference.
#pragma once
#include <stdint.h>
const q15_t int16xint8_dilation_1_output_ref[1800] = {
-23996, -19709, -24044, -19673, -23961, -19655, -23970, -19655, -23995, -19733, -24006, -19732, -23970, -19639,
-23975, -19641, -24028, -19596, -24030, -19629, -24077, -19664, -24054, -19547, -24003, -19588, -24070, -19629,
-24029, -19679, -23987, -19626, -23964, -19685, -23988, -19635, -23986, -19669, -23983, -19675, -24061, -19681,
-23956, -19650, -24046, -19620, -24061, -19668, -24005, -19626, -23966, -19600, -24043, -19729, -24092, -19638,
-24018, -19611, -24089, -19644, -24049, -19690, -23971, -19668, -23973, -19640, -23947, -19595, -24068, -19589,
-23992, -19642, -24150, -19583, -24000, -19625, -24057, -19567, -24044, -19642, -24086, -19649, -24057, -19626,
-23995, -19649, -24006, -19605, -23971, -19675, -24010, -19647, -24088, -19665, -23953, -19667, -24029, -19635,
-23990, -19666, -24085, -19623, -24025, -19674, -24070, -19577, -24043, -19647, -24070, -19645, -24069, -19683,
-23989, -19661, -24063, -19658, -24004, -19695, -24061, -19665, -23987, -19587, -24016, -19654, -24057, -19587,
-24050, -19665, -24048, -19634, -24021, -19595, -23968, -19609, -24031, -19536, -23995, -19643, -24036, -19655,
-24036, -19623, -23945, -19651, -24050, -19654, -24024, -19760, -24068, -19634, -23955, -19688, -24031, -19591,
-23989, -19643, -24006, -19607, -24007, -19537, -24003, -19573, -24025, -19623, -24059, -19614, -24024, -19544,
-24054, -19655, -24125, -19656, -24061, -19555, -23991, -19656, -24114, -19594, -24039, -19648, -24034, -19571,
-24053, -19610, -24052, -19669, -24044, -19544, -23948, -19688, -24106, -19611, -23965, -19681, -24069, -19615,
-24073, -19680, -23997, -19706, -24051, -19589, -23955, -19649, -24083, -19630, -24050, -19555, -23996, -19659,
-24101, -19575, -23924, -19616, -24081, -19568, -24066, -19731, -24039, -19612, -23954, -19633, -23956, -19660,
-24025, -19639, -23988, -19669, -24094, -19658, -23996, -19724, -24067, -19661, -23915, -19670, -24021, -19622,
-24047, -19690, -24064, -19577, -24027, -19656, -24052, -19645, -23978, -19603, -24006, -19704, -24048, -19563,
-23988, -19608, -24112, -19641, -24007, -19641, -24080, -19644, -23982, -19647, -24005, -19620, -24029, -19653,
-23996, -19632, -24020, -19594, -24041, -19624, -24090, -19623, -23968, -19619, -24091, -19588, -23992, -19599,
-24085, -19572, -24043, -19706, -24050, -19582, -23935, -19627, -24078, -19646, -24032, -19620, -24014, -19636,
-24053, -19647, -24046, -19683, -23976, -19600, -23997, -19695, -24038, -19657, -23992, -19632, -23997, -19620,
-24026, -19624, -24042, -19647, -24038, -19612, -24052, -19585, -24059, -19631, -24101, -19680, -24079, -19631,
-24001, -19580, -24094, -19612, -24081, -19548, -24065, -19606, -24140, -19605, -24063, -19595, -24090, -19652,
-24016, -19627, -24030, -19649, -24016, -19666, -24073, -19564, -24009, -19603, -24099, -19570, -24021, -19603,
-24088, -19599, -24081, -19607, -24065, -19616, -24055, -19626, -23934, -19583, -24120, -19585, -23989, -19587,
-24116, -19607, -24019, -19625, -24086, -19602, -24003, -19572, -24075, -19556, -24038, -19656, -24132, -19604,
-24001, -19633, -24084, -19628, -24040, -19705, -24002, -19610, -23971, -19617, -24047, -19625, -24011, -19577,
-24024, -19655, -24064, -19678, -24030, -19628, -24008, -19635, -24099, -19643, -24035, -19628, -24036, -19611,
-24022, -19614, -24066, -19669, -23989, -19580, -23989, -19615, -24044, -19651, -24059, -19618, -23997, -19645,
-24119, -19612, -24053, -19730, -24011, -19571, -23970, -19600, -24076, -19585, -24069, -19559, -24072, -19554,
-24050, -19601, -24096, -19608, -24075, -19705, -24119, -19637, -23999, -19676, -24074, -19665, -24023, -19621,
-24082, -19649, -24088, -19645, -24011, -19632, -24097, -19669, -24050, -19729, -24080, -19551, -24026, -19610,
-24077, -19619, -24058, -19591, -24034, -19657, -24032, -19682, -24050, -19657, -23985, -19636, -24065, -19584,
-24020, -19660, -24117, -19610, -24030, -19644, -24033, -19601, -24068, -19668, -24041, -19680, -24018, -19646,
-23962, -19666, -24004, -19653, -23993, -19671, -24000, -19718, -24009, -19648, -23974, -19664, -24012, -19645,
-24042, -19648, -23969, -19555, -24017, -19625, -24088, -19614, -24025, -19586, -24054, -19610, -24047, -19589,
-24008, -19624, -24048, -19609, -24008, -19634, -24080, -19691, -24069, -19588, -24009, -19650, -24070, -19614,
-23985, -19620, -24019, -19692, -24002, -19621, -23952, -19673, -24093, -19672, -24060, -19646, -24064, -19644,
-23980, -19633, -23969, -19645, -24029, -19616, -23985, -19675, -24074, -19653, -24040, -19650, -24020, -19665,
-24072, -19641, -23985, -19652, -24032, -19655, -23985, -19678, -23974, -19662, -24011, -19701, -24005, -19695,
-24012, -19695, -23999, -19632, -24013, -19643, -23986, -19643, -24108, -19699, -24005, -19607, -24011, -19592,
-24125, -19641, -24067, -19638, -23980, -19587, -24031, -19631, -24067, -19593, -24050, -19599, -24064, -19597,
-24064, -19609, -24052, -19598, -24097, -19597, -24031, -19697, -24010, -19573, -23994, -19590, -24048, -19657,
-24077, -19622, -24016, -19585, -24049, -19556, -24080, -19590, -24028, -19559, -24056, -19623, -24056, -19541,
-24032, -19624, -24093, -19602, -24057, -19647, -24025, -19650, -24062, -19650, -24042, -19627, -24012, -19666,
-24024, -19687, -23975, -19601, -24012, -19645, -24078, -19665, -24064, -19615, -24027, -19677, -24063, -19590,
-23996, -19607, -23987, -19652, -24018, -19686, -23991, -19684, -24045, -19568, -24007, -19674, -24041, -19580,
-23999, -19624, -24071, -19570, -23966, -19678, -24044, -19633, -23960, -19652, -23981, -19639, -24017, -19644,
-23984, -19627, -24027, -19618, -23989, -19579, -24013, -19593, -24091, -19620, -23981, -19665, -24059, -19580,
-23986, -19613, -24065, -19620, -24082, -19611, -24041, -19604, -23979, -19645, -24119, -19605, -24030, -19669,
-24074, -19626, -23979, -19679, -24049, -19649, -24066, -19651, -24047, -19648, -23997, -19680, -24045, -19669,
-24028, -19596, -24073, -19660, -24007, -19602, -24028, -19666, -23999, -19611, -23966, -19679, -24021, -19627,
-24058, -19631, -24052, -19687, -24074, -19609, -23992, -19639, -24068, -19581, -24025, -19706, -24053, -19621,
-23990, -19643, -24041, -19685, -24032, -19563, -23987, -19663, -24124, -19618, -24009, -19560, -24040, -19562,
-24102, -19542, -24025, -19656, -24072, -19633, -24024, -19647, -24014, -19653, -24029, -19683, -24073, -19651,
-24023, -19601, -23963, -19616, -24052, -19601, -24045, -19687, -23994, -19668, -23961, -19621, -23996, -19623,
-24091, -19644, -24068, -19585, -24004, -19606, -24110, -19588, -24032, -19616, -24047, -19581, -24060, -19593,
-24034, -19617, -24019, -19621, -24073, -19579, -24032, -19650, -24096, -19593, -24059, -19699, -23988, -19670,
-24004, -19683, -23987, -19694, -23992, -19635, -23995, -19577, -24045, -19715, -24081, -19646, -24047, -19644,
-24093, -19666, -23990, -19673, -24032, -19635, -24038, -19613, -23978, -19646, -24013, -19655, -23973, -19647,
-23994, -19673, -23993, -19686, -24024, -19623, -23995, -19638, -24025, -19608, -23986, -19638, -24060, -19701,
-24011, -19676, -24006, -19692, -24032, -19594, -24022, -19665, -24091, -19536, -24001, -19706, -24093, -19569,
-23948, -19625, -24024, -19708, -24010, -19605, -24014, -19655, -24044, -19642, -24070, -19608, -24057, -19661,
-24048, -19631, -24011, -19581, -24021, -19671, -24076, -19714, -24014, -19569, -23993, -19582, -24043, -19675,
-24073, -19611, -24009, -19633, -24037, -19660, -23959, -19613, -23954, -19643, -23978, -19667, -24039, -19673,
-23983, -19674, -24008, -19574, -24049, -19723, -24081, -19611, -24010, -19612, -24086, -19691, -24073, -19595,
-23996, -19686, -24056, -19705, -23971, -19692, -24027, -19688, -24006, -19644, -24013, -19583, -24002, -19619,
-23976, -19647, -24090, -19563, -24003, -19601, -24058, -19605, -24035, -19671, -24010, -19629, -24014, -19628,
-23953, -19592, -24066, -19645, -24039, -19666, -24029, -19666, -24006, -19613, -24016, -19602, -24011, -19626,
-23990, -19614, -24054, -19604, -24045, -19613, -24049, -19691, -24067, -19600, -23998, -19591, -23978, -19695,
-24060, -19562, -23992, -19666, -24107, -19628, -24040, -19663, -24049, -19585, -24086, -19640, -24030, -19662,
-24032, -19518, -23989, -19589, -24109, -19564, -24048, -19642, -24075, -19699, -24041, -19612, -23990, -19711,
-23975, -19658, -23967, -19608, -24014, -19598, -24090, -19674, -24068, -19610, -23945, -19610, -24032, -19679,
-24054, -19571, -23995, -19650, -24056, -19544, -24050, -19630, -24067, -19624, -24022, -19572, -24026, -19660,
-24048, -19666, -24023, -19550, -24005, -19684, -24106, -19586, -24049, -19650, -24072, -19617, -24031, -19584,
-24036, -19570, -24046, -19523, -24056, -19615, -24080, -19648, -24021, -19665, -24020, -19584, -24000, -19573,
-24119, -19731, -24059, -19633, -24029, -19634, -24035, -19615, -23991, -19667, -24029, -19655, -24006, -19643,
-24027, -19606, -24029, -19627, -24055, -19622, -24049, -19643, -24028, -19655, -24004, -19631, -23955, -19648,
-24081, -19631, -24008, -19630, -24031, -19576, -24078, -19644, -24067, -19694, -23975, -19621, -23960, -19640,
-23979, -19685, -24001, -19645, -23994, -19575, -24046, -19684, -24076, -19622, -23984, -19566, -24047, -19647,
-24066, -19640, -24084, -19660, -24036, -19594, -24085, -19618, -24033, -19644, -24014, -19622, -23986, -19595,
-24069, -19664, -24071, -19570, -24067, -19623, -24084, -19631, -23990, -19590, -24001, -19666, -24071, -19648,
-23964, -19610, -24068, -19673, -24055, -19648, -24030, -19637, -24059, -19658, -24025, -19619, -24048, -19530,
-24053, -19639, -24097, -19540, -24057, -19647, -24087, -19717, -24053, -19679, -23949, -19679, -23978, -19648,
-24034, -19667, -24007, -19625, -24020, -19584, -24002, -19576, -24074, -19651, -23948, -19594, -24016, -19694,
-24021, -19600, -23981, -19665, -24055, -19626, -23972, -19601, -24009, -19649, -23981, -19614, -24057, -19621,
-24013, -19698, -24038, -19594, -23972, -19690, -24087, -19590, -23964, -19695, -24019, -19592, -24007, -19622,
-24045, -19706, -24059, -19573, -24014, -19667, -24067, -19628, -24040, -19595, -24066, -19606, -24011, -19617,
-24024, -19656, -24042, -19677, -23982, -19690, -24022, -19625, -23952, -19699, -24067, -19641, -23924, -19659,
-24109, -19674, -24033, -19654, -24030, -19586, -24015, -19716, -24081, -19617, -23904, -19668, -24061, -19596,
-24048, -19664, -24110, -19668, -24038, -19584, -24025, -19614, -24068, -19509, -24087, -19692, -24159, -19583,
-24035, -19599, -24092, -19559, -24047, -19604, -24038, -19664, -24047, -19590, -23966, -19737, -24120, -19643,
-23981, -19692, -24044, -19654, -24021, -19611, -24042, -19606, -23996, -19635, -24064, -19615, -24042, -19568,
-24017, -19560, -24115, -19681, -24056, -19567, -24031, -19611, -24063, -19627, -24031, -19610, -24037, -19586,
-24062, -19568, -24085, -19643, -24082, -19614, -24015, -19585, -24015, -19643, -24100, -19654, -24025, -19611,
-23996, -19632, -24037, -19621, -24065, -19654, -23997, -19609, -24021, -19606, -24058, -19654, -24047, -19571,
-24059, -19632, -24094, -19614, -23997, -19606, -24065, -19680, -24076, -19679, -24024, -19554, -24008, -19683,
-24088, -19663, -23982, -19638, -23963, -19730, -23973, -19608, -24127, -19642, -24060, -19668, -24029, -19669,
-24019, -19660, -24015, -19700, -23988, -19613, -23981, -19611, -23991, -19548, -24041, -19643, -24072, -19661,
-24026, -19634, -24035, -19602, -24056, -19628, -24097, -19651, -24073, -19591, -24069, -19686, -24079, -19691,
-24036, -19693, -24007, -19620, -24040, -19550, -23987, -19674, -24028, -19651, -23995, -19745, -23933, -19579,
-23943, -19717, -24055, -19684, -24005, -19589, -24020, -19588, -24120, -19519, -24080, -19651, -24051, -19597,
-24069, -19639, -24057, -19661, -24041, -19657, -24013, -19643, -24018, -19587, -24022, -19672, -24132, -19654,
-23976, -19687, -24046, -19649, -23981, -19643, -24012, -19647, -24057, -19640, -24028, -19673, -24013, -19576,
-23998, -19645, -24095, -19659, -24038, -19588, -24042, -19619, -24060, -19645, -24086, -19628, -24051, -19689,
-24048, -19692, -24029, -19666, -23969, -19667, -24083, -19597, -23982, -19646, -24063, -19543, -24024, -19638,
-24118, -19599, -24041, -19684, -24097, -19652, -24066, -19680, -23983, -19661, -23975, -19609, -24035, -19653,
-24015, -19651, -23958, -19625, -24077, -19609, -24006, -19671, -24011, -19594, -23964, -19643, -24070, -19621,
-24015, -19699, -24026, -19622, -24039, -19567, -24049, -19618, -24099, -19665, -24053, -19615, -23954, -19663,
-24099, -19615, -24028, -19685, -24038, -19621, -23986, -19637, -23987, -19632, -23971, -19698, -24029, -19582,
-23922, -19655, -24076, -19659, -23989, -19669, -24054, -19619, -24006, -19635, -24044, -19606, -24075, -19618,
-24029, -19606, -24023, -19626, -24029, -19659, -24021, -19645, -24039, -19590, -24072, -19712, -24026, -19570,
-23951, -19615, -24074, -19597, -24011, -19597, -24085, -19571, -24022, -19616, -24125, -19656, -23969, -19643,
-24008, -19679, -23979, -19692, -24008, -19669, -23986, -19683, -24053, -19648, -23957, -19676, -24030, -19599,
-23980, -19671, -24005, -19677, -24025, -19694, -24005, -19582, -24055, -19610, -24058, -19701, -24032, -19669,
-23951, -19613, -24080, -19588, -24035, -19632, -24041, -19564, -24063, -19548, -24076, -19626, -24059, -19599,
-23996, -19619, -24069, -19687, -24045, -19571, -23971, -19634, -24109, -19563, -24023, -19685, -24072, -19559,
-24037, -19634, -24055, -19689, -23981, -19707, -24023, -19562, -23992, -19617, -24043, -19584, -24109, -19686,
-24041, -19626, -24011, -19632, -24017, -19640, -23993, -19618, -24017, -19573, -24076, -19623, -24060, -19596,
-24086, -19557, -23974, -19641, -24115, -19673, -23989, -19600, -24014, -19674, -24047, -19646, -24037, -19656,
-24021, -19580, -24026, -19602, -24084, -19573, -24060, -19695, -24141, -19577, -24023, -19626, -24019, -19622,
-24069, -19646, -24001, -19646, -24111, -19658, -23987, -19644, -24087, -19596, -23989, -19615, -24077, -19573,
-23973, -19650, -24077, -19599, -23994, -19611, -24050, -19641, -24022, -19611, -24059, -19638, -23993, -19627,
-23994, -19581, -24004, -19601, -23983, -19597, -23942, -19616, -24057, -19583, -24030, -19635, -24045, -19653,
-24035, -19732, -23972, -19615, -23967, -19642, -24071, -19671, -24015, -19654, -24021, -19677, -23958, -19606,
-24008, -19667, -24065, -19641, -24015, -19559, -24052, -19700, -24080, -19537, -24057, -19625, -24146, -19585,
-24022, -19608, -24014, -19613, -24068, -19656, -23978, -19687, -24005, -19684, -24000, -19578, -23992, -19598,
-24051, -19586, -24006, -19627, -24041, -19595, -24045, -19601};
|
43da0197988b3ff8820ad3eab1cd093fa0431eec
|
8838eb997879add5759b6dfb23f9a646464e53ca
|
/src/drivers/net/ne2k/ne2k.h
|
4edaa17d0ffd3eaea7bd1ef45acac3615a3274d5
|
[
"BSD-2-Clause"
] |
permissive
|
embox/embox
|
d6aacec876978522f01cdc4b8de37a668c6f4c80
|
98e3c06e33f3fdac10a29c069c20775568e0a6d1
|
refs/heads/master
| 2023-09-04T03:02:20.165042
| 2023-09-02T14:55:31
| 2023-09-02T14:55:31
| 33,078,138
| 1,087
| 325
|
BSD-2-Clause
| 2023-09-14T16:58:34
| 2015-03-29T15:27:48
|
C
|
UTF-8
|
C
| false
| false
| 6,148
|
h
|
ne2k.h
|
/**
* @file
* @brief ne2k register
* @date 01.07.2011
* @author Biff
* - Initial implementation
* @author Nikolay Korotky
* Ilia Vaprol
* - Adaptation for embox
*/
#ifndef NET_NE2K_PCI_H_
#define NET_NE2K_PCI_H_
extern int ne2k_dev_init(struct net_device *nic);
/* Port addresses */
#define NE_CMD 0x00 /* The command register (for all pages) */
/* Page 0 register offsets */
#define EN0_STARTPG 0x01 /* Starting page of ring buffer */
#define EN0_STOPPG 0x02 /* Ending page +1 of ring buffer */
#define EN0_BOUNDARY 0x03 /* Boundary page of ring buffer */
#define EN0_TSR 0x04 /* Transmit status reg RD */
#define EN0_TPSR 0x04
#define EN0_TBCR_LO 0x05 /* Low byte of tx byte count */
#define EN0_TBCR_HI 0x06 /* High byte of tx byte count */
#define EN0_ISR 0x07 /* Interrupt status reg */
/* Where to DMA data to/from */
#define EN0_RSARLO 0x08 /* Remote start address reg 0 */
#define EN0_RSARHI 0x09 /* Remote start address reg 1 */
/* How much data to DMA */
#define EN0_RCNTLO 0x0a /* Remote byte count reg */
#define EN0_RCNTHI 0x0b /* Remote byte count reg */
#define EN0_RXCR 0x0c /* RX configuration reg */
#define EN0_TXCR 0x0d /* TX configuration reg WR */
#define EN0_COUNTER0 0x0d /* Rcv alignment error counter RD */
#define EN0_DCFG 0x0e /* Data configuration reg WR */
#define EN0_COUNTER1 0x0e /* Rcv CRC error counter RD */
#define EN0_IMR 0x0f /* Interrupt mask reg WR */
#define EN0_COUNTER2 0x0f /* Rcv missed frame error counter RD */
/* Bits in receive configuration byte and EN0_RXCR */
#define ENRCR_SEP 0x01 /* Accept packets with receive errors */
#define ENRCR_AR 0x02 /* Accept packets with len < 64 */
#define ENRCR_AB 0x04 /* Accept packets with bcast dest address */
#define ENRCR_AM 0x08 /* Accept packets with mcast dest address */
#define ENRCR_PRO 0x10 /* Accept packets with physical dest address */
#define ENRCR_MON 0x20 /* Monitor mode (disable buffered to memory) */
/* Bits in received packet status byte and EN0_RSR */
#define ENRSR_RXOK 0x01 /* Received a good packet */
#define ENRSR_CRC 0x02 /* CRC error */
#define ENRSR_FAE 0x04 /* frame alignment error */
#define ENRSR_FO 0x08 /* FIFO overrun */
#define ENRSR_MPA 0x10 /* missed pkt */
#define ENRSR_PHY 0x20 /* physical/multicase address */
#define ENRSR_DIS 0x40 /* receiver disable. set in monitor mode */
#define ENRSR_DEF 0x80 /* deferring */
/* Bits in EN0_ISR - Interrupt status register */
#define ENISR_RX 0x01 /* Receiver, no error */
#define ENISR_TX 0x02 /* Transmitter, no error */
#define ENISR_RX_ERR 0x04 /* Receiver, with error */
#define ENISR_TX_ERR 0x08 /* Transmitter, with error */
#define ENISR_OVER 0x10 /* Receiver overwrote the ring */
#define ENISR_COUNTERS 0x20 /* Counters need emptying */
#define ENISR_RDC 0x40 /* remote dma complete */
#define ENISR_RESET 0x80 /* Reset completed */
#define ENISR_ALL 0x3f /* Interrupts we will enable */
/* Transmitted packet status, EN0_TSR. */
#define ENTSR_PTX 0x01 /* Packet transmitted without error */
#define ENTSR_ND 0x02 /* The transmit wasn't deferred. */
#define ENTSR_COL 0x04 /* The transmit collided at least once. */
#define ENTSR_ABT 0x08 /* The transmit collided 16 times, and was deferred. */
#define ENTSR_CRS 0x10 /* The carrier sense was lost. */
#define ENTSR_FU 0x20 /* A "FIFO underrun" occured during transmit. */
#define ENTSR_CDH 0x40 /* The collision detect "heartbeat" signal was lost. */
#define ENTSR_OWC 0x80 /* There was an out-of-window collision. */
/* Page 1 register offsets */
#define EN1_PHYS 0x01 /* This board's physical eth addr */
#define EN1_PHYS_SHIFT(i) (0x01 + i) /* Get and set mac address */
#define EN1_CURPAG 0x07 /* Current memory page RD WR */
#define EN1_MULT 0x08 /* Multicast filter mask array (8 bytes) */
#define EN1_MULT_SHIFT(i) (0x08 + i) /* Get and set multicast filter */
#define NE_DATAPORT 0x10 /* NatSemi-defined port window offset */
#define NE_RESET 0x1f /* Reset command */
/* Commands to select the different pages. */
#define NE_PAGE0_STOP 0x21
#define NE_PAGE1_STOP 0x61
#define NE_PAGE0 0x20
#define NE_PAGE1 0x60
#define NE_START 0x02
#define NE_STOP 0x01
#define NE_PAR0 0x01
#define NE_PAR1 0x02
#define NE_PAR2 0x03
#define NE_PAR3 0x04
#define NE_PAR4 0x05
#define NE_PAR5 0x06
//#define MEMBASE (16 * 1024)
//#define NE_PAGE_SIZE 256
//#define TX_BUFFER_START (MEMBASE / NE_PAGE_SIZE)
//#define NE_TXBUF_SIZE 6
//#define RX_BUFFER_START (TX_BUFFER_START + NE_TXBUF_SIZE)
//#define RX_BUFFER_END ((32 * 1024) / NE_PAGE_SIZE)
/* Applies to ne2000 version of the card. */
#define NESM_START_PG_TX 0x40 /* First page of TX buffer */
#define NESM_START_PG_RX 0x4C /* First page of RX buffer */
#define NESM_STOP_PG 0x80 /* Last page +1 of RX ring */
/* Some constants of e8390 family */
#define E8390_STOP 0x01 /* Stop and reset the chip */
#define E8390_START 0x02 /* Start the chip, clear reset */
#define E8390_TXOFF 0x02 /* EN0_TXCR: Transmitter off */
#define E8390_TRANS 0x04 /* Transmit a frame */
#define E8390_RREAD 0x08 /* Remote read */
#define E8390_RWRITE 0x10 /* Remote write */
#define E8390_NODMA 0x20 /* Remote DMA */
#define E8390_RXOFF 0x20 /* EN0_RXCR: Accept no packets */
#define E8390_PAGE0 0x00 /* Select page chip registers */
#define E8390_PAGE1 0x40 /* using the two high-order bits */
#define E8390_PAGE2 0x80 /* Page 3 is invalid. */
#define E8390_CMD 0x00 /* The command register (for all pages) */
#define E8390_RXCONFIG (ENRCR_AB | ENRCR_PRO) /* EN0_RXCR */
#define E8390_TXCONFIG 0x00 /* EN0_TXCR: Normal transmit mode */
#endif /* NET_NE2K_PCI_H_ */
|
858c9f279659ac805e0b86656a56dca0c9ea2be7
|
44a742973d9db97b35c88d4c28f538a48a3029c8
|
/pl/math/sv_cexpi_3u5.c
|
941810f246be4b58edb089b52e4906fb4dbb884b
|
[
"LLVM-exception",
"MIT",
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
ARM-software/optimized-routines
|
ac3349617ef6c7119050e1a26f33a040448a5c7b
|
4bdee55e42855a884f9da47abfe8c612b8534294
|
refs/heads/master
| 2023-08-15T11:56:21.269079
| 2023-08-14T12:34:34
| 2023-08-14T12:34:50
| 45,979,634
| 478
| 85
|
NOASSERTION
| 2023-09-12T08:13:38
| 2015-11-11T12:12:32
|
C
|
UTF-8
|
C
| false
| false
| 1,524
|
c
|
sv_cexpi_3u5.c
|
/*
* Double-precision vector cexpi function.
*
* Copyright (c) 2023, Arm Limited.
* SPDX-License-Identifier: MIT OR Apache-2.0 WITH LLVM-exception
*/
#include "sv_sincos_common.h"
#include "sv_math.h"
#include "pl_test.h"
static svfloat64x2_t NOINLINE
special_case (svfloat64_t x, svbool_t special, svfloat64x2_t y)
{
return svcreate2 (sv_call_f64 (sin, x, svget2 (y, 0), special),
sv_call_f64 (cos, x, svget2 (y, 1), special));
}
/* Double-precision vector function allowing calculation of both sin and cos in
one function call, using shared argument reduction and separate polynomials.
Largest observed error is for sin, 3.22 ULP:
sv_cexpi_sin (0x1.d70eef40f39b1p+12) got -0x1.ffe9537d5dbb7p-3
want -0x1.ffe9537d5dbb4p-3. */
svfloat64x2_t
_ZGVsMxv_cexpi (svfloat64_t x, svbool_t pg)
{
const struct sv_sincos_data *d = ptr_barrier (&sv_sincos_data);
svbool_t special = check_ge_rangeval (pg, x, d);
svfloat64x2_t sc = sv_sincos_inline (pg, x, d);
if (unlikely (svptest_any (pg, special)))
return special_case (x, special, sc);
return sc;
}
PL_TEST_ULP (sv_cexpi_sin, 2.73)
PL_TEST_ULP (sv_cexpi_cos, 2.73)
#define SV_CEXPI_INTERVAL(lo, hi, n) \
PL_TEST_INTERVAL (sv_cexpi_sin, lo, hi, n) \
PL_TEST_INTERVAL (sv_cexpi_cos, lo, hi, n)
SV_CEXPI_INTERVAL (0, 0x1p23, 500000)
SV_CEXPI_INTERVAL (-0, -0x1p23, 500000)
SV_CEXPI_INTERVAL (0x1p23, inf, 10000)
SV_CEXPI_INTERVAL (-0x1p23, -inf, 10000)
|
2cd5df8f564741d17ead5d991ea4d218d00b6510
|
1af43c4ba32d78c60f007a4d068136ce575d917f
|
/tools/rtl433/rtltest/devices/quhwa.c
|
919a6913daf67620b50f203257a9fd1951e956da
|
[
"MIT"
] |
permissive
|
gabonator/LA104
|
a4f1cdf2b3e513300d61c50fff091c5717abda9e
|
27d0eece7302c479da2cf86e881b6a51a535f93d
|
refs/heads/master
| 2023-08-31T22:09:36.272616
| 2023-08-27T20:08:08
| 2023-08-27T20:08:08
| 155,659,451
| 500
| 69
|
MIT
| 2023-08-17T08:44:32
| 2018-11-01T03:54:21
|
C
|
UTF-8
|
C
| false
| false
| 1,655
|
c
|
quhwa.c
|
/* Quhwa
* HS1527
*
* Tested devices:
* QH-C-CE-3V (which should be compatible with QH-832AC),
* also sold as "1 by One" wireless doorbell
*
* Copyright (C) 2016 Ask Jakobsen
* 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 2 of the License, or
* (at your option) any later version.
*/
#include "decoder.h"
static int quhwa_callback(r_device *decoder, bitbuffer_t *bitbuffer)
{
int r = bitbuffer_find_repeated_row(bitbuffer, 5, 18);
if (r < 0)
return 0;
uint8_t *b = bitbuffer->bb[r];
b[0] = ~b[0];
b[1] = ~b[1];
b[2] = ~b[2];
if (bitbuffer->bits_per_row[r] != 18
|| (b[1] & 0x03) != 0x03
|| (b[2] & 0xC0) != 0xC0)
return 0;
uint32_t id = (b[0] << 8) | b[1];
data_t *data = data_make(
"model", "", DATA_STRING, "Quhwa doorbell",
"id", "ID", DATA_INT, id,
NULL);
decoder_output_data(decoder, data);
return 1;
}
static char *output_fields[] = {
"model",
"id",
NULL
};
r_device quhwa = {
.name = "Quhwa",
.modulation = OOK_PULSE_PWM,
.short_width = 360, // Pulse: Short 360µs, Long 1070µs
.long_width = 1070, // Gaps: Short 360µs, Long 1070µs
.reset_limit = 6600, // Intermessage Gap 6500µs
.gap_limit = 1200, // Long Gap 1120µs
.sync_width = 0, // No sync bit used
.tolerance = 80, // us
.decode_fn = &quhwa_callback,
.disabled = 0,
.fields = output_fields
};
|
8a0fbf310d26eb1a88692f7e7f7d42f681c8e0c4
|
a831bb046bdc40567682f01f2dc8e73a3803120e
|
/libs/mrcp-server/include/mrcp_server.h
|
a1b4ad37f016405f231e06995d593db9427b5c5b
|
[
"Apache-2.0",
"LicenseRef-scancode-public-domain",
"LGPL-2.1-or-later"
] |
permissive
|
unispeech/unimrcp
|
5d9567c63d849c0e50bf0ee7b11259a798648d3e
|
9913f23691b3a1b8a7e84be5ba25478031352158
|
refs/heads/master
| 2023-08-05T08:22:40.918060
| 2023-08-01T17:35:29
| 2023-08-01T17:35:29
| 38,894,063
| 363
| 159
|
Apache-2.0
| 2023-05-17T12:50:27
| 2015-07-10T17:49:42
|
C
|
UTF-8
|
C
| false
| false
| 7,573
|
h
|
mrcp_server.h
|
/*
* Copyright 2008-2015 Arsen Chaloyan
*
* 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.
*/
#ifndef MRCP_SERVER_H
#define MRCP_SERVER_H
/**
* @file mrcp_server.h
* @brief MRCP Server
*/
#include "mrcp_server_types.h"
#include "mrcp_engine_iface.h"
#include "mpf_rtp_descriptor.h"
#include "apt_task.h"
APT_BEGIN_EXTERN_C
/**
* Create MRCP server instance.
* @return the created server instance
*/
MRCP_DECLARE(mrcp_server_t*) mrcp_server_create(apt_dir_layout_t *dir_layout);
/**
* Start message processing loop.
* @param server the MRCP server to start
* @return the created server instance
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_start(mrcp_server_t *server);
/**
* Take server offline.
* @param server the MRCP server to take offline
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_offline(mrcp_server_t *server);
/**
* Bring server online.
* @param server the MRCP server to bring online
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_online(mrcp_server_t *server);
/**
* Shutdown message processing loop.
* @param server the MRCP server to shutdown
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_shutdown(mrcp_server_t *server);
/**
* Destroy MRCP server.
* @param server the MRCP server to destroy
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_destroy(mrcp_server_t *server);
/**
* Register MRCP resource factory.
* @param server the MRCP server to set resource factory for
* @param resource_factory the resource factory to set
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_resource_factory_register(
mrcp_server_t *server,
mrcp_resource_factory_t *resource_factory);
/**
* Register MRCP engine.
* @param server the MRCP server to set engine for
* @param engine the engine to set
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_engine_register(
mrcp_server_t *server,
mrcp_engine_t *engine);
/**
* Register codec manager.
* @param server the MRCP server to set codec manager for
* @param codec_manager the codec manager to set
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_codec_manager_register(mrcp_server_t *server, mpf_codec_manager_t *codec_manager);
/**
* Get registered codec manager.
* @param server the MRCP server to get codec manager from
*/
MRCP_DECLARE(const mpf_codec_manager_t*) mrcp_server_codec_manager_get(const mrcp_server_t *server);
/**
* Register media engine.
* @param server the MRCP server to set media engine for
* @param media_engine the media engine to set
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_media_engine_register(
mrcp_server_t *server,
mpf_engine_t *media_engine);
/**
* Register RTP termination factory.
* @param server the MRCP server to set termination factory for
* @param rtp_termination_factory the termination factory
* @param name the name of the factory
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_rtp_factory_register(
mrcp_server_t *server,
mpf_termination_factory_t *rtp_termination_factory,
const char *name);
/**
* Register RTP settings.
* @param server the MRCP server to set RTP settings for
* @param rtp_settings the settings to set
* @param name the name of the settings
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_rtp_settings_register(
mrcp_server_t *server,
mpf_rtp_settings_t *rtp_settings,
const char *name);
/**
* Register MRCP signaling agent.
* @param server the MRCP server to set signaling agent for
* @param signaling_agent the signaling agent to set
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_signaling_agent_register(
mrcp_server_t *server,
mrcp_sig_agent_t *signaling_agent);
/**
* Register MRCP connection agent (MRCPv2 only).
* @param server the MRCP server to set connection agent for
* @param connection_agent the connection agent to set
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_connection_agent_register(
mrcp_server_t *server,
mrcp_connection_agent_t *connection_agent);
/** Create MRCP profile */
MRCP_DECLARE(mrcp_server_profile_t*) mrcp_server_profile_create(
const char *id,
mrcp_version_e mrcp_version,
mrcp_resource_factory_t *resource_factory,
mrcp_sig_agent_t *signaling_agent,
mrcp_connection_agent_t *connection_agent,
mpf_engine_t *media_engine,
mpf_termination_factory_t *rtp_factory,
mpf_rtp_settings_t *rtp_settings,
apr_pool_t *pool);
/**
* Register MRCP profile.
* @param server the MRCP server to set profile for
* @param profile the profile to set
* @param resource_engine_map the map of resource ids and engine settings (resource id -> mrcp_engine_settings_t*)
*/
MRCP_DECLARE(apt_bool_t) mrcp_server_profile_register(
mrcp_server_t *server,
mrcp_server_profile_t *profile,
apr_hash_t *resource_engine_map);
/**
* Load MRCP engine as a plugin.
* @param server the MRCP server to use
* @param id the identifier of the plugin
* @param path the path to the plugin to load
* @param config the config of the engine
*/
MRCP_DECLARE(mrcp_engine_t*) mrcp_server_engine_load(
mrcp_server_t *server,
const char *id,
const char *path,
mrcp_engine_config_t *config);
/**
* Get memory pool.
* @param server the MRCP server to get memory pool from
*/
MRCP_DECLARE(apr_pool_t*) mrcp_server_memory_pool_get(const mrcp_server_t *server);
/**
* Get MRCP engine by name.
* @param server the MRCP server to get media engine from
* @param name the name of the media engine to lookup
*/
MRCP_DECLARE(mrcp_engine_t*) mrcp_server_engine_get(const mrcp_server_t *server, const char *name);
/**
* Get media engine by name.
* @param server the MRCP server to get media engine from
* @param name the name of the media engine to lookup
*/
MRCP_DECLARE(mpf_engine_t*) mrcp_server_media_engine_get(const mrcp_server_t *server, const char *name);
/**
* Get RTP termination factory by name.
* @param server the MRCP server to get from
* @param name the name to lookup
*/
MRCP_DECLARE(mpf_termination_factory_t*) mrcp_server_rtp_factory_get(const mrcp_server_t *server, const char *name);
/**
* Get RTP settings by name
* @param server the MRCP server to get from
* @param name the name to lookup
*/
MRCP_DECLARE(mpf_rtp_settings_t*) mrcp_server_rtp_settings_get(const mrcp_server_t *server, const char *name);
/**
* Get signaling agent by name.
* @param server the MRCP server to get from
* @param name the name to lookup
*/
MRCP_DECLARE(mrcp_sig_agent_t*) mrcp_server_signaling_agent_get(const mrcp_server_t *server, const char *name);
/**
* Get connection agent by name.
* @param server the MRCP server to get from
* @param name the name to lookup
*/
MRCP_DECLARE(mrcp_connection_agent_t*) mrcp_server_connection_agent_get(const mrcp_server_t *server, const char *name);
/**
* Get profile by name.
* @param server the MRCP client to get from
* @param name the name to lookup
*/
MRCP_DECLARE(mrcp_server_profile_t*) mrcp_server_profile_get(const mrcp_server_t *server, const char *name);
APT_END_EXTERN_C
#endif /* MRCP_SERVER_H */
|
49721ee6a0d223184b7de8e05ab2e588aa7ed9e9
|
fbdc48c28e54fb33ae4842ef95ff63893902c99a
|
/src/drivers/winc1500/src/nm_common.c
|
c626aca14ba3147305353dce516ec35a49700ebd
|
[
"MIT"
] |
permissive
|
openmv/openmv
|
44d4b79fc8693950a2e330e5e0fd95b5c36e230f
|
8a90e070a88b7fc14c87a00351b9c4a213278419
|
refs/heads/master
| 2023-08-30T20:59:57.227603
| 2023-08-23T16:50:55
| 2023-08-23T16:50:55
| 14,360,940
| 2,150
| 1,226
|
MIT
| 2023-09-14T07:18:15
| 2013-11-13T10:23:44
|
C
|
UTF-8
|
C
| false
| false
| 2,995
|
c
|
nm_common.c
|
/**
*
* \file
*
* \brief This module contains common APIs declarations.
*
* Copyright (c) 2016-2018 Microchip Technology Inc. and its subsidiaries.
*
* \asf_license_start
*
* \page License
*
* Subject to your compliance with these terms, you may use Microchip
* software and any derivatives exclusively with Microchip products.
* It is your responsibility to comply with third party license terms applicable
* to your use of third party software (including open source software) that
* may accompany Microchip software.
*
* THIS SOFTWARE IS SUPPLIED BY MICROCHIP "AS IS". NO WARRANTIES,
* WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS SOFTWARE,
* INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY,
* AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT WILL MICROCHIP BE
* LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL OR CONSEQUENTIAL
* LOSS, DAMAGE, COST OR EXPENSE OF ANY KIND WHATSOEVER RELATED TO THE
* SOFTWARE, HOWEVER CAUSED, EVEN IF MICROCHIP HAS BEEN ADVISED OF THE
* POSSIBILITY OR THE DAMAGES ARE FORESEEABLE. TO THE FULLEST EXTENT
* ALLOWED BY LAW, MICROCHIP'S TOTAL LIABILITY ON ALL CLAIMS IN ANY WAY
* RELATED TO THIS SOFTWARE WILL NOT EXCEED THE AMOUNT OF FEES, IF ANY,
* THAT YOU HAVE PAID DIRECTLY TO MICROCHIP FOR THIS SOFTWARE.
*
* \asf_license_stop
*
*/
#include "common/include/nm_common.h"
void m2m_memcpy(uint8* pDst,uint8* pSrc,uint32 sz)
{
if(sz == 0) return;
do
{
*pDst = *pSrc;
pDst++;
pSrc++;
}while(--sz);
}
uint8 m2m_checksum(uint8* buf, int sz)
{
uint8 cs = 0;
while(--sz)
{
cs ^= *buf;
buf++;
}
return cs;
}
void m2m_memset(uint8* pBuf,uint8 val,uint32 sz)
{
if(sz == 0) return;
do
{
*pBuf = val;
pBuf++;
}while(--sz);
}
uint16 m2m_strlen(uint8 * pcStr)
{
uint16 u16StrLen = 0;
while(*pcStr)
{
u16StrLen ++;
pcStr++;
}
return u16StrLen;
}
uint8 m2m_strncmp(uint8 *pcS1, uint8 *pcS2, uint16 u16Len)
{
for ( ; u16Len > 0; pcS1++, pcS2++, --u16Len)
if (*pcS1 != *pcS2)
return ((*(uint8 *)pcS1 < *(uint8 *)pcS2) ? -1 : +1);
else if (*pcS1 == '\0')
return 0;
return 0;
}
/* Finds the occurrence of pcStr in pcIn.
If pcStr is part of pcIn it returns a valid pointer to the start of pcStr within pcIn.
Otherwise a NULL Pointer is returned.
*/
uint8 * m2m_strstr(uint8 *pcIn, uint8 *pcStr)
{
uint8 u8c;
uint16 u16StrLen;
u8c = *pcStr++;
if (!u8c)
return (uint8 *) pcIn; // Trivial empty string case
u16StrLen = m2m_strlen(pcStr);
do {
uint8 u8Sc;
do {
u8Sc = *pcIn++;
if (!u8Sc)
return (uint8 *) 0;
} while (u8Sc != u8c);
} while (m2m_strncmp(pcIn, pcStr, u16StrLen) != 0);
return (uint8 *) (pcIn - 1);
}
sint8 m2m_memcmp(uint8 *pu8Buff1,uint8 *pu8Buff2 ,uint32 u32Size)
{
uint32 i;
sint8 s8Result = 0;
for(i = 0 ; i < u32Size ; i++)
{
if(pu8Buff1[i] != pu8Buff2[i])
{
s8Result = 1;
break;
}
}
return s8Result;
}
|
ef0efa880dead85099bf5de442af6bedd6daa0d4
|
99bdb3251fecee538e0630f15f6574054dfc1468
|
/bsp/nuvoton/numaker-iot-ma35d1/board/board_dev.c
|
89a03d8355fe4828b9e47c32f22b069515b625ff
|
[
"Zlib",
"LicenseRef-scancode-proprietary-license",
"MIT",
"BSD-3-Clause",
"X11",
"BSD-4-Clause-UC",
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] |
permissive
|
RT-Thread/rt-thread
|
03a7c52c2aeb1b06a544143b0e803d72f47d1ece
|
3602f891211904a27dcbd51e5ba72fefce7326b2
|
refs/heads/master
| 2023-09-01T04:10:20.295801
| 2023-08-31T16:20:55
| 2023-08-31T16:20:55
| 7,408,108
| 9,599
| 5,805
|
Apache-2.0
| 2023-09-14T13:37:26
| 2013-01-02T14:49:21
|
C
|
UTF-8
|
C
| false
| false
| 8,817
|
c
|
board_dev.c
|
/**************************************************************************//**
*
* @copyright (C) 2019 Nuvoton Technology Corp. All rights reserved.
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
* 2021-6-1 Wayne First version
*
******************************************************************************/
#include <rtthread.h>
#include <rtdevice.h>
#include "drv_gpio.h"
#include "drv_sys.h"
#include "drv_sspcc.h"
#include "board.h"
#if defined(BOARD_USING_STORAGE_SPIFLASH)
#if defined(RT_USING_SFUD)
#include "spi_flash.h"
#include "spi_flash_sfud.h"
#endif
#include "drv_qspi.h"
#define W25X_REG_READSTATUS (0x05)
#define W25X_REG_READSTATUS2 (0x35)
#define W25X_REG_WRITEENABLE (0x06)
#define W25X_REG_WRITESTATUS (0x01)
#define W25X_REG_QUADENABLE (0x02)
static rt_uint8_t SpiFlash_ReadStatusReg(struct rt_qspi_device *qspi_device)
{
rt_uint8_t u8Val;
rt_err_t result = RT_EOK;
rt_uint8_t w25x_txCMD1 = W25X_REG_READSTATUS;
result = rt_qspi_send_then_recv(qspi_device, &w25x_txCMD1, 1, &u8Val, 1);
RT_ASSERT(result > 0);
return u8Val;
}
static rt_uint8_t SpiFlash_ReadStatusReg2(struct rt_qspi_device *qspi_device)
{
rt_uint8_t u8Val;
rt_err_t result = RT_EOK;
rt_uint8_t w25x_txCMD1 = W25X_REG_READSTATUS2;
result = rt_qspi_send_then_recv(qspi_device, &w25x_txCMD1, 1, &u8Val, 1);
RT_ASSERT(result > 0);
return u8Val;
}
static rt_err_t SpiFlash_WriteStatusReg(struct rt_qspi_device *qspi_device, uint8_t u8Value1, uint8_t u8Value2)
{
rt_uint8_t w25x_txCMD1;
rt_uint8_t au8Val[2];
rt_err_t result;
struct rt_qspi_message qspi_message = {0};
/* Enable WE */
w25x_txCMD1 = W25X_REG_WRITEENABLE;
result = rt_qspi_send(qspi_device, &w25x_txCMD1, sizeof(w25x_txCMD1));
if (result != sizeof(w25x_txCMD1))
goto exit_SpiFlash_WriteStatusReg;
/* Prepare status-1, 2 data */
au8Val[0] = u8Value1;
au8Val[1] = u8Value2;
/* 1-bit mode: Instruction+payload */
qspi_message.instruction.content = W25X_REG_WRITESTATUS;
qspi_message.instruction.qspi_lines = 1;
qspi_message.qspi_data_lines = 1;
qspi_message.parent.cs_take = 1;
qspi_message.parent.cs_release = 1;
qspi_message.parent.send_buf = &au8Val[0];
qspi_message.parent.length = sizeof(au8Val);
qspi_message.parent.next = RT_NULL;
if (rt_qspi_transfer_message(qspi_device, &qspi_message) != sizeof(au8Val))
{
result = -RT_ERROR;
}
result = RT_EOK;
exit_SpiFlash_WriteStatusReg:
return result;
}
static void SpiFlash_WaitReady(struct rt_qspi_device *qspi_device)
{
volatile uint8_t u8ReturnValue;
do
{
u8ReturnValue = SpiFlash_ReadStatusReg(qspi_device);
u8ReturnValue = u8ReturnValue & 1;
}
while (u8ReturnValue != 0); // check the BUSY bit
}
static void SpiFlash_EnterQspiMode(struct rt_qspi_device *qspi_device)
{
rt_err_t result = RT_EOK;
uint8_t u8Status1 = SpiFlash_ReadStatusReg(qspi_device);
uint8_t u8Status2 = SpiFlash_ReadStatusReg2(qspi_device);
u8Status2 |= W25X_REG_QUADENABLE;
result = SpiFlash_WriteStatusReg(qspi_device, u8Status1, u8Status2);
RT_ASSERT(result == RT_EOK);
SpiFlash_WaitReady(qspi_device);
}
static void SpiFlash_ExitQspiMode(struct rt_qspi_device *qspi_device)
{
rt_err_t result = RT_EOK;
uint8_t u8Status1 = SpiFlash_ReadStatusReg(qspi_device);
uint8_t u8Status2 = SpiFlash_ReadStatusReg2(qspi_device);
u8Status2 &= ~W25X_REG_QUADENABLE;
result = SpiFlash_WriteStatusReg(qspi_device, u8Status1, u8Status2);
RT_ASSERT(result == RT_EOK);
SpiFlash_WaitReady(qspi_device);
}
static int rt_hw_spiflash_init(void)
{
if (nu_qspi_bus_attach_device("qspi0", "qspi01", 4, SpiFlash_EnterQspiMode, SpiFlash_ExitQspiMode) != RT_EOK)
return -1;
#if defined(RT_USING_SFUD)
if (rt_sfud_flash_probe(FAL_USING_NOR_FLASH_DEV_NAME, "qspi01") == RT_NULL)
{
return -(RT_ERROR);
}
#endif
return 0;
}
INIT_DEVICE_EXPORT(rt_hw_spiflash_init);
#endif /* BOARD_USING_STORAGE_SPIFLASH */
#if defined(BOARD_USING_STORAGE_SPINAND) && defined(NU_PKG_USING_SPINAND)
#include "drv_qspi.h"
#include "spinand.h"
struct rt_mtd_nand_device mtd_partitions[MTD_SPINAND_PARTITION_NUM] =
{
[0] =
{
/*nand0: U-boot, env, rtthread*/
.block_start = 0,
.block_end = 63,
.block_total = 64,
},
[1] =
{
/*nand1: for filesystem mounting*/
.block_start = 64,
.block_end = 4095,
.block_total = 4032,
},
[2] =
{
/*nand2: Whole blocks size, overlay*/
.block_start = 0,
.block_end = 4095,
.block_total = 4096,
}
};
static int rt_hw_spinand_init(void)
{
if (nu_qspi_bus_attach_device("qspi0", "qspi01", 4, RT_NULL, RT_NULL) != RT_EOK)
return -1;
if (rt_hw_mtd_spinand_register("qspi01") != RT_EOK)
return -1;
return 0;
}
INIT_DEVICE_EXPORT(rt_hw_spinand_init);
#endif
#if defined(BOARD_USING_STORAGE_RAWNAND) && defined(BSP_USING_NFI)
struct rt_mtd_nand_device mtd_partitions_nfi[MTD_NFI_PARTITION_NUM] =
{
[0] =
{
/*nand0: rtthread*/
.block_start = 0,
.block_end = 63,
.block_total = 64,
},
[1] =
{
/*nand1: for filesystem mounting*/
.block_start = 64,
.block_end = 8191,
.block_total = 8128,
},
[2] =
{
/*nand2: Whole blocks size, overlay*/
.block_start = 0,
.block_end = 8191,
.block_total = 8192,
}
};
#endif
#if defined(BOARD_USING_NAU8822) && defined(NU_PKG_USING_NAU8822)
#include <acodec_nau8822.h>
S_NU_NAU8822_CONFIG sCodecConfig =
{
.i2c_bus_name = "i2c1",
.i2s_bus_name = "sound0",
.pin_phonejack_en = NU_GET_PININDEX(NU_PC, 2),
.pin_phonejack_det = NU_GET_PININDEX(NU_PC, 3),
};
int rt_hw_nau8822_port(void)
{
if (nu_hw_nau8822_init(&sCodecConfig) != RT_EOK)
return -1;
return 0;
}
INIT_COMPONENT_EXPORT(rt_hw_nau8822_port);
#endif /* BOARD_USING_NAU8822 */
#if defined(BOARD_USING_SENSOR0)
#include "ccap_sensor.h"
#define SENSOR0_RST_PIN NU_GET_PININDEX(NU_PM, 1)
#define SENSOR0_PD_PIN NU_GET_PININDEX(NU_PC, 12)
ccap_sensor_io sIo_sensor0 =
{
.RstPin = SENSOR0_RST_PIN,
.PwrDwnPin = SENSOR0_PD_PIN,
.I2cName = "i2c2"
};
#endif /* BOARD_USING_SENSOR0 */
int rt_hw_sensors_port(void)
{
#if defined(BOARD_USING_SENSOR0)
nu_ccap_sensor_create(&sIo_sensor0, (ccap_sensor_id)BOARD_USING_SENSON0_ID, "sensor0");
#endif
return 0;
}
INIT_COMPONENT_EXPORT(rt_hw_sensors_port);
void nu_rtp_sspcc_setup(void)
{
/* PDMA2/3 */
SSPCC_SET_REALM(SSPCC_PDMA2, SSPCC_SSET_SUBM);
SSPCC_SET_REALM(SSPCC_PDMA3, SSPCC_SSET_SUBM);
}
static S_NU_REG s_NuReg_arr[] =
{
/* QSPI0 */
NUREG_EXPORT(CLK_CLKSEL4, CLK_CLKSEL4_QSPI0SEL_Msk, CLK_CLKSEL4_QSPI0SEL_PCLK0),
NUREG_EXPORT(CLK_APBCLK1, CLK_APBCLK1_QSPI0CKEN_Msk, CLK_APBCLK1_QSPI0CKEN_Msk),
NUREG_EXPORT(SYS_GPD_MFPL, SYS_GPD_MFPL_PD5MFP_Msk, SYS_GPD_MFPL_PD5MFP_QSPI0_MISO1),
NUREG_EXPORT(SYS_GPD_MFPL, SYS_GPD_MFPL_PD4MFP_Msk, SYS_GPD_MFPL_PD4MFP_QSPI0_MOSI1),
NUREG_EXPORT(SYS_GPD_MFPL, SYS_GPD_MFPL_PD3MFP_Msk, SYS_GPD_MFPL_PD3MFP_QSPI0_MISO0),
NUREG_EXPORT(SYS_GPD_MFPL, SYS_GPD_MFPL_PD2MFP_Msk, SYS_GPD_MFPL_PD2MFP_QSPI0_MOSI0),
NUREG_EXPORT(SYS_GPD_MFPL, SYS_GPD_MFPL_PD1MFP_Msk, SYS_GPD_MFPL_PD1MFP_QSPI0_CLK),
NUREG_EXPORT(SYS_GPD_MFPL, SYS_GPD_MFPL_PD0MFP_Msk, SYS_GPD_MFPL_PD0MFP_QSPI0_SS0),
/* TIMERn */
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR0CKEN_Msk, CLK_APBCLK0_TMR0CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR1CKEN_Msk, CLK_APBCLK0_TMR1CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR2CKEN_Msk, CLK_APBCLK0_TMR2CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR3CKEN_Msk, CLK_APBCLK0_TMR3CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR4CKEN_Msk, CLK_APBCLK0_TMR4CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR5CKEN_Msk, CLK_APBCLK0_TMR5CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR6CKEN_Msk, CLK_APBCLK0_TMR6CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR7CKEN_Msk, CLK_APBCLK0_TMR7CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR8CKEN_Msk, CLK_APBCLK0_TMR8CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR9CKEN_Msk, CLK_APBCLK0_TMR9CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR10CKEN_Msk, CLK_APBCLK0_TMR10CKEN_Msk),
NUREG_EXPORT(CLK_APBCLK0, CLK_APBCLK0_TMR11CKEN_Msk, CLK_APBCLK0_TMR11CKEN_Msk),
{0}
};
void nu_check_register(void)
{
nu_sys_check_register(&s_NuReg_arr[0]);
}
MSH_CMD_EXPORT(nu_check_register, Check registers);
|
00ad78fbe7e675efb7d7cbbb75ace168bfc5b48f
|
ea8fc70c7dbf49059431fa45a940742736c68fb8
|
/ext/mvc/model/behaviorinterface.c
|
dd9e521db89a1ee2edc90e4cea7456e759e63b1d
|
[
"BSD-3-Clause"
] |
permissive
|
dreamsxin/cphalcon7
|
1bd2194a251657b48857326927db69fef617ab91
|
1b8c6b04b4ca237a5ead87d4752df0d2e85c7a9d
|
refs/heads/master
| 2023-03-08T04:53:08.829432
| 2022-07-07T07:48:59
| 2022-07-07T07:48:59
| 47,245,335
| 298
| 73
| null | 2021-06-22T11:53:25
| 2015-12-02T07:44:43
|
C
|
UTF-8
|
C
| false
| false
| 2,358
|
c
|
behaviorinterface.c
|
/*
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2014 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
| |
| If you did not receive a copy of the license and are unable to |
| obtain it through the world-wide-web, please send an email |
| to license@phalconphp.com so we can send you a copy immediately. |
+------------------------------------------------------------------------+
| Authors: Andres Gutierrez <andres@phalconphp.com> |
| Eduar Carvajal <eduar@phalconphp.com> |
+------------------------------------------------------------------------+
*/
#include "mvc/model/behaviorinterface.h"
#include "kernel/main.h"
zend_class_entry *phalcon_mvc_model_behaviorinterface_ce;
static const zend_function_entry phalcon_mvc_model_behaviorinterface_method_entry[] = {
PHP_ABSTRACT_ME(Phalcon_Mvc_Model_BehaviorInterface, notify, arginfo_phalcon_mvc_model_behaviorinterface_notify)
PHP_ABSTRACT_ME(Phalcon_Mvc_Model_BehaviorInterface, missingMethod, arginfo_phalcon_mvc_model_behaviorinterface_missingmethod)
PHP_FE_END
};
/**
* Phalcon\Mvc\Model\BehaviorInterface initializer
*/
PHALCON_INIT_CLASS(Phalcon_Mvc_Model_BehaviorInterface){
PHALCON_REGISTER_INTERFACE(Phalcon\\Mvc\\Model, BehaviorInterface, mvc_model_behaviorinterface, phalcon_mvc_model_behaviorinterface_method_entry);
return SUCCESS;
}
/**
* This method receives the notifications from the EventsManager
*
* @param string $type
* @param Phalcon\Mvc\ModelInterface $model
*/
PHALCON_DOC_METHOD(Phalcon_Mvc_Model_BehaviorInterface, notify);
/**
* Calls a method when it's missing in the model
*
* @param Phalcon\Mvc\ModelInterface $model
* @param string $method
* @param array $arguments
*/
PHALCON_DOC_METHOD(Phalcon_Mvc_Model_BehaviorInterface, missingMethod);
|
9aec912926d021db7b620c52f449b9db71d59122
|
7eaf54a78c9e2117247cb2ab6d3a0c20719ba700
|
/SOFTWARE/A64-TERES/linux-a64/drivers/gpu/drm/ast/ast_drv.h
|
5cfc1765af74859374b0dac747efe010bedf5799
|
[
"Linux-syscall-note",
"GPL-2.0-only",
"GPL-1.0-or-later",
"LicenseRef-scancode-free-unknown",
"Apache-2.0"
] |
permissive
|
OLIMEX/DIY-LAPTOP
|
ae82f4ee79c641d9aee444db9a75f3f6709afa92
|
a3fafd1309135650bab27f5eafc0c32bc3ca74ee
|
refs/heads/rel3
| 2023-08-04T01:54:19.483792
| 2023-04-03T07:18:12
| 2023-04-03T07:18:12
| 80,094,055
| 507
| 92
|
Apache-2.0
| 2023-04-03T07:05:59
| 2017-01-26T07:25:50
|
C
|
UTF-8
|
C
| false
| false
| 9,260
|
h
|
ast_drv.h
|
/*
* Copyright 2012 Red Hat 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, sub license, 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 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 NON-INFRINGEMENT. IN NO EVENT SHALL
* THE COPYRIGHT HOLDERS, AUTHORS AND/OR ITS SUPPLIERS 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.
*
* The above copyright notice and this permission notice (including the
* next paragraph) shall be included in all copies or substantial portions
* of the Software.
*
*/
/*
* Authors: Dave Airlie <airlied@redhat.com>
*/
#ifndef __AST_DRV_H__
#define __AST_DRV_H__
#include <drm/drm_fb_helper.h>
#include <drm/ttm/ttm_bo_api.h>
#include <drm/ttm/ttm_bo_driver.h>
#include <drm/ttm/ttm_placement.h>
#include <drm/ttm/ttm_memory.h>
#include <drm/ttm/ttm_module.h>
#include <linux/i2c.h>
#include <linux/i2c-algo-bit.h>
#define DRIVER_AUTHOR "Dave Airlie"
#define DRIVER_NAME "ast"
#define DRIVER_DESC "AST"
#define DRIVER_DATE "20120228"
#define DRIVER_MAJOR 0
#define DRIVER_MINOR 1
#define DRIVER_PATCHLEVEL 0
#define PCI_CHIP_AST2000 0x2000
#define PCI_CHIP_AST2100 0x2010
#define PCI_CHIP_AST1180 0x1180
enum ast_chip {
AST2000,
AST2100,
AST1100,
AST2200,
AST2150,
AST2300,
AST1180,
};
#define AST_DRAM_512Mx16 0
#define AST_DRAM_1Gx16 1
#define AST_DRAM_512Mx32 2
#define AST_DRAM_1Gx32 3
#define AST_DRAM_2Gx16 6
#define AST_DRAM_4Gx16 7
struct ast_fbdev;
struct ast_private {
struct drm_device *dev;
void __iomem *regs;
void __iomem *ioregs;
enum ast_chip chip;
bool vga2_clone;
uint32_t dram_bus_width;
uint32_t dram_type;
uint32_t mclk;
uint32_t vram_size;
struct ast_fbdev *fbdev;
int fb_mtrr;
struct {
struct drm_global_reference mem_global_ref;
struct ttm_bo_global_ref bo_global_ref;
struct ttm_bo_device bdev;
} ttm;
struct drm_gem_object *cursor_cache;
uint64_t cursor_cache_gpu_addr;
/* Acces to this cache is protected by the crtc->mutex of the only crtc
* we have. */
struct ttm_bo_kmap_obj cache_kmap;
int next_cursor;
};
int ast_driver_load(struct drm_device *dev, unsigned long flags);
int ast_driver_unload(struct drm_device *dev);
struct ast_gem_object;
#define AST_IO_AR_PORT_WRITE (0x40)
#define AST_IO_MISC_PORT_WRITE (0x42)
#define AST_IO_SEQ_PORT (0x44)
#define AST_DAC_INDEX_READ (0x3c7)
#define AST_IO_DAC_INDEX_WRITE (0x48)
#define AST_IO_DAC_DATA (0x49)
#define AST_IO_GR_PORT (0x4E)
#define AST_IO_CRTC_PORT (0x54)
#define AST_IO_INPUT_STATUS1_READ (0x5A)
#define AST_IO_MISC_PORT_READ (0x4C)
#define __ast_read(x) \
static inline u##x ast_read##x(struct ast_private *ast, u32 reg) { \
u##x val = 0;\
val = ioread##x(ast->regs + reg); \
return val;\
}
__ast_read(8);
__ast_read(16);
__ast_read(32)
#define __ast_io_read(x) \
static inline u##x ast_io_read##x(struct ast_private *ast, u32 reg) { \
u##x val = 0;\
val = ioread##x(ast->ioregs + reg); \
return val;\
}
__ast_io_read(8);
__ast_io_read(16);
__ast_io_read(32);
#define __ast_write(x) \
static inline void ast_write##x(struct ast_private *ast, u32 reg, u##x val) {\
iowrite##x(val, ast->regs + reg);\
}
__ast_write(8);
__ast_write(16);
__ast_write(32);
#define __ast_io_write(x) \
static inline void ast_io_write##x(struct ast_private *ast, u32 reg, u##x val) {\
iowrite##x(val, ast->ioregs + reg);\
}
__ast_io_write(8);
__ast_io_write(16);
#undef __ast_io_write
static inline void ast_set_index_reg(struct ast_private *ast,
uint32_t base, uint8_t index,
uint8_t val)
{
ast_io_write16(ast, base, ((u16)val << 8) | index);
}
void ast_set_index_reg_mask(struct ast_private *ast,
uint32_t base, uint8_t index,
uint8_t mask, uint8_t val);
uint8_t ast_get_index_reg(struct ast_private *ast,
uint32_t base, uint8_t index);
uint8_t ast_get_index_reg_mask(struct ast_private *ast,
uint32_t base, uint8_t index, uint8_t mask);
static inline void ast_open_key(struct ast_private *ast)
{
ast_set_index_reg(ast, AST_IO_CRTC_PORT, 0x80, 0xA8);
}
#define AST_VIDMEM_SIZE_8M 0x00800000
#define AST_VIDMEM_SIZE_16M 0x01000000
#define AST_VIDMEM_SIZE_32M 0x02000000
#define AST_VIDMEM_SIZE_64M 0x04000000
#define AST_VIDMEM_SIZE_128M 0x08000000
#define AST_VIDMEM_DEFAULT_SIZE AST_VIDMEM_SIZE_8M
#define AST_MAX_HWC_WIDTH 64
#define AST_MAX_HWC_HEIGHT 64
#define AST_HWC_SIZE (AST_MAX_HWC_WIDTH*AST_MAX_HWC_HEIGHT*2)
#define AST_HWC_SIGNATURE_SIZE 32
#define AST_DEFAULT_HWC_NUM 2
/* define for signature structure */
#define AST_HWC_SIGNATURE_CHECKSUM 0x00
#define AST_HWC_SIGNATURE_SizeX 0x04
#define AST_HWC_SIGNATURE_SizeY 0x08
#define AST_HWC_SIGNATURE_X 0x0C
#define AST_HWC_SIGNATURE_Y 0x10
#define AST_HWC_SIGNATURE_HOTSPOTX 0x14
#define AST_HWC_SIGNATURE_HOTSPOTY 0x18
struct ast_i2c_chan {
struct i2c_adapter adapter;
struct drm_device *dev;
struct i2c_algo_bit_data bit;
};
struct ast_connector {
struct drm_connector base;
struct ast_i2c_chan *i2c;
};
struct ast_crtc {
struct drm_crtc base;
u8 lut_r[256], lut_g[256], lut_b[256];
struct drm_gem_object *cursor_bo;
uint64_t cursor_addr;
int cursor_width, cursor_height;
u8 offset_x, offset_y;
};
struct ast_encoder {
struct drm_encoder base;
};
struct ast_framebuffer {
struct drm_framebuffer base;
struct drm_gem_object *obj;
};
struct ast_fbdev {
struct drm_fb_helper helper;
struct ast_framebuffer afb;
struct list_head fbdev_list;
void *sysram;
int size;
struct ttm_bo_kmap_obj mapping;
int x1, y1, x2, y2; /* dirty rect */
spinlock_t dirty_lock;
};
#define to_ast_crtc(x) container_of(x, struct ast_crtc, base)
#define to_ast_connector(x) container_of(x, struct ast_connector, base)
#define to_ast_encoder(x) container_of(x, struct ast_encoder, base)
#define to_ast_framebuffer(x) container_of(x, struct ast_framebuffer, base)
struct ast_vbios_stdtable {
u8 misc;
u8 seq[4];
u8 crtc[25];
u8 ar[20];
u8 gr[9];
};
struct ast_vbios_enhtable {
u32 ht;
u32 hde;
u32 hfp;
u32 hsync;
u32 vt;
u32 vde;
u32 vfp;
u32 vsync;
u32 dclk_index;
u32 flags;
u32 refresh_rate;
u32 refresh_rate_index;
u32 mode_id;
};
struct ast_vbios_dclk_info {
u8 param1;
u8 param2;
u8 param3;
};
struct ast_vbios_mode_info {
struct ast_vbios_stdtable *std_table;
struct ast_vbios_enhtable *enh_table;
};
extern int ast_mode_init(struct drm_device *dev);
extern void ast_mode_fini(struct drm_device *dev);
int ast_framebuffer_init(struct drm_device *dev,
struct ast_framebuffer *ast_fb,
struct drm_mode_fb_cmd2 *mode_cmd,
struct drm_gem_object *obj);
int ast_fbdev_init(struct drm_device *dev);
void ast_fbdev_fini(struct drm_device *dev);
void ast_fbdev_set_suspend(struct drm_device *dev, int state);
void ast_fbdev_set_base(struct ast_private *ast, unsigned long gpu_addr);
struct ast_bo {
struct ttm_buffer_object bo;
struct ttm_placement placement;
struct ttm_bo_kmap_obj kmap;
struct drm_gem_object gem;
u32 placements[3];
int pin_count;
};
#define gem_to_ast_bo(gobj) container_of((gobj), struct ast_bo, gem)
static inline struct ast_bo *
ast_bo(struct ttm_buffer_object *bo)
{
return container_of(bo, struct ast_bo, bo);
}
#define to_ast_obj(x) container_of(x, struct ast_gem_object, base)
#define AST_MM_ALIGN_SHIFT 4
#define AST_MM_ALIGN_MASK ((1 << AST_MM_ALIGN_SHIFT) - 1)
extern int ast_dumb_create(struct drm_file *file,
struct drm_device *dev,
struct drm_mode_create_dumb *args);
extern int ast_dumb_destroy(struct drm_file *file,
struct drm_device *dev,
uint32_t handle);
extern int ast_gem_init_object(struct drm_gem_object *obj);
extern void ast_gem_free_object(struct drm_gem_object *obj);
extern int ast_dumb_mmap_offset(struct drm_file *file,
struct drm_device *dev,
uint32_t handle,
uint64_t *offset);
#define DRM_FILE_PAGE_OFFSET (0x100000000ULL >> PAGE_SHIFT)
int ast_mm_init(struct ast_private *ast);
void ast_mm_fini(struct ast_private *ast);
int ast_bo_create(struct drm_device *dev, int size, int align,
uint32_t flags, struct ast_bo **pastbo);
int ast_gem_create(struct drm_device *dev,
u32 size, bool iskernel,
struct drm_gem_object **obj);
int ast_bo_pin(struct ast_bo *bo, u32 pl_flag, u64 *gpu_addr);
int ast_bo_unpin(struct ast_bo *bo);
int ast_bo_reserve(struct ast_bo *bo, bool no_wait);
void ast_bo_unreserve(struct ast_bo *bo);
void ast_ttm_placement(struct ast_bo *bo, int domain);
int ast_bo_push_sysram(struct ast_bo *bo);
int ast_mmap(struct file *filp, struct vm_area_struct *vma);
/* ast post */
void ast_post_gpu(struct drm_device *dev);
#endif
|
3d4261e57bd538339b01bbf211e126549f8ce8d4
|
bb38c44037a99d0a12a12d92059678f2faebbc80
|
/src/include/gs_threadlocal.h
|
40ae7851df9828e2e754fe16ed55e494b4344e40
|
[
"LicenseRef-scancode-mulanpsl-2.0-en",
"LicenseRef-scancode-unknown-license-reference",
"PostgreSQL",
"BSD-3-Clause",
"LGPL-2.0-or-later",
"LicenseRef-scancode-unicode",
"LicenseRef-scancode-warranty-disclaimer",
"curl",
"GPL-1.0-or-later",
"LGPL-2.1-or-later",
"LGPL-2.1-only",
"CC-BY-4.0",
"LicenseRef-scancode-protobuf",
"OpenSSL",
"LicenseRef-scancode-generic-export-compliance",
"X11-distribute-modifications-variant",
"LicenseRef-scancode-other-permissive",
"MIT",
"NCSA",
"Python-2.0",
"LicenseRef-scancode-openssl",
"LicenseRef-scancode-ssleay-windows",
"CC-BY-3.0",
"LicenseRef-scancode-other-copyleft",
"GPL-2.0-only",
"BSL-1.0",
"Apache-2.0",
"LGPL-2.0-only",
"LicenseRef-scancode-public-domain",
"BSD-2-Clause",
"Zlib"
] |
permissive
|
opengauss-mirror/openGauss-server
|
a9c5a62908643492347830826c56da49f0942796
|
310e84631c68c8bf37b004148b66f94064f701e4
|
refs/heads/master
| 2023-07-26T19:29:12.495484
| 2023-07-17T12:23:32
| 2023-07-17T12:23:32
| 276,117,477
| 591
| 208
|
MulanPSL-2.0
| 2023-04-28T12:30:18
| 2020-06-30T14:08:59
|
C++
|
UTF-8
|
C
| false
| false
| 703
|
h
|
gs_threadlocal.h
|
/* ---------------------------------------------------------------------------------------
*
* gs_threadlocal.h
*
* Portions Copyright (c) 2020 Huawei Technologies Co.,Ltd.
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
* src/include/gs_threadlocal.h
*
* ---------------------------------------------------------------------------------------
*/
#ifndef GS_THREADLOCAL_H_
#define GS_THREADLOCAL_H_
#ifdef PC_LINT
#define THR_LOCAL
#endif
#ifndef THR_LOCAL
#ifndef WIN32
#define THR_LOCAL __thread
#else
#define THR_LOCAL __declspec(thread)
#endif
#endif
#endif
|
e434988f75aa77b060cd338a854cbbedc5daff5d
|
88ae8695987ada722184307301e221e1ba3cc2fa
|
/native_client/src/nonsfi/irt/irt_random.c
|
7b378380ae0d9dd6da92dcb7c37ddc749a52e1f2
|
[
"BSD-3-Clause",
"Zlib",
"Classpath-exception-2.0",
"BSD-Source-Code",
"LZMA-exception",
"LicenseRef-scancode-unicode",
"LGPL-3.0-only",
"LGPL-2.0-or-later",
"LicenseRef-scancode-philippe-de-muyter",
"LicenseRef-scancode-warranty-disclaimer",
"LicenseRef-scancode-intel-osl-1993",
"HPND-sell-variant",
"ICU",
"LicenseRef-scancode-protobuf",
"bzip2-1.0.6",
"Spencer-94",
"NCSA",
"LicenseRef-scancode-nilsson-historical",
"CC0-1.0",
"LicenseRef-scancode-proprietary-license",
"LGPL-2.1-only",
"LicenseRef-scancode-other-copyleft",
"GPL-2.0-or-later",
"NTP",
"GPL-2.0-only",
"LicenseRef-scancode-other-permissive",
"GPL-3.0-only",
"GFDL-1.1-only",
"W3C",
"LicenseRef-scancode-python-cwi",
"GCC-exception-3.1",
"BSL-1.0",
"Python-2.0",
"GPL-1.0-or-later",
"LGPL-2.1-or-later",
"LicenseRef-scancode-unknown-license-reference",
"CPL-1.0",
"GFDL-1.1-or-later",
"W3C-19980720",
"LGPL-2.0-only",
"LicenseRef-scancode-amd-historical",
"LicenseRef-scancode-ietf",
"SAX-PD",
"LicenseRef-scancode-x11-hanson",
"LicenseRef-scancode-public-domain",
"BSD-2-Clause",
"dtoa",
"MIT",
"LicenseRef-scancode-public-domain-disclaimer",
"PSF-2.0",
"LicenseRef-scancode-newlib-historical",
"LicenseRef-scancode-generic-exception",
"SMLNJ",
"HP-1986",
"LicenseRef-scancode-free-unknown",
"SunPro",
"MPL-1.1"
] |
permissive
|
iridium-browser/iridium-browser
|
71d9c5ff76e014e6900b825f67389ab0ccd01329
|
5ee297f53dc7f8e70183031cff62f37b0f19d25f
|
refs/heads/master
| 2023-08-03T16:44:16.844552
| 2023-07-20T15:17:00
| 2023-07-23T16:09:30
| 220,016,632
| 341
| 40
|
BSD-3-Clause
| 2021-08-13T13:54:45
| 2019-11-06T14:32:31
| null |
UTF-8
|
C
| false
| false
| 1,127
|
c
|
irt_random.c
|
/*
* Copyright (c) 2014 The Native Client Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "native_client/src/public/nonsfi/irt_random.h"
#include "native_client/src/untrusted/nacl/nacl_random.h"
#include <errno.h>
#include <fcntl.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
static int g_urandom_fd = -1;
void nonsfi_set_urandom_fd(int fd) {
g_urandom_fd = fd;
}
/*
* Note: This library provides the nacl_secure_random_init for testing purposes.
*/
int nacl_secure_random_init(void) {
return 0; /* Success */
}
int nacl_secure_random(void *buf, size_t count, size_t *nread) {
if (g_urandom_fd < 0) {
/*
* If the fd for /dev/urandom is not initialized, try to open it.
* This happens on testing, or in nonsfi_loader. Abort on failure.
*/
g_urandom_fd = open("/dev/urandom", O_RDONLY);
if (g_urandom_fd < 0)
abort();
}
int result = read(g_urandom_fd, buf, count);
if (result < 0)
return errno;
*nread = result;
return 0;
}
|
d0afa9729da9faa52481373f3d5b4542b3c8e3dc
|
bece8b97cdb15988562c8c8dc27a5b58cd3acb90
|
/wizard_spider/Resources/TrickBot/Module64/Module64/Service.c
|
837982096dd333cb5b9a3a8c0fd590db888867ab
|
[
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer"
] |
permissive
|
center-for-threat-informed-defense/adversary_emulation_library
|
4382e78f56faa635d5a6cc89bce5b36f3b74476c
|
4b1d1327ebfbd550ba7e5f1b5562c1f3db61311e
|
refs/heads/master
| 2023-08-12T20:08:57.078612
| 2023-07-17T16:54:16
| 2023-07-17T16:54:16
| 259,753,257
| 1,220
| 243
|
Apache-2.0
| 2023-09-06T16:23:00
| 2020-04-28T21:16:54
|
C
|
UTF-8
|
C
| false
| false
| 2,709
|
c
|
Service.c
|
#include "Service.h"
/*
* InstallService:
* About:
* Creates new service used for persistence
* Artifacts:
* Writes to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Service
* after installing service
* Creates service with random name that will startup on system reboot
* Result:
* Returns 0 on success, -1 on error, -2 on insufficient privileges
*/
int InstallService() {
SC_HANDLE schSCManager;
SC_HANDLE schService;
SERVICE_DESCRIPTION sd;
// Open service manager, requires administrator or above privileges
//MessageBoxA(NULL, "in install service", "Reflective Dll Injection", MB_OK);
schSCManager = OpenSCManager(NULL, NULL, SC_MANAGER_ALL_ACCESS);
if (!schSCManager)
{
//if (GetLastError() == ERROR_ACCESS_DENIED)
//{
// //printf("Access was denied!\n");
//}
//MessageBoxA(NULL, "Access issue installed!", "Reflective Dll Injection", MB_OK);
return -2;
}
// Verify if service is already installed
// returns NULL if service does not exist
if (OpenService(schSCManager, SERVICE_NAME, SERVICE_QUERY_STATUS)) {
//printf("Already installed, skipping...\n");
//MessageBoxA(NULL, "already installed!", "Reflective Dll Injection", MB_OK);
return 0;
}
// Create service
schService = CreateService(schSCManager,
SERVICE_NAME,
SERVICE_NAME,
SERVICE_ALL_ACCESS,
SERVICE_WIN32_OWN_PROCESS,
SERVICE_AUTO_START,
SERVICE_ERROR_NORMAL,
SERVICE_PATH,
NULL,
NULL,
NULL,
NULL,
NULL);
if (!schService)
{
if (GetLastError() != ERROR_SERVICE_EXISTS)
{
//MessageBoxA(NULL, GetLastError(), "Reflective Dll Injection", MB_OK);
CloseServiceHandle(schSCManager);
return -1;
}
}
// Make sure service was created
schService = OpenService(schSCManager, SERVICE_NAME, GENERIC_ALL);
if (!schService)
{
CloseServiceHandle(schSCManager);
return -1;
}
// Change description of service through optional configuration
// Description from CTI
// src: https://unit42.paloaltonetworks.com/attack-chain-overview-emotet-in-december-2020-and-january-2021/
sd.lpDescription = (LPTSTR)TEXT("Windows Media Center Service for TV and FM broadcast reception");
if (!ChangeServiceConfig2(schService, SERVICE_CONFIG_DESCRIPTION, &sd))
{
//printf("Changing description of service failed.\n");
return -1;
}
CloseServiceHandle(schSCManager);
CloseServiceHandle(schService);
return 0;
}
|
8643f8621abfef3a3b5d9c56791ad24efa8721da
|
3bd385b466cb035fecd2b0c11ae054d42bf44fc2
|
/src/match/eis-sequencemultiread.h
|
d1b48205008dcd754d2cca197f7614a4f91d2604
|
[
"LicenseRef-scancode-unknown-license-reference",
"ISC",
"BSD-2-Clause",
"LicenseRef-scancode-mit-old-style",
"Zlib",
"MIT",
"BSD-3-Clause",
"bzip2-1.0.6"
] |
permissive
|
genometools/genometools
|
c366dff04f6baa887f6b3be3ec55bce824b2bae1
|
df1df94b8c05a9c9bf848ffc6755c87b58573da5
|
refs/heads/master
| 2023-04-13T13:57:18.748796
| 2023-04-09T21:29:53
| 2023-04-09T21:29:53
| 11,177,980
| 237
| 63
|
NOASSERTION
| 2023-04-09T21:29:54
| 2013-07-04T13:39:38
|
C
|
UTF-8
|
C
| false
| false
| 3,560
|
h
|
eis-sequencemultiread.h
|
/*
Copyright (C) 2007 Thomas Jahns <Thomas.Jahns@gmx.net>
Permission to use, copy, modify, and 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.
*/
#ifndef EIS_SEQUENCEMULTIREAD_H
#define EIS_SEQUENCEMULTIREAD_H
/**
* \file eis-sequencemultiread.h
* Keeps information about multiple synchronous reads of sequence
* data, where only one source and multiple consumers exist.
*/
#include "core/assert_api.h"
#include "core/minmax_api.h"
#include "match/eis-seqdatasrc.h"
/** every reader is identified by a unique scalar */
typedef unsigned consumerID;
/* moves data that can no longer be regenerated to the backlog */
typedef void (*move2BacklogFunc)(void *backlogState, const void *seqData,
GtUword requestStart, size_t requestLen);
/**
* basic idea: let this function write the required data to output
* and also call the move2Backlog callback if any data will be
* invalidated after this call and is still required by other consumers
* @return number of elements actually generated (might be short on eof etc.)
*/
typedef size_t (*generatorFunc)(void *generatorState, void *backlogState,
move2BacklogFunc move2Backlog, void *output,
GtUword generateStart, size_t len,
SeqDataTranslator xltor);
typedef struct seqReaderSet SeqReaderSet;
struct seqReaderSet
{
int numConsumers, numAutoConsumers;
int tagSuperSet;
struct seqReaderState *consumerList;
struct seqSinkState *autoConsumerList;
GtUword backlogStartPos;
bool fromSuffixsortspace;
size_t backlogSize, backlogLen, backlogElemSize;
void *seqDataBacklog, *generatorState;
generatorFunc generator;
};
/**
* @return numReaders if all consumers registered otherwise
*/
/*
int
gt_initSeqReaderSet(SeqReaderSet *readerSet, int initialSuperSet,
int numConsumers, int *tags, SeqDataTranslator xltors[],
SeqDataReader *generatedReaders, size_t seqElemSize,
generatorFunc generator, void *generatorState);
*/
void
gt_initEmptySeqReaderSet(SeqReaderSet *readerSet, int initialSuperSet,
bool fromSuffixsortspace,
size_t seqElemSize,
generatorFunc generator,
void *generatorState);
/**
* @return readData field will be NULL on error -> test with
* SDRIsValid */
SeqDataReader
gt_seqReaderSetRegisterConsumer(SeqReaderSet *readerSet, int tag,
SeqDataTranslator xltor);
/**
* @brief The registered writer will be called automatically for any
* data that is to be invalidated.
*
* @return false on error, true if successfully registered
*/
bool
gt_seqReaderSetRegisterAutoConsumer(SeqReaderSet *readerSet, int tag,
SeqDataWriter writer);
void
gt_destructSeqReaderSet(SeqReaderSet *readerSet);
#endif
|
964ebc7665ac3377b8315b3bed3d4115cb692fdc
|
99bdb3251fecee538e0630f15f6574054dfc1468
|
/components/net/sal/include/sal_socket.h
|
b77487516f0ca6f27d35a0e77889922011a03101
|
[
"Apache-2.0"
] |
permissive
|
RT-Thread/rt-thread
|
03a7c52c2aeb1b06a544143b0e803d72f47d1ece
|
3602f891211904a27dcbd51e5ba72fefce7326b2
|
refs/heads/master
| 2023-09-01T04:10:20.295801
| 2023-08-31T16:20:55
| 2023-08-31T16:20:55
| 7,408,108
| 9,599
| 5,805
|
Apache-2.0
| 2023-09-14T13:37:26
| 2013-01-02T14:49:21
|
C
|
UTF-8
|
C
| false
| false
| 9,322
|
h
|
sal_socket.h
|
/*
* Copyright (c) 2006-2021, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
* 2018-05-24 ChenYong First version
*/
#ifndef SAL_SOCKET_H__
#define SAL_SOCKET_H__
#include <stddef.h>
#include <arpa/inet.h>
#ifdef __cplusplus
extern "C" {
#endif
#if !defined(socklen_t) && !defined(SOCKLEN_T_DEFINED)
typedef uint32_t socklen_t;
#endif
#if !defined(sa_family_t) && !defined(SA_FAMILY_T_DEFINED)
typedef uint8_t sa_family_t;
#endif
/* If your port already typedef's in_port_t, define IN_PORT_T_DEFINED
to prevent this code from redefining it. */
#if !defined(in_port_t) && !defined(IN_PORT_T_DEFINED)
typedef uint16_t in_port_t;
#endif
/* Socket protocol types (TCP/UDP/RAW) */
#define SOCK_STREAM 1
#define SOCK_DGRAM 2
#define SOCK_RAW 3
#define SOCK_PACKET 10
#define SOCK_NONBLOCK 04000
#define SOCK_CLOEXEC 02000000
#define SOCK_MAX (SOCK_CLOEXEC + 1)
/* Option flags per-socket. These must match the SOF_ flags in ip.h (checked in init.c) */
#define SO_REUSEADDR 0x0004 /* Allow local address reuse */
#define SO_KEEPALIVE 0x0008 /* keep connections alive */
#define SO_BROADCAST 0x0020 /* permit to send and to receive broadcast messages (see IP_SOF_BROADCAST option) */
/* Additional options, not kept in so_options */
#define SO_DEBUG 0x0001 /* Unimplemented: turn on debugging info recording */
#define SO_ACCEPTCONN 0x0002 /* socket has had listen() */
#define SO_DONTROUTE 0x0010 /* Unimplemented: just use interface addresses */
#define SO_USELOOPBACK 0x0040 /* Unimplemented: bypass hardware when possible */
#define SO_LINGER 0x0080 /* linger on close if data present */
#define SO_DONTLINGER ((int)(~SO_LINGER))
#define SO_OOBINLINE 0x0100 /* Unimplemented: leave received OOB data in line */
#define SO_REUSEPORT 0x0200 /* Unimplemented: allow local address & port reuse */
#define SO_SNDBUF 0x1001 /* Unimplemented: send buffer size */
#define SO_RCVBUF 0x1002 /* receive buffer size */
#define SO_SNDLOWAT 0x1003 /* Unimplemented: send low-water mark */
#define SO_RCVLOWAT 0x1004 /* Unimplemented: receive low-water mark */
#define SO_SNDTIMEO 0x1005 /* send timeout */
#define SO_RCVTIMEO 0x1006 /* receive timeout */
#define SO_ERROR 0x1007 /* get error status and clear */
#define SO_TYPE 0x1008 /* get socket type */
#define SO_CONTIMEO 0x1009 /* Unimplemented: connect timeout */
#define SO_NO_CHECK 0x100a /* don't create UDP checksum */
/* Level number for (get/set)sockopt() to apply to socket itself */
#define SOL_SOCKET 0xfff /* options for socket level */
#define AF_UNSPEC 0
#define AF_UNIX 1
#define AF_INET 2
#define AF_INET6 10
#define AF_CAN 29 /* Controller Area Network */
#define AF_AT 45 /* AT socket */
#define AF_WIZ 46 /* WIZnet socket */
#define PF_UNIX AF_UNIX
#define PF_INET AF_INET
#define PF_INET6 AF_INET6
#define PF_UNSPEC AF_UNSPEC
#define PF_CAN AF_CAN
#define PF_AT AF_AT
#define PF_WIZ AF_WIZ
#define AF_MAX (AF_WIZ + 1) /* For now.. */
#define IPPROTO_IP 0
#define IPPROTO_ICMP 1
#define IPPROTO_TCP 6
#define IPPROTO_UDP 17
#define IPPROTO_IPV6 41
#define IPPROTO_ICMPV6 58
#define IPPROTO_UDPLITE 136
#define IPPROTO_RAW 255
/* Flags we can use with send and recv */
#define MSG_PEEK 0x01 /* Peeks at an incoming message */
#define MSG_WAITALL 0x02 /* Unimplemented: Requests that the function block until the full amount of data requested can be returned */
#define MSG_OOB 0x04 /* Unimplemented: Requests out-of-band data. The significance and semantics of out-of-band data are protocol-specific */
#define MSG_DONTWAIT 0x08 /* Nonblocking i/o for this operation only */
#define MSG_MORE 0x10 /* Sender will send more */
/* Options for level IPPROTO_IP */
#define IP_TOS 1
#define IP_TTL 2
/* Options for level IPPROTO_TCP */
#define TCP_NODELAY 0x01 /* don't delay send to coalesce packets */
#define TCP_KEEPALIVE 0x02 /* send KEEPALIVE probes when idle for pcb->keep_idle milliseconds */
#define TCP_KEEPIDLE 0x03 /* set pcb->keep_idle - Same as TCP_KEEPALIVE, but use seconds for get/setsockopt */
#define TCP_KEEPINTVL 0x04 /* set pcb->keep_intvl - Use seconds for get/setsockopt */
#define TCP_KEEPCNT 0x05 /* set pcb->keep_cnt - Use number of probes sent for get/setsockopt */
/* Options and types related to multicast membership */
#define IP_ADD_MEMBERSHIP 3
#define IP_DROP_MEMBERSHIP 4
/* Options and types for UDP multicast traffic handling */
#define IP_MULTICAST_TTL 5
#define IP_MULTICAST_IF 6
#define IP_MULTICAST_LOOP 7
typedef struct ip_mreq
{
struct in_addr imr_multiaddr; /* IP multicast address of group */
struct in_addr imr_interface; /* local IP address of interface */
} ip_mreq;
/* The Type of Service provides an indication of the abstract parameters of the quality of service desired */
#define IPTOS_TOS_MASK 0x1E
#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK)
#define IPTOS_LOWDELAY 0x10
#define IPTOS_THROUGHPUT 0x08
#define IPTOS_RELIABILITY 0x04
#define IPTOS_LOWCOST 0x02
#define IPTOS_MINCOST IPTOS_LOWCOST
/* The Network Control precedence designation is intended to be used within a network only */
#define IPTOS_PREC_MASK 0xe0
#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK)
#define IPTOS_PREC_NETCONTROL 0xe0
#define IPTOS_PREC_INTERNETCONTROL 0xc0
#define IPTOS_PREC_CRITIC_ECP 0xa0
#define IPTOS_PREC_FLASHOVERRIDE 0x80
#define IPTOS_PREC_FLASH 0x60
#define IPTOS_PREC_IMMEDIATE 0x40
#define IPTOS_PREC_PRIORITY 0x20
#define IPTOS_PREC_ROUTINE 0x00
/* Options for shatdown type */
#ifndef SHUT_RD
#define SHUT_RD 0
#define SHUT_WR 1
#define SHUT_RDWR 2
#endif
struct sockaddr
{
uint8_t sa_len;
sa_family_t sa_family;
char sa_data[14];
};
/* Structure describing the address of an AF_LOCAL (aka AF_UNIX) socket. */
struct sockaddr_un
{
uint8_t sa_len;
sa_family_t sa_family;
char sun_path[108]; /* Path name. */
};
#if NETDEV_IPV4
/* members are in network byte order */
struct sockaddr_in
{
uint8_t sin_len;
sa_family_t sin_family;
in_port_t sin_port;
struct in_addr sin_addr;
#define SIN_ZERO_LEN 8
char sin_zero[SIN_ZERO_LEN];
};
#endif /* NETDEV_IPV4 */
#if NETDEV_IPV6
struct sockaddr_in6
{
uint8_t sin6_len; /* length of this structure */
sa_family_t sin6_family; /* AF_INET6 */
in_port_t sin6_port; /* Transport layer port # */
uint32_t sin6_flowinfo; /* IPv6 flow information */
struct in6_addr sin6_addr; /* IPv6 address */
uint32_t sin6_scope_id; /* Set of interfaces for scope */
};
#endif /* NETDEV_IPV6 */
struct sockaddr_storage
{
uint8_t s2_len;
sa_family_t ss_family;
char s2_data1[2];
uint32_t s2_data2[3];
#if NETDEV_IPV6
uint32_t s2_data3[3];
#endif /* NETDEV_IPV6 */
};
#define IFNAMSIZ 16
struct sal_ifmap
{
unsigned long int mem_start;
unsigned long int mem_end;
unsigned short int base_addr;
unsigned char irq;
unsigned char dma;
unsigned char port;
};
struct sal_ifreq
{
union
{
char ifrn_name[IFNAMSIZ];
} ifr_ifrn;
union
{
struct sockaddr ifru_addr;
struct sockaddr ifru_dstaddr;
struct sockaddr ifru_broadaddr;
struct sockaddr ifru_netmask;
struct sockaddr ifru_hwaddr;
short int ifru_flags;
int ifru_ivalue;
int ifru_mtu;
struct sal_ifmap ifru_map;
char ifru_slave[IFNAMSIZ];
char ifru_newname[IFNAMSIZ];
char *ifru_data;
} ifr_ifru;
};
int sal_accept(int socket, struct sockaddr *addr, socklen_t *addrlen);
int sal_bind(int socket, const struct sockaddr *name, socklen_t namelen);
int sal_shutdown(int socket, int how);
int sal_getpeername (int socket, struct sockaddr *name, socklen_t *namelen);
int sal_getsockname (int socket, struct sockaddr *name, socklen_t *namelen);
int sal_getsockopt (int socket, int level, int optname, void *optval, socklen_t *optlen);
int sal_setsockopt (int socket, int level, int optname, const void *optval, socklen_t optlen);
int sal_connect(int socket, const struct sockaddr *name, socklen_t namelen);
int sal_listen(int socket, int backlog);
int sal_recvfrom(int socket, void *mem, size_t len, int flags,
struct sockaddr *from, socklen_t *fromlen);
int sal_sendto(int socket, const void *dataptr, size_t size, int flags,
const struct sockaddr *to, socklen_t tolen);
int sal_socket(int domain, int type, int protocol);
int sal_closesocket(int socket);
int sal_ioctlsocket(int socket, long cmd, void *arg);
#ifdef __cplusplus
}
#endif
#endif /* SAL_SOCKET_H__ */
|
3c2a4b81cfc7fa293e10120633465715b3650010
|
5ab69c8644a936a3d9dec1669a86c7369c911bf8
|
/os/net/routing/rpl-lite/rpl-dag.c
|
3d928283b0b885ad0fdb487eb7fae4fd3206221f
|
[
"BSD-3-Clause"
] |
permissive
|
contiki-ng/contiki-ng
|
393d36f68b98f5ee3544ea32502cf662ffb2fe9f
|
31fcaadf7a0dc8ceea07f438cd69db73174879e6
|
refs/heads/develop
| 2023-09-01T20:10:30.000765
| 2023-09-01T14:37:12
| 2023-09-01T14:37:12
| 91,191,972
| 1,242
| 788
|
BSD-3-Clause
| 2023-09-14T19:08:35
| 2017-05-13T17:37:59
|
C
|
UTF-8
|
C
| false
| false
| 26,752
|
c
|
rpl-dag.c
|
/*
* Copyright (c) 2010, Swedish Institute of Computer Science.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. 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.
* 3. Neither the name of the Institute 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 INSTITUTE 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 INSTITUTE 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 file is part of the Contiki operating system.
*
*/
/**
* \addtogroup rpl-lite
* @{
*
* \file
* Logic for Directed Acyclic Graphs in RPL.
*
* \author Joakim Eriksson <joakime@sics.se>, Nicolas Tsiftes <nvt@sics.se>,
* Simon Duquennoy <simon.duquennoy@inria.fr>
* Contributors: George Oikonomou <oikonomou@users.sourceforge.net> (multicast)
*/
#include "net/routing/rpl-lite/rpl.h"
#include "net/ipv6/uip-sr.h"
#include "net/nbr-table.h"
#include "net/link-stats.h"
/* Log configuration */
#include "sys/log.h"
#define LOG_MODULE "RPL"
#define LOG_LEVEL LOG_LEVEL_RPL
/*---------------------------------------------------------------------------*/
extern rpl_of_t rpl_of0, rpl_mrhof;
static rpl_of_t * const objective_functions[] = RPL_SUPPORTED_OFS;
static int process_dio_init_dag(rpl_dio_t *dio);
/*---------------------------------------------------------------------------*/
/* Allocate instance table. */
rpl_instance_t curr_instance;
/*---------------------------------------------------------------------------*/
#ifdef RPL_VALIDATE_DIO_FUNC
int RPL_VALIDATE_DIO_FUNC(rpl_dio_t *dio);
#endif /* RPL_PROBING_SELECT_FUNC */
/*---------------------------------------------------------------------------*/
const char *
rpl_dag_state_to_str(enum rpl_dag_state state)
{
switch(state) {
case DAG_INITIALIZED:
return "initialized";
case DAG_JOINED:
return "joined";
case DAG_REACHABLE:
return "reachable";
case DAG_POISONING:
return "poisoning";
default:
return "unknown";
}
}
/*---------------------------------------------------------------------------*/
int
rpl_dag_get_root_ipaddr(uip_ipaddr_t *ipaddr)
{
if(curr_instance.used && ipaddr != NULL) {
uip_ipaddr_copy(ipaddr, &curr_instance.dag.dag_id);
return 1;
}
return 0;
}
/*---------------------------------------------------------------------------*/
void
rpl_dag_leave(void)
{
LOG_INFO("leaving DAG ");
LOG_INFO_6ADDR(&curr_instance.dag.dag_id);
LOG_INFO_(", instance %u\n", curr_instance.instance_id);
/* Issue a no-path DAO */
if(!rpl_dag_root_is_root()) {
RPL_LOLLIPOP_INCREMENT(curr_instance.dag.dao_last_seqno);
rpl_icmp6_dao_output(0);
}
/* Forget past link statistics */
link_stats_reset();
/* Remove all neighbors, links and default route */
rpl_neighbor_remove_all();
uip_sr_free_all();
/* Stop all timers */
rpl_timers_stop_dag_timers();
/* Remove autoconfigured address */
if((curr_instance.dag.prefix_info.flags & UIP_ND6_RA_FLAG_AUTONOMOUS)) {
rpl_reset_prefix(&curr_instance.dag.prefix_info);
}
/* Mark instance as unused */
curr_instance.used = 0;
}
/*---------------------------------------------------------------------------*/
void
rpl_dag_poison_and_leave(void)
{
curr_instance.dag.state = DAG_POISONING;
rpl_timers_schedule_state_update();
}
/*---------------------------------------------------------------------------*/
void
rpl_dag_periodic(unsigned seconds)
{
if(curr_instance.used) {
if(curr_instance.dag.lifetime != RPL_LIFETIME(RPL_INFINITE_LIFETIME)) {
curr_instance.dag.lifetime =
curr_instance.dag.lifetime > seconds ? curr_instance.dag.lifetime - seconds : 0;
if(curr_instance.dag.lifetime == 0) {
LOG_WARN("DAG expired, poison and leave\n");
curr_instance.dag.state = DAG_POISONING;
rpl_timers_schedule_state_update();
} else if(curr_instance.dag.lifetime < 300 && curr_instance.dag.preferred_parent != NULL) {
/* Five minutes before expiring, start sending unicast DIS to get an update */
LOG_WARN("DAG expiring in %u seconds, send DIS to preferred parent\n", (unsigned)curr_instance.dag.lifetime);
rpl_icmp6_dis_output(rpl_neighbor_get_ipaddr(curr_instance.dag.preferred_parent));
}
}
}
}
/*---------------------------------------------------------------------------*/
int
rpl_is_addr_in_our_dag(const uip_ipaddr_t *addr)
{
return curr_instance.used
&& uip_ipaddr_prefixcmp(&curr_instance.dag.dag_id, addr, curr_instance.dag.prefix_info.length);
}
/*---------------------------------------------------------------------------*/
rpl_instance_t *
rpl_get_default_instance(void)
{
return curr_instance.used ? &curr_instance : NULL;
}
/*---------------------------------------------------------------------------*/
rpl_dag_t *
rpl_get_any_dag(void)
{
return curr_instance.used ? &curr_instance.dag : NULL;
}
/*---------------------------------------------------------------------------*/
static rpl_of_t *
find_objective_function(rpl_ocp_t ocp)
{
unsigned int i;
for(i = 0; i < sizeof(objective_functions) / sizeof(objective_functions[0]); i++) {
if(objective_functions[i]->ocp == ocp) {
return objective_functions[i];
}
}
return NULL;
}
/*---------------------------------------------------------------------------*/
void
rpl_refresh_routes(const char *str)
{
if(rpl_dag_root_is_root()) {
/* Increment DTSN */
RPL_LOLLIPOP_INCREMENT(curr_instance.dtsn_out);
LOG_WARN("incremented DTSN (%s), current %u\n",
str, curr_instance.dtsn_out);
if(LOG_INFO_ENABLED) {
rpl_neighbor_print_list("Refresh routes (before)");
}
}
}
/*---------------------------------------------------------------------------*/
void
rpl_global_repair(const char *str)
{
if(rpl_dag_root_is_root()) {
RPL_LOLLIPOP_INCREMENT(curr_instance.dag.version); /* New DAG version */
curr_instance.dtsn_out = RPL_LOLLIPOP_INIT; /* Re-initialize DTSN */
LOG_WARN("initiating global repair (%s), version %u, rank %u\n",
str, curr_instance.dag.version, curr_instance.dag.rank);
if(LOG_INFO_ENABLED) {
rpl_neighbor_print_list("Global repair (before)");
}
/* Now do a local repair to disseminate the new version */
rpl_local_repair("Global repair");
}
}
/*---------------------------------------------------------------------------*/
static void
global_repair_non_root(rpl_dio_t *dio)
{
if(!rpl_dag_root_is_root()) {
LOG_WARN("participating in global repair, version %u, rank %u\n",
dio->version, curr_instance.dag.rank);
if(LOG_INFO_ENABLED) {
rpl_neighbor_print_list("Global repair (before)");
}
/* Re-initialize configuration from DIO */
rpl_timers_stop_dag_timers();
rpl_neighbor_set_preferred_parent(NULL);
/* This will both re-init the DAG and schedule required timers */
process_dio_init_dag(dio);
rpl_local_repair("Global repair");
}
}
/*---------------------------------------------------------------------------*/
void
rpl_local_repair(const char *str)
{
if(curr_instance.used) { /* Check needed because this is a public function */
LOG_WARN("local repair (%s)\n", str);
if(!rpl_dag_root_is_root()) {
curr_instance.dag.state = DAG_INITIALIZED; /* Reset DAG state */
}
curr_instance.of->reset(); /* Reset OF */
rpl_neighbor_remove_all(); /* Remove all neighbors */
rpl_timers_dio_reset("Local repair"); /* Reset Trickle timer */
rpl_timers_schedule_state_update();
}
}
/*---------------------------------------------------------------------------*/
int
rpl_dag_ready_to_advertise(void)
{
if(curr_instance.mop == RPL_MOP_NO_DOWNWARD_ROUTES) {
return curr_instance.used && curr_instance.dag.state >= DAG_INITIALIZED;
} else {
return curr_instance.used && curr_instance.dag.state >= DAG_REACHABLE;
}
}
/*---------------------------------------------------------------------------*/
/* Updates rank and parent */
void
rpl_dag_update_state(void)
{
rpl_rank_t old_rank;
if(!curr_instance.used) {
return;
}
old_rank = curr_instance.dag.rank;
/* Any scheduled state update is no longer needed */
rpl_timers_unschedule_state_update();
if(curr_instance.dag.state == DAG_POISONING) {
rpl_neighbor_set_preferred_parent(NULL);
curr_instance.dag.rank = RPL_INFINITE_RANK;
if(old_rank != RPL_INFINITE_RANK) {
/* Advertise that we are leaving, and leave after a delay */
LOG_WARN("poisoning and leaving after a delay\n");
rpl_timers_dio_reset("Poison routes");
rpl_timers_schedule_leaving();
}
} else if(!rpl_dag_root_is_root()) {
rpl_nbr_t *old_parent = curr_instance.dag.preferred_parent;
rpl_nbr_t *nbr;
/* Select and set preferred parent */
rpl_neighbor_set_preferred_parent(rpl_neighbor_select_best());
/* Update rank */
curr_instance.dag.rank = rpl_neighbor_rank_via_nbr(curr_instance.dag.preferred_parent);
/* Update better_parent_since flag for each neighbor */
nbr = nbr_table_head(rpl_neighbors);
while(nbr != NULL) {
if(rpl_neighbor_rank_via_nbr(nbr) < curr_instance.dag.rank) {
/* This neighbor would be a better parent than our current.
Set 'better_parent_since' if not already set. */
if(nbr->better_parent_since == 0) {
nbr->better_parent_since = clock_time(); /* Initialize */
}
} else {
nbr->better_parent_since = 0; /* Not a better parent */
}
nbr = nbr_table_next(rpl_neighbors, nbr);
}
if(old_parent == NULL || curr_instance.dag.rank < curr_instance.dag.lowest_rank) {
/* This is a slight departure from RFC6550: if we had no preferred parent before,
* reset lowest_rank. This helps recovering from temporary bad link conditions. */
curr_instance.dag.lowest_rank = curr_instance.dag.rank;
}
/* Reset DIO timer in case of significant rank update */
if(curr_instance.dag.last_advertised_rank != RPL_INFINITE_RANK
&& curr_instance.dag.rank != RPL_INFINITE_RANK
&& ABS((int32_t)curr_instance.dag.rank - curr_instance.dag.last_advertised_rank) > RPL_SIGNIFICANT_CHANGE_THRESHOLD) {
LOG_WARN("significant rank update %u->%u\n",
curr_instance.dag.last_advertised_rank, curr_instance.dag.rank);
/* Update already here to avoid multiple resets in a row */
curr_instance.dag.last_advertised_rank = curr_instance.dag.rank;
rpl_timers_dio_reset("Significant rank update");
}
/* Parent switch */
if(curr_instance.dag.unprocessed_parent_switch) {
if(curr_instance.dag.preferred_parent != NULL) {
/* We just got a parent (was NULL), reset trickle timer to advertise this */
if(old_parent == NULL) {
curr_instance.dag.state = DAG_JOINED;
rpl_timers_dio_reset("Got parent");
LOG_WARN("found parent: ");
LOG_WARN_6ADDR(rpl_neighbor_get_ipaddr(curr_instance.dag.preferred_parent));
LOG_WARN_(", staying in DAG\n");
rpl_timers_unschedule_leaving();
}
/* Schedule a DAO */
rpl_timers_schedule_dao();
} else {
/* We have no more parent, schedule DIS to get a chance to hear updated state */
curr_instance.dag.state = DAG_INITIALIZED;
LOG_WARN("no parent, scheduling periodic DIS, will leave if no parent is found\n");
rpl_timers_dio_reset("Poison routes");
rpl_timers_schedule_periodic_dis();
rpl_timers_schedule_leaving();
}
if(LOG_INFO_ENABLED) {
rpl_neighbor_print_list("Parent switch");
}
/* Clear unprocessed_parent_switch now that we have processed it */
curr_instance.dag.unprocessed_parent_switch = false;
}
}
/* Finally, update metric container */
curr_instance.of->update_metric_container();
}
/*---------------------------------------------------------------------------*/
static rpl_nbr_t *
update_nbr_from_dio(uip_ipaddr_t *from, rpl_dio_t *dio)
{
rpl_nbr_t *nbr = NULL;
const uip_lladdr_t *lladdr;
nbr = rpl_neighbor_get_from_ipaddr(from);
/* Neighbor not in RPL neighbor table, add it */
if(nbr == NULL) {
/* Is the neighbor known by ds6? Drop this request if not.
* Typically, the neighbor is added upon receiving a DIO. */
lladdr = uip_ds6_nbr_lladdr_from_ipaddr(from);
if(lladdr == NULL) {
return NULL;
}
/* Add neighbor to RPL table */
nbr = nbr_table_add_lladdr(rpl_neighbors, (linkaddr_t *)lladdr,
NBR_TABLE_REASON_RPL_DIO, dio);
if(nbr == NULL) {
LOG_ERR("failed to add neighbor\n");
return NULL;
}
}
/* Update neighbor info from DIO */
nbr->rank = dio->rank;
nbr->dtsn = dio->dtsn;
#if RPL_WITH_MC
memcpy(&nbr->mc, &dio->mc, sizeof(nbr->mc));
#endif /* RPL_WITH_MC */
return nbr;
}
/*---------------------------------------------------------------------------*/
static void
process_dio_from_current_dag(uip_ipaddr_t *from, rpl_dio_t *dio)
{
rpl_nbr_t *nbr;
uint8_t last_dtsn;
/* Does the rank make sense at all? */
if(dio->rank < ROOT_RANK) {
return;
}
/* If the DIO sender is on an older version of the DAG, do not process it
* further. The sender will eventually hear the global repair and catch up. */
if(rpl_lollipop_greater_than(curr_instance.dag.version, dio->version)) {
if(dio->rank == ROOT_RANK) {
/* Before returning, if the DIO was from the root, an old DAG versions
* likely incidates a root reboot. Reset our DIO timer to make sure the
* root hears our version ASAP, and in turn triggers a global repair. */
rpl_timers_dio_reset("Heard old version from root");
}
return;
}
/* The DIO is valid, proceed further */
/* Update DIO counter for redundancy mngt */
if(dio->rank != RPL_INFINITE_RANK) {
curr_instance.dag.dio_counter++;
}
/* The DIO has a newer version: global repair.
* Must come first, as it might remove all neighbors, and we then need
* to re-add this source of the DIO to the neighbor table */
if(rpl_lollipop_greater_than(dio->version, curr_instance.dag.version)) {
if(curr_instance.dag.rank == ROOT_RANK) {
/* The root should not hear newer versions unless it just rebooted */
LOG_ERR("inconsistent DIO version (current: %u, received: %u), initiate global repair\n",
curr_instance.dag.version, dio->version);
/* Update version and trigger global repair */
curr_instance.dag.version = dio->version;
rpl_global_repair("Inconsistent DIO version");
} else {
LOG_WARN("new DIO version (current: %u, received: %u), apply global repair\n",
curr_instance.dag.version, dio->version);
global_repair_non_root(dio);
}
}
/* Update IPv6 neighbor cache */
if(!rpl_icmp6_update_nbr_table(from, NBR_TABLE_REASON_RPL_DIO, dio)) {
LOG_ERR("IPv6 cache full, dropping DIO\n");
return;
}
nbr = rpl_neighbor_get_from_ipaddr(from);
last_dtsn = nbr != NULL ? nbr->dtsn : RPL_LOLLIPOP_INIT;
/* Add neighbor to RPL neighbor table */
if(!update_nbr_from_dio(from, dio)) {
LOG_ERR("neighbor table full, dropping DIO\n");
return;
}
/* Init lifetime if not set yet. Refresh it at every DIO from preferred parent. */
if(curr_instance.dag.lifetime == 0 ||
(nbr != NULL && nbr == curr_instance.dag.preferred_parent)) {
LOG_INFO("refreshing lifetime\n");
curr_instance.dag.lifetime = RPL_LIFETIME(RPL_DAG_LIFETIME);
}
/* If the source is our preferred parent and it increased DTSN, we increment
* our DTSN in turn and schedule a DAO (see RFC6550 section 9.6.) */
if(curr_instance.mop != RPL_MOP_NO_DOWNWARD_ROUTES) {
if(nbr != NULL && nbr == curr_instance.dag.preferred_parent && rpl_lollipop_greater_than(dio->dtsn, last_dtsn)) {
RPL_LOLLIPOP_INCREMENT(curr_instance.dtsn_out);
LOG_WARN("DTSN increment %u->%u, schedule new DAO with DTSN %u\n",
last_dtsn, dio->dtsn, curr_instance.dtsn_out);
rpl_timers_schedule_dao();
}
}
}
/*---------------------------------------------------------------------------*/
static int
init_dag(uint8_t instance_id, uip_ipaddr_t *dag_id, rpl_ocp_t ocp,
uip_ipaddr_t *prefix, unsigned prefix_len, uint8_t prefix_flags)
{
rpl_of_t *of;
memset(&curr_instance, 0, sizeof(curr_instance));
/* OF */
of = find_objective_function(ocp);
if(of == NULL) {
LOG_ERR("ignoring DIO with an unsupported OF: %u\n", ocp);
return 0;
}
/* Prefix */
if(!rpl_set_prefix_from_addr(prefix, prefix_len, prefix_flags)) {
LOG_ERR("failed to set prefix\n");
return 0;
}
/* Instnace */
curr_instance.instance_id = instance_id;
curr_instance.of = of;
curr_instance.dtsn_out = RPL_LOLLIPOP_INIT;
curr_instance.used = 1;
/* DAG */
curr_instance.dag.rank = RPL_INFINITE_RANK;
curr_instance.dag.last_advertised_rank = RPL_INFINITE_RANK;
curr_instance.dag.lowest_rank = RPL_INFINITE_RANK;
curr_instance.dag.dao_last_seqno = RPL_LOLLIPOP_INIT;
curr_instance.dag.dao_last_acked_seqno = RPL_LOLLIPOP_INIT;
curr_instance.dag.dao_last_seqno = RPL_LOLLIPOP_INIT;
memcpy(&curr_instance.dag.dag_id, dag_id, sizeof(curr_instance.dag.dag_id));
return 1;
}
/*---------------------------------------------------------------------------*/
static int
init_dag_from_dio(rpl_dio_t *dio)
{
if(!init_dag(dio->instance_id, &dio->dag_id, dio->ocp,
&dio->prefix_info.prefix, dio->prefix_info.length, dio->prefix_info.flags)) {
return 0;
}
/* Instnace */
curr_instance.mop = dio->mop;
curr_instance.mc.type = dio->mc.type;
curr_instance.mc.flags = dio->mc.flags;
curr_instance.mc.aggr = dio->mc.aggr;
curr_instance.mc.prec = dio->mc.prec;
curr_instance.max_rankinc = dio->dag_max_rankinc;
curr_instance.min_hoprankinc = dio->dag_min_hoprankinc;
curr_instance.dio_intdoubl = dio->dag_intdoubl;
curr_instance.dio_intmin = dio->dag_intmin;
curr_instance.dio_redundancy = dio->dag_redund;
curr_instance.default_lifetime = dio->default_lifetime;
curr_instance.lifetime_unit = dio->lifetime_unit;
/* DAG */
curr_instance.dag.state = DAG_INITIALIZED;
curr_instance.dag.preference = dio->preference;
curr_instance.dag.grounded = dio->grounded;
curr_instance.dag.version = dio->version;
/* dio_intcurrent will be reset by rpl_timers_dio_reset() */
curr_instance.dag.dio_intcurrent = 0;
return 1;
}
/*---------------------------------------------------------------------------*/
static int
process_dio_init_dag(rpl_dio_t *dio)
{
#ifdef RPL_VALIDATE_DIO_FUNC
if(!RPL_VALIDATE_DIO_FUNC(dio)) {
LOG_WARN("DIO validation failed\n");
return 0;
}
#endif
/* Check MOP */
if(dio->mop != RPL_MOP_NO_DOWNWARD_ROUTES && dio->mop != RPL_MOP_NON_STORING) {
LOG_WARN("ignoring DIO with an unsupported MOP: %d\n", dio->mop);
return 0;
}
/* Initialize instance and DAG data structures */
if(!init_dag_from_dio(dio)) {
LOG_WARN("failed to initialize DAG\n");
return 0;
}
/* Init OF and timers */
curr_instance.of->reset();
rpl_timers_dio_reset("Join");
#if RPL_WITH_PROBING
rpl_schedule_probing();
#endif /* RPL_WITH_PROBING */
/* Leave the network after RPL_DELAY_BEFORE_LEAVING in case we do not
find a parent */
LOG_INFO("initialized DAG with instance ID %u, DAG ID ",
curr_instance.instance_id);
LOG_INFO_6ADDR(&curr_instance.dag.dag_id);
LOG_INFO_(", prexix ");
LOG_INFO_6ADDR(&dio->prefix_info.prefix);
LOG_INFO_("/%u, rank %u\n", dio->prefix_info.length, curr_instance.dag.rank);
LOG_ANNOTATE("#A init=%u\n", curr_instance.dag.dag_id.u8[sizeof(curr_instance.dag.dag_id) - 1]);
LOG_WARN("just joined, no parent yet, setting timer for leaving\n");
rpl_timers_schedule_leaving();
return 1;
}
/*---------------------------------------------------------------------------*/
void
rpl_process_dio(uip_ipaddr_t *from, rpl_dio_t *dio)
{
if(!curr_instance.used && !rpl_dag_root_is_root()) {
/* Attempt to init our DAG from this DIO */
if(!process_dio_init_dag(dio)) {
LOG_WARN("failed to init DAG\n");
return;
}
}
if(curr_instance.used
&& curr_instance.instance_id == dio->instance_id
&& uip_ipaddr_cmp(&curr_instance.dag.dag_id, &dio->dag_id)) {
process_dio_from_current_dag(from, dio);
rpl_dag_update_state();
}
}
/*---------------------------------------------------------------------------*/
void
rpl_process_dis(uip_ipaddr_t *from, int is_multicast)
{
if(is_multicast) {
rpl_timers_dio_reset("Multicast DIS");
} else {
/* Add neighbor to cache and reply to the unicast DIS with a unicast DIO*/
if(rpl_icmp6_update_nbr_table(from, NBR_TABLE_REASON_RPL_DIS, NULL) != NULL) {
LOG_INFO("unicast DIS, reply to sender\n");
rpl_icmp6_dio_output(from);
}
}
}
/*---------------------------------------------------------------------------*/
void
rpl_process_dao(uip_ipaddr_t *from, rpl_dao_t *dao)
{
if(dao->lifetime == 0) {
uip_sr_expire_parent(NULL, from, &dao->parent_addr);
} else {
if(!uip_sr_update_node(NULL, from, &dao->parent_addr, RPL_LIFETIME(dao->lifetime))) {
LOG_ERR("failed to add link on incoming DAO\n");
return;
}
}
#if RPL_WITH_DAO_ACK
if(dao->flags & RPL_DAO_K_FLAG) {
rpl_timers_schedule_dao_ack(from, dao->sequence);
}
#endif /* RPL_WITH_DAO_ACK */
}
/*---------------------------------------------------------------------------*/
#if RPL_WITH_DAO_ACK
void
rpl_process_dao_ack(uint8_t sequence, uint8_t status)
{
/* Update dao_last_acked_seqno */
if(rpl_lollipop_greater_than(sequence, curr_instance.dag.dao_last_acked_seqno)) {
curr_instance.dag.dao_last_acked_seqno = sequence;
}
/* Is this an ACK for our last DAO? */
if(sequence == curr_instance.dag.dao_last_seqno) {
int status_ok = status < RPL_DAO_ACK_UNABLE_TO_ACCEPT;
if(curr_instance.dag.state == DAG_JOINED && status_ok) {
curr_instance.dag.state = DAG_REACHABLE;
rpl_timers_dio_reset("Reachable");
}
/* Let the rpl-timers module know that we got an ACK for the last DAO */
rpl_timers_notify_dao_ack();
if(!status_ok) {
/* We got a NACK, start poisoning and leave */
LOG_WARN("DAO-NACK received with seqno %u, status %u, poison and leave\n",
sequence, status);
curr_instance.dag.state = DAG_POISONING;
}
}
}
#endif /* RPL_WITH_DAO_ACK */
/*---------------------------------------------------------------------------*/
int
rpl_process_hbh(rpl_nbr_t *sender, uint16_t sender_rank, int loop_detected, int rank_error_signaled)
{
int drop = 0;
if(loop_detected) {
if(rank_error_signaled) {
#if RPL_LOOP_ERROR_DROP
/* Drop packet and reset trickle timer, as per RFC6550 - 11.2.2.2 */
rpl_timers_dio_reset("HBH error");
LOG_WARN("rank error and loop detected, dropping\n");
drop = 1;
#endif /* RPL_LOOP_ERROR_DROP */
}
/* Attempt to repair the loop by sending a unicast DIO back to the sender
* so that it gets a fresh update of our rank. */
rpl_timers_schedule_unicast_dio(sender);
}
if(rank_error_signaled) {
/* A rank error was signalled, attempt to repair it by updating
* the sender's rank from ext header */
if(sender != NULL) {
sender->rank = sender_rank;
/* Select DAG and preferred parent. In case of a parent switch,
the new parent will be used to forward the current packet. */
rpl_dag_update_state();
}
}
return !drop;
}
/*---------------------------------------------------------------------------*/
void
rpl_dag_init_root(uint8_t instance_id, uip_ipaddr_t *dag_id,
uip_ipaddr_t *prefix, unsigned prefix_len, uint8_t prefix_flags)
{
uint8_t version = RPL_LOLLIPOP_INIT;
/* If we're in an instance, first leave it */
if(curr_instance.used) {
/* We were already root. Increment version */
if(uip_ipaddr_cmp(&curr_instance.dag.dag_id, dag_id)) {
version = curr_instance.dag.version;
RPL_LOLLIPOP_INCREMENT(version);
}
rpl_dag_leave();
}
/* Init DAG and instance */
init_dag(instance_id, dag_id, RPL_OF_OCP, prefix, prefix_len, prefix_flags);
/* Instance */
curr_instance.mop = RPL_MOP_DEFAULT;
curr_instance.max_rankinc = RPL_MAX_RANKINC;
curr_instance.min_hoprankinc = RPL_MIN_HOPRANKINC;
curr_instance.dio_intdoubl = RPL_DIO_INTERVAL_DOUBLINGS;
curr_instance.dio_intmin = RPL_DIO_INTERVAL_MIN;
curr_instance.dio_redundancy = RPL_DIO_REDUNDANCY;
curr_instance.default_lifetime = RPL_DEFAULT_LIFETIME;
curr_instance.lifetime_unit = RPL_DEFAULT_LIFETIME_UNIT;
/* DAG */
curr_instance.dag.preference = RPL_PREFERENCE;
curr_instance.dag.grounded = RPL_GROUNDED;
curr_instance.dag.version = version;
curr_instance.dag.rank = ROOT_RANK;
curr_instance.dag.lifetime = RPL_LIFETIME(RPL_INFINITE_LIFETIME);
/* dio_intcurrent will be reset by rpl_timers_dio_reset() */
curr_instance.dag.dio_intcurrent = 0;
curr_instance.dag.state = DAG_REACHABLE;
rpl_timers_dio_reset("Init root");
LOG_INFO("created DAG with instance ID %u, DAG ID ",
curr_instance.instance_id);
LOG_INFO_6ADDR(&curr_instance.dag.dag_id);
LOG_INFO_(", rank %u\n", curr_instance.dag.rank);
LOG_ANNOTATE("#A root=%u\n", curr_instance.dag.dag_id.u8[sizeof(curr_instance.dag.dag_id) - 1]);
}
/*---------------------------------------------------------------------------*/
void
rpl_dag_init(void)
{
memset(&curr_instance, 0, sizeof(curr_instance));
}
/*---------------------------------------------------------------------------*/
/** @} */
|
251d54ac16ca2565ce2a9d43b247ace171ef8d93
|
baa9fffc817a2a993d4ecc774d3f277783308c20
|
/src/uct/base/uct_iface_vfs.c
|
e79ebd885e1bcc52a612b321620d231619600c40
|
[
"BSD-3-Clause"
] |
permissive
|
openucx/ucx
|
9a0f2205295afbdf3cff14b5d24af781b123f5ea
|
73a48700badb7cbace64d94b82f408e2a26fca32
|
refs/heads/master
| 2023-09-01T16:51:26.913950
| 2023-09-01T13:02:25
| 2023-09-01T13:02:25
| 25,379,390
| 966
| 420
|
NOASSERTION
| 2023-09-14T12:29:35
| 2014-10-17T22:17:24
|
C
|
UTF-8
|
C
| false
| false
| 6,513
|
c
|
uct_iface_vfs.c
|
/**
* Copyright (c) NVIDIA CORPORATION & AFFILIATES, 2001-2021. ALL RIGHTS RESERVED.
*
* See file LICENSE for terms.
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "uct_iface.h"
#include "uct_vfs_attr.h"
#include <uct/api/uct.h>
#include <ucs/datastruct/string_buffer.h>
#include <ucs/sys/compiler_def.h>
#include <ucs/sys/string.h>
#include <ucs/vfs/base/vfs_obj.h>
static const uct_vfs_flag_info_t uct_iface_vfs_cap_infos[] = {
{UCT_IFACE_FLAG_AM_SHORT, "am_short"},
{UCT_IFACE_FLAG_AM_BCOPY, "am_bcopy"},
{UCT_IFACE_FLAG_AM_ZCOPY, "am_zcopy"},
{UCT_IFACE_FLAG_PENDING, "pending"},
{UCT_IFACE_FLAG_PUT_SHORT, "put_short"},
{UCT_IFACE_FLAG_PUT_BCOPY, "put_bcopy"},
{UCT_IFACE_FLAG_PUT_ZCOPY, "put_zcopy"},
{UCT_IFACE_FLAG_GET_SHORT, "get_short"},
{UCT_IFACE_FLAG_GET_BCOPY, "get_bcopy"},
{UCT_IFACE_FLAG_GET_ZCOPY, "get_zcopy"},
{UCT_IFACE_FLAG_ATOMIC_CPU, "atomic_cpu"},
{UCT_IFACE_FLAG_ATOMIC_DEVICE, "atomic_device"},
{UCT_IFACE_FLAG_ERRHANDLE_SHORT_BUF, "errhandle_short_buf"},
{UCT_IFACE_FLAG_ERRHANDLE_BCOPY_BUF, "errhandle_bcopy_buf"},
{UCT_IFACE_FLAG_ERRHANDLE_ZCOPY_BUF, "errhandle_zcopy_buf"},
{UCT_IFACE_FLAG_ERRHANDLE_AM_ID, "errhandle_am_id"},
{UCT_IFACE_FLAG_ERRHANDLE_REMOTE_MEM, "errhandle_remote_mem"},
{UCT_IFACE_FLAG_ERRHANDLE_BCOPY_LEN, "errhandle_bcopy_len"},
{UCT_IFACE_FLAG_ERRHANDLE_PEER_FAILURE, "errhandle_peer_failure"},
{UCT_IFACE_FLAG_EP_CHECK, "ep_check"},
{UCT_IFACE_FLAG_CONNECT_TO_IFACE, "connect_to_iface"},
{UCT_IFACE_FLAG_CONNECT_TO_EP, "connect_to_ep"},
{UCT_IFACE_FLAG_CONNECT_TO_SOCKADDR, "connect_to_sockaddr"},
{UCT_IFACE_FLAG_AM_DUP, "am_dup"},
{UCT_IFACE_FLAG_CB_SYNC, "cb_sync"},
{UCT_IFACE_FLAG_CB_ASYNC, "cb_async"},
{UCT_IFACE_FLAG_EP_KEEPALIVE, "ep_keepalive"},
{UCT_IFACE_FLAG_TAG_EAGER_SHORT, "tag_eager_short"},
{UCT_IFACE_FLAG_TAG_EAGER_BCOPY, "tag_eager_bcopy"},
{UCT_IFACE_FLAG_TAG_EAGER_ZCOPY, "tag_eager_zcopy"},
{UCT_IFACE_FLAG_TAG_RNDV_ZCOPY, "tag_rndv_zcopy"},
};
typedef struct {
uint64_t flag;
const char *op_name;
const char *limit_name;
size_t offset;
} uct_iface_vfs_cap_limit_info_t;
#define uct_iface_vfs_cap_limit_info(_flag, _op, _attr) \
{ \
_flag, #_op, #_attr, ucs_offsetof(uct_iface_attr_t, cap._op._attr) \
}
static const uct_iface_vfs_cap_limit_info_t uct_iface_vfs_cap_limit_infos[] = {
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_PUT_SHORT, put, max_short),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_PUT_BCOPY, put, max_bcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_PUT_ZCOPY, put, min_zcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_PUT_ZCOPY, put, max_zcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_PUT_ZCOPY, put,
opt_zcopy_align),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_PUT_SHORT |
UCT_IFACE_FLAG_PUT_BCOPY |
UCT_IFACE_FLAG_PUT_ZCOPY,
put, align_mtu),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_PUT_ZCOPY, put, max_iov),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_GET_SHORT, get, max_short),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_GET_BCOPY, get, max_bcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_GET_ZCOPY, get, min_zcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_GET_ZCOPY, get, max_zcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_GET_ZCOPY, get,
opt_zcopy_align),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_GET_SHORT |
UCT_IFACE_FLAG_GET_BCOPY |
UCT_IFACE_FLAG_GET_ZCOPY,
get, align_mtu),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_GET_ZCOPY, get, max_iov),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_SHORT, am, max_short),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_BCOPY, am, max_bcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_ZCOPY, am, min_zcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_ZCOPY, am, max_zcopy),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_ZCOPY, am, opt_zcopy_align),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_SHORT |
UCT_IFACE_FLAG_AM_BCOPY |
UCT_IFACE_FLAG_AM_ZCOPY,
am, align_mtu),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_ZCOPY, am, max_hdr),
uct_iface_vfs_cap_limit_info(UCT_IFACE_FLAG_AM_ZCOPY, am, max_iov),
};
static void uct_iface_vfs_show_cap_limit(void *obj, ucs_string_buffer_t *strb,
void *arg_ptr, uint64_t arg_u64)
{
uct_iface_h iface = obj;
uct_iface_attr_t iface_attr;
size_t attr;
char buf[64];
if (uct_iface_query(iface, &iface_attr) != UCS_OK) {
ucs_string_buffer_appendf(strb, "<failed to query iface attributes>\n");
return;
}
attr = *(size_t*)UCS_PTR_BYTE_OFFSET(&iface_attr, arg_u64);
ucs_string_buffer_appendf(strb, "%s\n",
ucs_memunits_to_str(attr, buf, sizeof(buf)));
}
static void
uct_iface_vfs_init_cap_limits(uct_iface_h iface, uint64_t iface_cap_flags)
{
size_t i;
for (i = 0; i < ucs_static_array_size(uct_iface_vfs_cap_limit_infos); ++i) {
if (iface_cap_flags & uct_iface_vfs_cap_limit_infos[i].flag) {
ucs_vfs_obj_add_ro_file(iface, uct_iface_vfs_show_cap_limit, NULL,
uct_iface_vfs_cap_limit_infos[i].offset,
"capability/%s/%s",
uct_iface_vfs_cap_limit_infos[i].op_name,
uct_iface_vfs_cap_limit_infos[i].limit_name);
}
}
}
void uct_iface_vfs_refresh(void *obj)
{
uct_base_iface_t *iface = obj;
uct_iface_attr_t iface_attr;
if (uct_iface_query(&iface->super, &iface_attr) == UCS_OK) {
uct_vfs_init_flags(&iface->super, iface_attr.cap.flags,
uct_iface_vfs_cap_infos,
ucs_static_array_size(uct_iface_vfs_cap_infos));
uct_iface_vfs_init_cap_limits(&iface->super, iface_attr.cap.flags);
} else {
ucs_debug("failed to query iface attributes");
}
iface->internal_ops->iface_vfs_refresh(&iface->super);
}
|
e9edc9a4b7a84b669796a8d607489b7f9e94238c
|
a3374503d1f36ae7b9c88542e1b0877d9965dd46
|
/jsb_build/quickjs/demo.c
|
d3e42a4457418da25f21ec9e02bb125255a6150b
|
[
"MIT"
] |
permissive
|
ialex32x/unity-jsb
|
5a72cf18b47a12e43fbf404709ff257edff6163e
|
12a816599c2c3a4013151cf69664881eab258667
|
refs/heads/master
| 2023-07-19T20:33:53.409871
| 2023-07-11T03:39:58
| 2023-07-11T03:39:58
| 223,927,919
| 320
| 34
|
MIT
| 2023-07-07T22:28:43
| 2019-11-25T11:01:46
|
C
|
UTF-8
|
C
| false
| false
| 8,108
|
c
|
demo.c
|
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include "../quickjs.h"
#include "../quickjs-libc.h"
#include "../unity_base.c"
// enum
// {
// JS_ATOM_NULL,
// #define DEF(name, str) JS_ATOM_##name,
// #include "../quickjs-atom.h"
// #undef DEF
// JS_ATOM_END,
// };
JS_BOOL JSB_SetBridgeType(JSContext *ctx, JSValue obj, int32_t type)
{
if (JS_VALUE_GET_TAG(obj) == JS_TAG_OBJECT)
{
JS_SetPropertyStr(ctx, obj, JS_HIDDEN_PROP("type"), JS_NewInt32(ctx, type));
return TRUE;
}
return FALSE;
}
int32_t JSB_GetBridgeType(JSContext *ctx, JSValue obj)
{
if (JS_VALUE_GET_TAG(obj) == JS_TAG_OBJECT)
{
JSValue val = JS_GetPropertyStr(ctx, obj, JS_HIDDEN_PROP("type"));
int32_t pres;
if (JS_ToInt32(ctx, &pres, val) == 0)
{
JS_FreeValue(ctx, val);
return pres;
}
JS_FreeValue(ctx, val);
}
return -1;
}
static int running = 1;
static JSClassID unity_object_class_id;
static void foo_finalizer(JSRuntime *rt, JSValue val)
{
void *data = JS_GetOpaque(val, unity_object_class_id);
printf("unity_object_class.finalizer (%d)\n", (int)data);
}
static int iii = 123;
static JSValue foo_constructor(JSContext *ctx, JSValueConst new_target, int argc, JSValueConst *argv)
{
iii++;
printf("foo.constructor %d\n", iii);
JSValue proto = JS_GetProperty(ctx, new_target, JS_ATOM_prototype);
JSValue obj = JS_NewObjectProtoClass(ctx, proto, unity_object_class_id);
JS_SetOpaque(obj, (void *)iii);
JS_FreeValue(ctx, proto);
JSB_SetBridgeType(ctx, obj, 233);
// return new_target;
return obj;
}
static JSValue foo_call(JSContext *ctx, JSValueConst this_obj, int argc, JSValueConst *argv)
{
void *data = JS_GetOpaque(this_obj, unity_object_class_id);
printf("foo.call %d\n", (int)data);
assert(JSB_GetBridgeType(ctx, this_obj) == 233);
return JS_UNDEFINED;
}
static JSValue goo_constructor(JSContext *ctx, JSValueConst new_target, int argc, JSValueConst *argv)
{
iii++;
printf("goo.constructor %d\n", iii);
JSValue proto = JS_GetProperty(ctx, new_target, JS_ATOM_prototype);
JSValue obj = JS_NewObjectProtoClass(ctx, proto, unity_object_class_id);
JS_SetOpaque(obj, (void *)iii);
JS_FreeValue(ctx, proto);
// return new_target;
return obj;
}
static char *read_file(const char *filename)
{
FILE *fp = fopen(filename, "r");
if (fp)
{
fseek(fp, 0, SEEK_END);
long length = ftell(fp);
fseek(fp, 0, SEEK_SET);
char *buf = malloc(length + 1);
memset(buf, 0, length + 1);
fread(buf, length, 1, fp);
fclose(fp);
return buf;
}
return 0;
}
static void print_exception(JSContext *ctx, JSValueConst e)
{
JSValue err_msg = JS_GetProperty(ctx, e, JS_ATOM_message);
size_t len = 0;
const char *msg_str = JS_ToCStringLen(ctx, &len, err_msg);
printf("exception: %s\n", msg_str);
JS_FreeCString(ctx, msg_str);
JS_FreeValue(ctx, err_msg);
}
static JSValue js_quit(JSContext *ctx, JSValueConst this_val,
int argc, JSValueConst *argv)
{
running = 0;
return JS_UNDEFINED;
}
static JSValue js_print(JSContext *ctx, JSValueConst this_val,
int argc, JSValueConst *argv)
{
int i;
const char *str;
size_t len;
for (i = 0; i < argc; i++)
{
if (i != 0)
putchar(' ');
str = JS_ToCStringLen(ctx, &len, argv[i]);
if (!str)
return JS_EXCEPTION;
fwrite(str, 1, len, stdout);
JS_FreeCString(ctx, str);
}
putchar('\n');
return JS_UNDEFINED;
}
static JSModuleDef *js_module_loader_test(JSContext *ctx,
const char *module_name, void *opaque)
{
printf("js_module_loader: %s\n", module_name);
size_t buf_len;
uint8_t *buf;
JSModuleDef *m;
JSValue func_val;
buf = js_load_file(ctx, &buf_len, module_name);
if (!buf)
{
JS_ThrowReferenceError(ctx, "could not load module filename '%s'",
module_name);
return NULL;
}
/* compile the module */
func_val = JS_Eval(ctx, (char *)buf, buf_len, module_name,
JS_EVAL_TYPE_MODULE | JS_EVAL_FLAG_COMPILE_ONLY);
js_free(ctx, buf);
if (JS_IsException(func_val))
return NULL;
/* the module is already referenced, so we must free it */
m = JS_VALUE_GET_PTR(func_val);
JS_FreeValue(ctx, func_val);
return m;
}
void foo()
{
JSB_Init();
JSRuntime *rt = JS_NewRuntime();
JSContext *ctx = JS_NewContext(rt);
JS_AddIntrinsicOperators(ctx);
JSAtom op = JS_NewAtom(ctx, "Operators");
printf("Operators: %d ?? %d\n", op, JSB_ATOM_Operators());
JS_FreeAtom(ctx, op);
JSValue globalObj = JS_GetGlobalObject(ctx);
JSValue operators = JS_GetPropertyStr(ctx, globalObj, "Operators");
if (JS_IsUndefined(operators))
{
printf("?????????????????\n");
}
JS_FreeValue(ctx, operators);
JS_FreeValue(ctx, globalObj);
JS_SetModuleLoaderFunc(rt, NULL, js_module_loader_test, NULL);
js_init_module_std(ctx, "std");
js_init_module_os(ctx, "os");
JSClassID cls_id;
unity_object_class_id = JS_NewClassID(&cls_id);
JSClassDef cls_def;
cls_def.class_name = "UnityObject";
cls_def.finalizer = foo_finalizer;
cls_def.exotic = NULL;
cls_def.gc_mark = NULL;
cls_def.call = NULL;
JS_NewClass(rt, cls_id, &cls_def);
JSValue global_obj = JS_GetGlobalObject(ctx);
JS_SetPropertyStr(ctx, global_obj, "print", JS_NewCFunction(ctx, js_print, "print", 1));
JS_SetPropertyStr(ctx, global_obj, "quit", JS_NewCFunction(ctx, js_quit, "quit", 0));
JSAtom atom_test = JS_NewAtom(ctx, "Foo");
JSValue foo_proto_val = JS_NewObject(ctx);
JSValue foo_constructor_val = JSB_NewCFunction(ctx, foo_constructor, atom_test, 0, JS_CFUNC_constructor, 0);
JS_SetConstructor(ctx, foo_constructor_val, foo_proto_val);
// JS_SetClassProto(ctx, cls_id, foo_proto_val);
// JS_SetPrototype( __this_is_super_base_class__ );
JSB_SetBridgeType(ctx, foo_constructor_val, 123);
assert(JSB_GetBridgeType(ctx, foo_constructor_val) == 123);
JS_DefinePropertyValue(ctx, global_obj, atom_test, foo_constructor_val, JS_PROP_ENUMERABLE | JS_PROP_CONFIGURABLE);
JSValue foo_prop = JSB_NewPropertyObject(ctx, foo_constructor_val, atom_test, JS_PROP_ENUMERABLE | JS_PROP_CONFIGURABLE);
JSAtom atom_call = JS_NewAtom(ctx, "call");
JSValue foo_call_val = JSB_NewCFunction(ctx, foo_call, atom_call, 0, JS_CFUNC_generic, 0);
JS_DefinePropertyValue(ctx, foo_proto_val, atom_call, foo_call_val, JS_PROP_ENUMERABLE | JS_PROP_CONFIGURABLE);
JS_FreeAtom(ctx, atom_call);
JS_FreeValue(ctx, foo_prop);
JS_FreeAtom(ctx, atom_test);
JSValue goo_proto_val = JS_NewObject(ctx);
JSValue goo_constructor_val = JS_NewCFunction2(ctx, goo_constructor, "Goo", 0, JS_CFUNC_constructor, 0);
JS_SetConstructor(ctx, goo_constructor_val, goo_proto_val);
// JS_SetClassProto(ctx, cls_id, goo_proto_val);
JS_SetPrototype(ctx, goo_proto_val, foo_proto_val);
JS_DefinePropertyValueStr(ctx, global_obj, "Goo", goo_constructor_val, JS_PROP_ENUMERABLE | JS_PROP_CONFIGURABLE);
char *source = read_file("./examples/demo.js");
JSValue rval = JS_Eval(ctx, source, strlen(source), "eval", JS_EVAL_TYPE_MODULE | JS_EVAL_FLAG_STRICT);
if (JS_IsException(rval))
{
JSValue e = JS_GetException(ctx);
print_exception(ctx, e);
}
free(source);
JS_FreeValue(ctx, rval);
JS_FreeValue(ctx, foo_proto_val);
JS_FreeValue(ctx, goo_proto_val);
// JS_FreeValue(ctx, foo_proto_val);
// JS_FreeValue(ctx, foo_constructor_val);
JS_FreeValue(ctx, global_obj);
while (running)
{
js_std_loop(ctx);
}
JS_RunGC(rt);
JS_FreeContext(ctx);
JS_FreeRuntime(rt);
}
int main()
{
printf("demo running...\n");
foo();
fflush(stdout);
return 0;
}
|
0882413143059453145b8208d6b704cccdb23436
|
1e4ff560d2912a98fb71c1194cd52e3a93fc9102
|
/hevd-exploits/uninitialized-stack-variable/uninitialized-stack-variable.h
|
9bcf9be247c159f6d657f84cde549870ca1342fd
|
[
"MIT"
] |
permissive
|
LordNoteworthy/windows-exploitation
|
26204b7e9f431ac06a03b6c30d90d7bea1d61a55
|
be0ed1d5a841b8340c326240cbdf5040948aaac3
|
refs/heads/master
| 2023-08-08T05:27:29.989723
| 2023-07-25T22:12:41
| 2023-07-25T22:12:41
| 150,267,584
| 163
| 34
| null | null | null | null |
UTF-8
|
C
| false
| false
| 7,489
|
h
|
uninitialized-stack-variable.h
|
#pragma once
#include <Windows.h>
#include <tchar.h>
#include <ntstatus.h>
typedef time_t TIME;
typedef struct _CLIENT_ID {
PVOID UniqueProcess;
PVOID UniqueThread;
} CLIENT_ID, *PCLIENT_ID;
typedef struct _LSA_UNICODE_STRING {
USHORT Length;
USHORT MaximumLength;
PWSTR Buffer;
} LSA_UNICODE_STRING, *PLSA_UNICODE_STRING, UNICODE_STRING, *PUNICODE_STRING;
typedef struct _OBJECT_ATTRIBUTES {
ULONG Length;
HANDLE RootDirectory;
PUNICODE_STRING ObjectName;
ULONG Attributes;
PVOID SecurityDescriptor;
PVOID SecurityQualityOfService;
} OBJECT_ATTRIBUTES, *POBJECT_ATTRIBUTES;
typedef struct _SYSTEM_MODULE_INFORMATION_ENTRY {
PVOID Unknown1;
PVOID Unknown2;
PVOID Base;
ULONG Size;
ULONG Flags;
USHORT Index;
USHORT NameLength;
USHORT LoadCount;
USHORT PathLength;
CHAR ImageName[256];
} SYSTEM_MODULE_INFORMATION_ENTRY, *PSYSTEM_MODULE_INFORMATION_ENTRY;
typedef struct _SYSTEM_MODULE_INFORMATION {
ULONG Count;
SYSTEM_MODULE_INFORMATION_ENTRY Module[1];
} SYSTEM_MODULE_INFORMATION, *PSYSTEM_MODULE_INFORMATION;
typedef enum _SYSTEM_INFORMATION_CLASS {
SystemModuleInformation = 11,
SystemHandleInformation = 16
} SYSTEM_INFORMATION_CLASS;
typedef enum _PROCESSINFOCLASS {
ProcessBasicInformation,
ProcessQuotaLimits,
ProcessIoCounters,
ProcessVmCounters,
ProcessTimes,
ProcessBasePriority,
ProcessRaisePriority,
ProcessDebugPort,
ProcessExceptionPort,
ProcessAccessToken,
ProcessLdtInformation,
ProcessLdtSize,
ProcessDefaultHardErrorMode,
ProcessIoPortHandlers,
ProcessPooledUsageAndLimits,
ProcessWorkingSetWatch,
ProcessUserModeIOPL,
ProcessEnableAlignmentFaultFixup,
ProcessPriorityClass,
ProcessWx86Information,
ProcessHandleCount,
ProcessAffinityMask,
ProcessPriorityBoost,
ProcessDeviceMap,
ProcessSessionInformation,
ProcessForegroundInformation,
ProcessWow64Information,
ProcessImageFileName,
ProcessLUIDDeviceMapsEnabled,
ProcessBreakOnTermination,
ProcessDebugObjectHandle,
ProcessDebugFlags,
ProcessHandleTracing,
ProcessIoPriority,
ProcessExecuteFlags,
ProcessTlsInformation,
ProcessCookie,
ProcessImageInformation,
ProcessCycleTime,
ProcessPagePriority,
ProcessInstrumentationCallback,
ProcessThreadStackAllocation,
ProcessWorkingSetWatchEx,
ProcessImageFileNameWin32,
ProcessImageFileMapping,
ProcessAffinityUpdateMode,
ProcessMemoryAllocationMode,
ProcessGroupInformation,
ProcessTokenVirtualizationEnabled,
ProcessConsoleHostProcess,
ProcessWindowInformation,
MaxProcessInfoClass
} PROCESSINFOCLASS;
typedef struct _PROCESS_ACCESS_TOKEN {
HANDLE Token;
HANDLE Thread;
} PROCESS_ACCESS_TOKEN, *PPROCESS_ACCESS_TOKEN;
typedef struct _EPROCESS {
UCHAR NotNeeded1[0x26C];
union {
ULONG Flags2;
struct {
ULONG JobNotReallyActive : 1;
ULONG AccountingFolded : 1;
ULONG NewProcessReported : 1;
ULONG ExitProcessReported : 1;
ULONG ReportCommitChanges : 1;
ULONG LastReportMemory : 1;
ULONG ReportPhysicalPageChanges : 1;
ULONG HandleTableRundown : 1;
ULONG NeedsHandleRundown : 1;
ULONG RefTraceEnabled : 1;
ULONG NumaAware : 1;
ULONG ProtectedProcess : 1;
ULONG DefaultPagePriority : 3;
ULONG PrimaryTokenFrozen : 1;
ULONG ProcessVerifierTarget : 1;
ULONG StackRandomizationDisabled : 1;
ULONG AffinityPermanent : 1;
ULONG AffinityUpdateEnable : 1;
ULONG PropagateNode : 1;
ULONG ExplicitAffinity : 1;
};
};
UCHAR NotNeeded2[0x50];
} EPROCESS, *PEPROCESS;
typedef struct _PROCESS_DEVICEMAP_INFORMATION {
HANDLE DirectoryHandle;
} PROCESS_DEVICEMAP_INFORMATION, *PPROCESS_DEVICEMAP_INFORMATION;
typedef NTSTATUS(WINAPI *ZwClose_t)(IN HANDLE hObject);
typedef PEPROCESS(WINAPI *PsGetCurrentProcess_t)(VOID);
typedef PACCESS_TOKEN(WINAPI *PsReferencePrimaryToken_t)(IN OUT PVOID Process);
typedef NTSTATUS(WINAPI *NtQueryIntervalProfile_t)(IN ULONG ProfileSource,
OUT PULONG Interval);
typedef NTSTATUS(WINAPI *ZwOpenProcessToken_t)(IN HANDLE ProcessHandle,
IN ACCESS_MASK DesiredAccess,
OUT PHANDLE TokenHandle);
typedef NTSTATUS(WINAPI *PsLookupProcessByProcessId_t)(IN HANDLE ProcessId,
OUT PVOID Process);
typedef NTSTATUS(WINAPI *ZwSetInformationProcess_t)(IN HANDLE ProcessHandle,
IN ULONG ProcessInformationClass,
IN PVOID ProcessInformation,
IN ULONG ProcessInformationLength);
typedef NTSTATUS(WINAPI *ZwOpenProcess_t)(OUT PHANDLE ProcessHandle,
IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes,
IN PCLIENT_ID ClientId OPTIONAL);
typedef NTSTATUS(WINAPI *NtAllocateVirtualMemory_t)(IN HANDLE ProcessHandle,
IN OUT PVOID *BaseAddress,
IN ULONG ZeroBits,
IN OUT PULONG AllocationSize,
IN ULONG AllocationType,
IN ULONG Protect);
typedef NTSTATUS(WINAPI *NtAllocateReserveObject_t)(OUT PHANDLE hObject,
IN POBJECT_ATTRIBUTES ObjectAttributes,
IN DWORD ObjectType);
typedef NTSTATUS(WINAPI *NtMapUserPhysicalPages_t)(IN PVOID VirtualAddress,
IN ULONG_PTR NumberOfPages,
IN OUT PULONG_PTR UserPfnArray);
typedef NTSTATUS(WINAPI *ZwDuplicateToken_t)(IN HANDLE ExistingTokenHandle,
IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes,
IN BOOLEAN EffectiveOnly,
IN TOKEN_TYPE TokenType,
OUT PHANDLE NewTokenHandle);
typedef NTSTATUS(WINAPI *NtQuerySystemInformation_t)(IN SYSTEM_INFORMATION_CLASS SystemInformationClass,
OUT PVOID SystemInformation,
IN ULONG SystemInformationLength,
OUT PULONG ReturnLength);
typedef NTSTATUS(WINAPI *NtSetInformationProcess_t)(IN HANDLE ProcessHandle,
IN PROCESSINFOCLASS ProcessInformationClass,
IN PVOID ProcessInformation,
IN ULONG ProcessInformationLength);
typedef NTSTATUS(WINAPI *NtCreateDirectoryObject_t)(OUT PHANDLE DirectoryHandle,
IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes);
typedef NTSTATUS(WINAPI *NtOpenDirectoryObject_t)(OUT PHANDLE DirectoryHandle,
IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes);
typedef VOID(WINAPI *RtlInitUnicodeString_t)(IN OUT PUNICODE_STRING DestinationString,
IN PCWSTR SourceString OPTIONAL);
typedef NTSTATUS(WINAPI *NtCreateSymbolicLinkObject_t)(OUT PHANDLE SymbolicLinkHandle,
IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes,
IN PUNICODE_STRING TargetName);
ZwClose_t ZwClose;
ZwOpenProcess_t ZwOpenProcess;
ZwDuplicateToken_t ZwDuplicateToken;
ZwOpenProcessToken_t ZwOpenProcessToken;
PsGetCurrentProcess_t PsGetCurrentProcess;
RtlInitUnicodeString_t RtlInitUnicodeString;
NtOpenDirectoryObject_t NtOpenDirectoryObject;
NtMapUserPhysicalPages_t NtMapUserPhysicalPages;
NtQueryIntervalProfile_t NtQueryIntervalProfile;
NtSetInformationProcess_t NtSetInformationProcess;
ZwSetInformationProcess_t ZwSetInformationProcess;
NtAllocateReserveObject_t NtAllocateReserveObject;
NtAllocateVirtualMemory_t NtAllocateVirtualMemory;
NtCreateDirectoryObject_t NtCreateDirectoryObject;
PsReferencePrimaryToken_t PsReferencePrimaryToken;
NtQuerySystemInformation_t NtQuerySystemInformation;
PsLookupProcessByProcessId_t PsLookupProcessByProcessId;
NtCreateSymbolicLinkObject_t NtCreateSymbolicLinkObject;
|
473b8bc067bcf74dcaf199e19b9db381ead22f5e
|
99bdb3251fecee538e0630f15f6574054dfc1468
|
/bsp/imxrt/libraries/MIMXRT1170/MIMXRT1176/drivers/fsl_smartcard_emvsim.h
|
397966bc02079e3f8d1c9542c920dd1febcaae56
|
[
"Apache-2.0",
"Zlib",
"LicenseRef-scancode-proprietary-license",
"MIT",
"BSD-3-Clause",
"X11",
"BSD-4-Clause-UC",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
RT-Thread/rt-thread
|
03a7c52c2aeb1b06a544143b0e803d72f47d1ece
|
3602f891211904a27dcbd51e5ba72fefce7326b2
|
refs/heads/master
| 2023-09-01T04:10:20.295801
| 2023-08-31T16:20:55
| 2023-08-31T16:20:55
| 7,408,108
| 9,599
| 5,805
|
Apache-2.0
| 2023-09-14T13:37:26
| 2013-01-02T14:49:21
|
C
|
UTF-8
|
C
| false
| false
| 6,481
|
h
|
fsl_smartcard_emvsim.h
|
/*
* Copyright (c) 2015-2016, Freescale Semiconductor, Inc.
* Copyright 2016-2017 NXP
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef _FSL_SMARTCARD_EMVSIM_H_
#define _FSL_SMARTCARD_EMVSIM_H_
#include "fsl_smartcard.h"
/*!
* @addtogroup smartcard_emvsim_driver
* @{
*/
/*******************************************************************************
* Definitions
******************************************************************************/
/*! @brief EMV RX NACK interrupt generation threshold */
#define SMARTCARD_EMV_RX_NACK_THRESHOLD (5u)
/*! @brief EMV TX NACK interrupt generation threshold */
#define SMARTCARD_EMV_TX_NACK_THRESHOLD (5u)
/*! @brief Smart card Word Wait Timer adjustment value */
#define SMARTCARD_WWT_ADJUSTMENT (160u)
/*! @brief Smart card Character Wait Timer adjustment value */
#define SMARTCARD_CWT_ADJUSTMENT (3u)
/*! @brief General Purpose Counter clock selections */
typedef enum _emvsim_gpc_clock_select
{
kEMVSIM_GPCClockDisable = 0u, /*!< Disabled */
kEMVSIM_GPCCardClock = 1u, /*!< Card clock */
kEMVSIM_GPCRxClock = 2u, /*!< Receive clock */
kEMVSIM_GPCTxClock = 3u, /*!< Transmit ETU clock */
} emvsim_gpc_clock_select_t;
/*! @brief EMVSIM card presence detection edge control */
typedef enum _presence_detect_edge
{
kEMVSIM_DetectOnFallingEdge = 0u, /*!< Presence detected on the falling edge */
kEMVSIM_DetectOnRisingEdge = 1u, /*!< Presence detected on the rising edge */
} emvsim_presence_detect_edge_t;
/*! @brief EMVSIM card presence detection status */
typedef enum _presence_detect_status
{
kEMVSIM_DetectPinIsLow = 0u, /*!< Presence detected pin is logic low */
kEMVSIM_DetectPinIsHigh = 1u, /*!< Presence detected pin is logic high */
} emvsim_presence_detect_status_t;
/*******************************************************************************
* API
******************************************************************************/
#if defined(__cplusplus)
extern "C" {
#endif
/*!
* @name Smart card EMVSIM Driver
* @{
*/
/*!
* @brief Fills in the smartcard_card_params structure with default values according to the EMV 4.3 specification.
*
* @param cardParams The configuration structure of type smartcard_interface_config_t.
* Function fill in members:
* Fi = 372;
* Di = 1;
* currentD = 1;
* WI = 0x0A;
* GTN = 0x00;
* with default values.
*/
void SMARTCARD_EMVSIM_GetDefaultConfig(smartcard_card_params_t *cardParams);
/*!
* @brief Initializes an EMVSIM peripheral for the Smart card/ISO-7816 operation.
*
* This function un-gates the EMVSIM clock, initializes the module to EMV default settings,
* configures the IRQ, enables the module-level interrupt to the core and, initializes the driver context.
*
* @param base The EMVSIM peripheral base address.
* @param context A pointer to the smart card driver context structure.
* @param srcClock_Hz Smart card clock generation module source clock.
*
* @return An error code or kStatus_SMARTCARD_Success.
*/
status_t SMARTCARD_EMVSIM_Init(EMVSIM_Type *base, smartcard_context_t *context, uint32_t srcClock_Hz);
/*!
* @brief This function disables the EMVSIM interrupts, disables the transmitter and receiver,
* flushes the FIFOs, and gates EMVSIM clock in SIM.
*
* @param base The EMVSIM module base address.
*/
void SMARTCARD_EMVSIM_Deinit(EMVSIM_Type *base);
/*!
* @brief Returns whether the previous EMVSIM transfer has finished.
*
* When performing an async transfer, call this function to ascertain the context of the
* current transfer: in progress (or busy) or complete (success). If the
* transfer is still in progress, the user can obtain the number of words that have not been
* transferred.
*
* @param base The EMVSIM module base address.
* @param context A pointer to a smart card driver context structure.
*
* @return The number of bytes not transferred.
*/
int32_t SMARTCARD_EMVSIM_GetTransferRemainingBytes(EMVSIM_Type *base, smartcard_context_t *context);
/*!
* @brief Terminates an asynchronous EMVSIM transfer early.
*
* During an async EMVSIM transfer, the user can terminate the transfer early
* if the transfer is still in progress.
*
* @param base The EMVSIM peripheral address.
* @param context A pointer to a smart card driver context structure.
* @retval kStatus_SMARTCARD_Success The transmit abort was successful.
* @retval kStatus_SMARTCARD_NoTransmitInProgress No transmission is currently in progress.
*/
status_t SMARTCARD_EMVSIM_AbortTransfer(EMVSIM_Type *base, smartcard_context_t *context);
/*!
* @brief Transfer data using interrupts.
*
* A non-blocking (also known as asynchronous) function means that the function returns
* immediately after initiating the transfer function. The application has to get the
* transfer status to see when the transfer is complete. In other words, after calling the non-blocking
* (asynchronous) transfer function, the application must get the transfer status to check if the transmit
* is completed or not.
*
* @param base The EMVSIM peripheral base address.
* @param context A pointer to a smart card driver context structure.
* @param xfer A pointer to the smart card transfer structure where the linked buffers and sizes are stored.
*
* @return An error code or kStatus_SMARTCARD_Success.
*/
status_t SMARTCARD_EMVSIM_TransferNonBlocking(EMVSIM_Type *base, smartcard_context_t *context, smartcard_xfer_t *xfer);
/*!
* @brief Controls the EMVSIM module per different user request.
*
* @param base The EMVSIM peripheral base address.
* @param context A pointer to a smart card driver context structure.
* @param control Control type.
* @param param Integer value of specific to control command.
*
* return kStatus_SMARTCARD_Success in success.
* return kStatus_SMARTCARD_OtherError in case of error.
*/
status_t SMARTCARD_EMVSIM_Control(EMVSIM_Type *base,
smartcard_context_t *context,
smartcard_control_t control,
uint32_t param);
/*!
* @brief Handles EMVSIM module interrupts.
*
* @param base The EMVSIM peripheral base address.
* @param context A pointer to a smart card driver context structure.
*/
void SMARTCARD_EMVSIM_IRQHandler(EMVSIM_Type *base, smartcard_context_t *context);
/*@}*/
#if defined(__cplusplus)
}
#endif
/*! @}*/
#endif /* _FSL_SMARTCARD_EMVSIM_H_*/
|
5ebfead0976460316fbc0976d6bbc8dd507a8208
|
28d0f8c01599f8f6c711bdde0b59f9c2cd221203
|
/sys/arch/mac68k/obio/wdc_obio.c
|
5f77dbadce057c142693deefab2209e40520cdbe
|
[] |
no_license
|
NetBSD/src
|
1a9cbc22ed778be638b37869ed4fb5c8dd616166
|
23ee83f7c0aea0777bd89d8ebd7f0cde9880d13c
|
refs/heads/trunk
| 2023-08-31T13:24:58.105962
| 2023-08-27T15:50:47
| 2023-08-27T15:50:47
| 88,439,547
| 656
| 348
| null | 2023-07-20T20:07:24
| 2017-04-16T20:03:43
| null |
UTF-8
|
C
| false
| false
| 6,807
|
c
|
wdc_obio.c
|
/* $NetBSD: wdc_obio.c,v 1.32 2022/08/20 20:02:22 tsutsui Exp $ */
/*
* Copyright (c) 2002 Takeshi Shibagaki All rights reserved.
*
* mac68k OBIO-IDE attachment created by Takeshi Shibagaki
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. 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.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by Charles M. Hannum.
* 4. The name of the author may not be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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 AUTHOR 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.
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: wdc_obio.c,v 1.32 2022/08/20 20:02:22 tsutsui Exp $");
#include <sys/types.h>
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/device.h>
#include <sys/kernel.h>
#include <sys/kmem.h>
#include <sys/callout.h>
#include <machine/bus.h>
#include <machine/intr.h>
#include <machine/cpu.h>
#include <machine/viareg.h>
#include <mac68k/obio/obiovar.h>
#include <dev/ata/atavar.h>
#include <dev/ic/wdcvar.h>
#define WDC_OBIO_REG_NPORTS 0x40
#define WDC_OBIO_AUXREG_OFFSET 0x38
#define WDC_OBIO_AUXREG_NPORTS 1
#define WDC_OBIO_ISR_OFFSET 0x101
#define WDC_OBIO_ISR_NPORTS 1
static u_long IDEBase = 0x50f1a000;
/*
* XXX This code currently doesn't even try to allow 32-bit data port use.
*/
struct wdc_obio_softc {
struct wdc_softc sc_wdcdev;
struct ata_channel *sc_chanlist[1];
struct ata_channel sc_channel;
struct wdc_regs sc_wdc_regs;
void *sc_ih;
};
int wdc_obio_match(device_t, cfdata_t, void *);
void wdc_obio_attach(device_t, device_t, void *);
void wdc_obio_intr(void *);
CFATTACH_DECL_NEW(wdc_obio, sizeof(struct wdc_obio_softc),
wdc_obio_match, wdc_obio_attach, NULL, NULL);
static bus_space_tag_t wdc_obio_isr_tag;
static bus_space_handle_t wdc_obio_isr_hdl;
static struct ata_channel *ch_sc;
int
wdc_obio_match(device_t parent, cfdata_t match, void *aux)
{
struct obio_attach_args *oa = (struct obio_attach_args *) aux;
struct wdc_regs *wdr;
int i, result = 0;
wdr = kmem_alloc(sizeof(*wdr), KM_SLEEP);
switch (current_mac_model->machineid) {
case MACH_MACPB150:
case MACH_MACPB190:
case MACH_MACPB190CS:
case MACH_MACP580:
case MACH_MACQ630:
wdr->cmd_iot = wdr->ctl_iot = oa->oa_tag;
if (bus_space_map(wdr->cmd_iot, IDEBase, WDC_OBIO_REG_NPORTS,
0, &wdr->cmd_baseioh))
goto out;
mac68k_bus_space_handle_swapped(wdr->cmd_iot,
&wdr->cmd_baseioh);
for (i = 0; i < WDC_NREG; i++) {
if (bus_space_subregion(wdr->cmd_iot, wdr->cmd_baseioh,
i * 4, 4, &wdr->cmd_iohs[i]) != 0)
goto unmap;
}
wdc_init_shadow_regs(wdr);
if (bus_space_subregion(wdr->cmd_iot, wdr->cmd_baseioh,
WDC_OBIO_AUXREG_OFFSET, WDC_OBIO_AUXREG_NPORTS,
&wdr->ctl_ioh))
goto unmap;
result = wdcprobe(wdr);
unmap:
bus_space_unmap(wdr->cmd_iot, wdr->cmd_baseioh,
WDC_OBIO_REG_NPORTS);
}
out:
kmem_free(wdr, sizeof(*wdr));
return result;
}
void
wdc_obio_attach(device_t parent, device_t self, void *aux)
{
struct wdc_obio_softc *sc = device_private(self);
struct wdc_regs *wdr;
struct obio_attach_args *oa = aux;
struct ata_channel *chp = &sc->sc_channel;
int i;
sc->sc_wdcdev.sc_atac.atac_dev = self;
sc->sc_wdcdev.regs = wdr = &sc->sc_wdc_regs;
oa->oa_addr = IDEBase;
wdr->cmd_iot = wdr->ctl_iot = oa->oa_tag;
if (bus_space_map(wdr->cmd_iot, oa->oa_addr, WDC_OBIO_REG_NPORTS, 0,
&wdr->cmd_baseioh)) {
aprint_error(": couldn't map registers\n");
return;
}
mac68k_bus_space_handle_swapped(wdr->cmd_iot, &wdr->cmd_baseioh);
for (i = 0; i < WDC_NREG; i++) {
if (bus_space_subregion(wdr->cmd_iot, wdr->cmd_baseioh,
i * 4, 4, &wdr->cmd_iohs[i]) != 0) {
aprint_error(
": unable to subregion control register\n");
goto err;
}
}
if (bus_space_subregion(wdr->cmd_iot, wdr->cmd_baseioh,
WDC_OBIO_AUXREG_OFFSET, WDC_OBIO_AUXREG_NPORTS, &wdr->ctl_ioh)) {
aprint_error(": unable to subregion aux register\n");
goto err;
}
wdc_obio_isr_tag = oa->oa_tag;
if (bus_space_map(wdc_obio_isr_tag, oa->oa_addr + WDC_OBIO_ISR_OFFSET,
WDC_OBIO_ISR_NPORTS, 0, &wdc_obio_isr_hdl)) {
aprint_error(": couldn't map intr status register\n");
goto err;
}
switch (current_mac_model->machineid) {
case MACH_MACP580:
case MACH_MACQ630:
/*
* Quadra/Performa IDE generates pseudo Nubus intr at slot F
*/
aprint_normal(" (Quadra/Performa series IDE interface)");
add_nubus_intr(0xf, wdc_obio_intr, sc);
break;
case MACH_MACPB150:
case MACH_MACPB190:
case MACH_MACPB190CS:
/*
* PowerBook IDE generates pseudo NuBus intr at slot C
*/
aprint_normal(" (PowerBook series IDE interface)");
add_nubus_intr(0xc, wdc_obio_intr, sc);
break;
}
ch_sc = chp;
if ((device_cfdata(self)->cf_flags & ATAC_CAP_NOIRQ) != 0)
sc->sc_wdcdev.sc_atac.atac_cap |= ATAC_CAP_NOIRQ;
sc->sc_wdcdev.sc_atac.atac_cap |= ATAC_CAP_DATA16;
sc->sc_wdcdev.sc_atac.atac_pio_cap = 0;
sc->sc_chanlist[0] = chp;
sc->sc_wdcdev.sc_atac.atac_channels = sc->sc_chanlist;
sc->sc_wdcdev.sc_atac.atac_nchannels = 1;
sc->sc_wdcdev.wdc_maxdrives = 2;
chp->ch_channel = 0;
chp->ch_atac = &sc->sc_wdcdev.sc_atac;
wdc_init_shadow_regs(wdr);
aprint_normal("\n");
wdcattach(chp);
return;
err:
bus_space_unmap(wdr->cmd_iot, wdr->cmd_baseioh, WDC_OBIO_REG_NPORTS);
}
void
wdc_obio_intr(void *arg)
{
uint8_t status;
status = bus_space_read_1(wdc_obio_isr_tag, wdc_obio_isr_hdl, 0);
if ((status & 0x20) != 0) {
wdcintr(ch_sc);
bus_space_write_1(wdc_obio_isr_tag, wdc_obio_isr_hdl, 0,
status & ~0x20);
}
}
|
fc03384ad60ff821522808cf5d85ffe79285decf
|
dbc5fd6f0b741d07aca08cff31fe88d2f62e8483
|
/tools/clang/test/zapcc/multi/section-or-fragment/f.h
|
352623a769477ce64713912e6c4f354f99d0cc31
|
[
"LicenseRef-scancode-unknown-license-reference",
"NCSA"
] |
permissive
|
yrnkrn/zapcc
|
647246a2ed860f73adb49fa1bd21333d972ff76b
|
c6a8aa30006d997eff0d60fd37b0e62b8aa0ea50
|
refs/heads/master
| 2023-03-08T22:55:12.842122
| 2020-07-21T10:21:59
| 2020-07-21T10:21:59
| 137,340,494
| 1,255
| 88
|
NOASSERTION
| 2020-07-21T10:22:01
| 2018-06-14T10:00:31
|
C++
|
UTF-8
|
C
| false
| false
| 62
|
h
|
f.h
|
extern "C" {
void *memset ( void *, int,unsigned long int);
}
|
9715f8d63843c66780f2241bcad54d89686a7055
|
a7856278e39f6030eacbb0680ca66b57e30ca06b
|
/generation/DirectX/um/dwrite_3/um-dwrite_3.h
|
f93742716036641c2fee2d6907d86b01335c1b3a
|
[
"MIT"
] |
permissive
|
terrafx/terrafx.interop.windows
|
07f1ac52cbaea6c0f5f8f6147df7a8dd50345f49
|
fadce5a41fa5e6f0282e80e96f033d0a2c130991
|
refs/heads/main
| 2023-07-09T03:56:06.057946
| 2023-06-23T16:01:17
| 2023-06-23T16:01:17
| 192,857,891
| 208
| 46
|
MIT
| 2023-07-07T17:25:55
| 2019-06-20T05:58:46
|
C#
|
UTF-8
|
C
| false
| false
| 52
|
h
|
um-dwrite_3.h
|
#include "..\..\..\TerraFX.h"
#include <dwrite_3.h>
|
b913fd060f66124cf0393d03f00ede84b896758c
|
5ed4f58304033044e3a259f2a678328de4696692
|
/src/window.c
|
e5884d57e76b89a357c8f7329da2cd5398d5249e
|
[
"Unlicense",
"LicenseRef-scancode-public-domain"
] |
permissive
|
troglobit/mg
|
a971a04a1610f93d57636f1253760684ea7b29a9
|
46dca121b1d67758ee06809d8eb72d0b9d6def65
|
refs/heads/master
| 2023-08-21T22:52:12.135823
| 2023-08-13T15:31:28
| 2023-08-13T15:31:28
| 58,325,928
| 333
| 39
|
Unlicense
| 2023-08-09T23:59:32
| 2016-05-08T18:41:56
|
C
|
UTF-8
|
C
| false
| false
| 9,993
|
c
|
window.c
|
/* $OpenBSD: window.c,v 1.35 2015/10/29 20:20:49 lum Exp $ */
/* This file is in the public domain. */
/*
* Window handling.
*/
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include "def.h"
struct mgwin *
new_window(struct buffer *bp)
{
struct mgwin *wp;
wp = calloc(1, sizeof(struct mgwin));
if (wp == NULL)
return (NULL);
wp->w_bufp = bp;
wp->w_dotp = NULL;
wp->w_doto = 0;
wp->w_markp = NULL;
wp->w_marko = 0;
wp->w_rflag = 0;
wp->w_frame = 0;
wp->w_wrapline = NULL;
wp->w_dotline = wp->w_markline = 1;
if (bp)
bp->b_nwnd++;
return (wp);
}
/*
* Reposition dot in the current window to line "n". If the argument is
* positive, it is that line. If it is negative it is that line from the
* bottom. If it is 0 the window is centered (this is what the standard
* redisplay code does).
*/
int
reposition(int f, int n)
{
curwp->w_frame = (f & FFARG) ? (n >= 0 ? n + 1 : n) : 0;
curwp->w_rflag |= WFFRAME;
sgarbf = TRUE;
return (TRUE);
}
/*
* Refresh the display. A call is made to the "ttresize" entry in the
* terminal handler, which tries to reset "nrow" and "ncol". They will,
* however, never be set outside of the NROW or NCOL range. If the display
* changed size, arrange that everything is redone, then call "update" to
* fix the display. We do this so the new size can be displayed. In the
* normal case the call to "update" in "main.c" refreshes the screen, and
* all of the windows need not be recomputed. This call includes a
* 'force' parameter to ensure that the redraw is done, even after a
* a suspend/continue (where the window size parameters will already
* be updated). Note that when you get to the "display unusable"
* message, the screen will be messed up. If you make the window bigger
* again, and send another command, everything will get fixed!
*/
int
redraw(int f, int n)
{
return (do_redraw(f, n, FALSE));
}
int
do_redraw(int f, int n, int force)
{
struct mgwin *wp;
int oldnrow, oldncol;
oldnrow = nrow;
oldncol = ncol;
ttresize();
if (nrow != oldnrow || ncol != oldncol || force) {
/* find last */
wp = wheadp;
while (wp->w_wndp != NULL)
wp = wp->w_wndp;
/* check if too small */
if (nrow < wp->w_toprow + 3) {
dobeep();
ewprintf("Display unusable");
return (FALSE);
}
wp->w_ntrows = nrow - wp->w_toprow - 2;
sgarbf = TRUE;
update(CMODE);
} else
sgarbf = TRUE;
return (TRUE);
}
/*
* The command to make the next window (next => down the screen) the current
* window. There are no real errors, although the command does nothing if
* there is only 1 window on the screen.
*/
int
nextwind(int f, int n)
{
struct mgwin *wp;
if ((wp = curwp->w_wndp) == NULL)
wp = wheadp;
curwp = wp;
curbp = wp->w_bufp;
return (TRUE);
}
/* not in GNU Emacs */
/*
* This command makes the previous window (previous => up the screen) the
* current window. There are no errors, although the command does not do
* a lot if there is only 1 window.
*/
int
prevwind(int f, int n)
{
struct mgwin *wp1, *wp2;
wp1 = wheadp;
wp2 = curwp;
if (wp1 == wp2)
wp2 = NULL;
while (wp1->w_wndp != wp2)
wp1 = wp1->w_wndp;
curwp = wp1;
curbp = wp1->w_bufp;
return (TRUE);
}
/*
* This command makes the current window the only window on the screen. Try
* to set the framing so that "." does not have to move on the display. Some
* care has to be taken to keep the values of dot and mark in the buffer
* structures right if the destruction of a window makes a buffer become
* undisplayed.
*/
int
onlywind(int f, int n)
{
struct mgwin *wp;
struct line *lp;
int i;
while (wheadp != curwp) {
wp = wheadp;
wheadp = wp->w_wndp;
if (--wp->w_bufp->b_nwnd == 0) {
wp->w_bufp->b_dotp = wp->w_dotp;
wp->w_bufp->b_doto = wp->w_doto;
wp->w_bufp->b_markp = wp->w_markp;
wp->w_bufp->b_marko = wp->w_marko;
wp->w_bufp->b_dotline = wp->w_dotline;
wp->w_bufp->b_markline = wp->w_markline;
}
free(wp);
}
while (curwp->w_wndp != NULL) {
wp = curwp->w_wndp;
curwp->w_wndp = wp->w_wndp;
if (--wp->w_bufp->b_nwnd == 0) {
wp->w_bufp->b_dotp = wp->w_dotp;
wp->w_bufp->b_doto = wp->w_doto;
wp->w_bufp->b_markp = wp->w_markp;
wp->w_bufp->b_marko = wp->w_marko;
wp->w_bufp->b_dotline = wp->w_dotline;
wp->w_bufp->b_markline = wp->w_markline;
}
free(wp);
}
lp = curwp->w_linep;
i = curwp->w_toprow;
while (i != 0 && lback(lp) != curbp->b_headp) {
--i;
lp = lback(lp);
}
curwp->w_toprow = 0;
/* 2 = mode, echo */
curwp->w_ntrows = nrow - 2;
curwp->w_linep = lp;
curwp->w_rflag |= WFMODE | WFFULL;
return (TRUE);
}
/*
* Split the current window. A window smaller than 3 lines cannot be split.
* The only other error that is possible is a "malloc" failure allocating the
* structure for the new window.
* If called with a FFOTHARG, flags on the new window are set to 'n'.
*/
int
splitwind(int f, int n)
{
struct mgwin *wp, *wp1, *wp2;
struct line *lp;
int ntru, ntrd, ntrl;
if (curwp->w_ntrows < 3) {
dobeep();
ewprintf("Cannot split a %d line window", curwp->w_ntrows);
return (FALSE);
}
wp = new_window(curbp);
if (wp == NULL) {
dobeep();
ewprintf("Unable to create a window");
return (FALSE);
}
/* use the current dot and mark */
wp->w_dotp = curwp->w_dotp;
wp->w_doto = curwp->w_doto;
wp->w_markp = curwp->w_markp;
wp->w_marko = curwp->w_marko;
wp->w_dotline = curwp->w_dotline;
wp->w_markline = curwp->w_markline;
/* figure out which half of the screen we're in */
ntru = (curwp->w_ntrows - 1) / 2; /* Upper size */
ntrl = (curwp->w_ntrows - 1) - ntru; /* Lower size */
for (lp = curwp->w_linep, ntrd = 0; lp != curwp->w_dotp;
lp = lforw(lp))
ntrd++;
lp = curwp->w_linep;
/* old is upper window */
if (ntrd <= ntru) {
/* hit mode line */
if (ntrd == ntru)
lp = lforw(lp);
curwp->w_ntrows = ntru;
wp->w_wndp = curwp->w_wndp;
curwp->w_wndp = wp;
wp->w_toprow = curwp->w_toprow + ntru + 1;
wp->w_ntrows = ntrl;
/* old is lower window */
} else {
wp1 = NULL;
wp2 = wheadp;
while (wp2 != curwp) {
wp1 = wp2;
wp2 = wp2->w_wndp;
}
if (wp1 == NULL)
wheadp = wp;
else
wp1->w_wndp = wp;
wp->w_wndp = curwp;
wp->w_toprow = curwp->w_toprow;
wp->w_ntrows = ntru;
/* mode line */
++ntru;
curwp->w_toprow += ntru;
curwp->w_ntrows = ntrl;
while (ntru--)
lp = lforw(lp);
}
/* adjust the top lines if necessary */
curwp->w_linep = lp;
wp->w_linep = lp;
curwp->w_rflag |= WFMODE | WFFULL;
wp->w_rflag |= WFMODE | WFFULL;
/* if FFOTHARG, set flags) */
if (f & FFOTHARG)
wp->w_flag = n;
return (TRUE);
}
/*
* Enlarge the current window. Find the window that loses space. Make sure
* it is big enough. If so, hack the window descriptions, and ask redisplay
* to do all the hard work. You don't just set "force reframe" because dot
* would move.
*/
int
enlargewind(int f, int n)
{
struct mgwin *adjwp;
struct line *lp;
int i;
if (n < 0)
return (shrinkwind(f, -n));
if (wheadp->w_wndp == NULL) {
dobeep();
ewprintf("Only one window");
return (FALSE);
}
if ((adjwp = curwp->w_wndp) == NULL) {
adjwp = wheadp;
while (adjwp->w_wndp != curwp)
adjwp = adjwp->w_wndp;
}
if (adjwp->w_ntrows <= n) {
dobeep();
ewprintf("Impossible change");
return (FALSE);
}
/* shrink below */
if (curwp->w_wndp == adjwp) {
lp = adjwp->w_linep;
for (i = 0; i < n && lp != adjwp->w_bufp->b_headp; ++i)
lp = lforw(lp);
adjwp->w_linep = lp;
adjwp->w_toprow += n;
/* shrink above */
} else {
lp = curwp->w_linep;
for (i = 0; i < n && lback(lp) != curbp->b_headp; ++i)
lp = lback(lp);
curwp->w_linep = lp;
curwp->w_toprow -= n;
}
curwp->w_ntrows += n;
adjwp->w_ntrows -= n;
curwp->w_rflag |= WFMODE | WFFULL;
adjwp->w_rflag |= WFMODE | WFFULL;
return (TRUE);
}
/*
* Shrink the current window. Find the window that gains space. Hack at the
* window descriptions. Ask the redisplay to do all the hard work.
*/
int
shrinkwind(int f, int n)
{
struct mgwin *adjwp;
struct line *lp;
int i;
if (n < 0)
return (enlargewind(f, -n));
if (wheadp->w_wndp == NULL) {
dobeep();
ewprintf("Only one window");
return (FALSE);
}
/*
* Bit of flakiness - FFRAND means it was an internal call, and
* to be trusted implicitly about sizes.
*/
if (!(f & FFRAND) && curwp->w_ntrows <= n) {
dobeep();
ewprintf("Impossible change");
return (FALSE);
}
if ((adjwp = curwp->w_wndp) == NULL) {
adjwp = wheadp;
while (adjwp->w_wndp != curwp)
adjwp = adjwp->w_wndp;
}
/* grow below */
if (curwp->w_wndp == adjwp) {
lp = adjwp->w_linep;
for (i = 0; i < n && lback(lp) != adjwp->w_bufp->b_headp; ++i)
lp = lback(lp);
adjwp->w_linep = lp;
adjwp->w_toprow -= n;
/* grow above */
} else {
lp = curwp->w_linep;
for (i = 0; i < n && lp != curbp->b_headp; ++i)
lp = lforw(lp);
curwp->w_linep = lp;
curwp->w_toprow += n;
}
curwp->w_ntrows -= n;
adjwp->w_ntrows += n;
curwp->w_rflag |= WFMODE | WFFULL;
adjwp->w_rflag |= WFMODE | WFFULL;
return (TRUE);
}
/*
* Delete current window. Call shrink-window to do the screen updating, then
* throw away the window.
*/
int
delwind(int f, int n)
{
struct mgwin *wp, *nwp;
wp = curwp; /* Cheap... */
/* shrinkwind returning false means only one window... */
if (shrinkwind(FFRAND, wp->w_ntrows + 1) == FALSE)
return (FALSE);
if (--wp->w_bufp->b_nwnd == 0) {
wp->w_bufp->b_dotp = wp->w_dotp;
wp->w_bufp->b_doto = wp->w_doto;
wp->w_bufp->b_markp = wp->w_markp;
wp->w_bufp->b_marko = wp->w_marko;
wp->w_bufp->b_dotline = wp->w_dotline;
wp->w_bufp->b_markline = wp->w_markline;
}
/* since shrinkwind did't crap out, we know we have a second window */
if (wp == wheadp)
wheadp = curwp = wp->w_wndp;
else if ((curwp = wp->w_wndp) == NULL)
curwp = wheadp;
curbp = curwp->w_bufp;
for (nwp = wheadp; nwp != NULL; nwp = nwp->w_wndp)
if (nwp->w_wndp == wp) {
nwp->w_wndp = wp->w_wndp;
break;
}
free(wp);
return (TRUE);
}
|
27f8cb1fe32c19fceb1a9af892afc7221bad8551
|
ed2c7c59a934be2d6c326693f60d0f847b09505c
|
/tests/check_utils.c
|
8336adb3fe09ea7d1149d3a160d7b152ad33b91a
|
[
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
Mange/rofi-emoji
|
e209fe6839f37d12c4b6589a7ef40363d6bd08da
|
eeae62e6fa598df19977f2ebad2d91526c1e6d43
|
refs/heads/master
| 2023-05-01T18:31:12.087945
| 2023-04-19T06:04:17
| 2023-04-19T06:04:17
| 132,520,665
| 461
| 36
|
MIT
| 2022-09-12T18:26:44
| 2018-05-07T21:57:30
|
C
|
UTF-8
|
C
| false
| false
| 5,877
|
c
|
check_utils.c
|
#include <check.h>
#include <glib.h>
#include <stdlib.h>
#include "../src/utils.h"
START_TEST(test_capitalize) {
char *str = g_strdup("hello world");
char *upper = g_strdup("HELLO WORLD");
capitalize(str);
capitalize(upper);
ck_assert_str_eq(str, "Hello world");
ck_assert_str_eq(upper, "HELLO WORLD");
g_free(str);
g_free(upper);
}
END_TEST
START_TEST(test_tokenize_search_simple_query) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "hello world ";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "hello world");
ck_assert_ptr_eq(group_query, NULL);
ck_assert_ptr_eq(subgroup_query, NULL);
// query is a copy of the input
query[0] = 'b';
ck_assert_str_eq(query, "bello world");
ck_assert_str_eq(input, "hello world ");
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_tokenize_search_empty_query) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "");
ck_assert_ptr_eq(group_query, NULL);
ck_assert_ptr_eq(subgroup_query, NULL);
// query is a copy of the input
ck_assert_ptr_ne(query, input);
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_tokenize_search_group_query) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "hello @group world";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "hello world");
ck_assert_str_eq(group_query, "group");
ck_assert_ptr_eq(subgroup_query, NULL);
// query is a copy of the input
ck_assert_ptr_ne(query, input);
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_tokenize_search_subgroup_query) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "hello #sub world";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "hello world");
ck_assert_ptr_eq(group_query, NULL);
ck_assert_str_eq(subgroup_query, "sub");
// query is a copy of the input
ck_assert_ptr_ne(query, input);
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_tokenize_search_complex_query) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "@group unicorn #animal";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "unicorn");
ck_assert_str_eq(group_query, "group");
ck_assert_str_eq(subgroup_query, "animal");
// query is a copy of the input
ck_assert_ptr_ne(query, input);
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_tokenize_search_empty_filters) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "@ #";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "");
ck_assert_ptr_eq(group_query, NULL);
ck_assert_ptr_eq(subgroup_query, NULL);
// query is a copy of the input
ck_assert_ptr_ne(query, input);
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_tokenize_search_only_group) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "@hello";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "");
ck_assert_str_eq(group_query, "hello");
ck_assert_ptr_eq(subgroup_query, NULL);
// query is a copy of the input
ck_assert_ptr_ne(query, input);
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_tokenize_search_repeated_filters) {
char *query = NULL;
char *group_query = NULL;
char *subgroup_query = NULL;
char *input = "1 @a #x 2 #y @b 3";
tokenize_search(input, &query, &group_query, &subgroup_query);
ck_assert_str_eq(query, "1 2 3");
ck_assert_str_eq(group_query, "b");
ck_assert_str_eq(subgroup_query, "y");
// query is a copy of the input
ck_assert_ptr_ne(query, input);
g_free(query);
g_free(group_query);
g_free(subgroup_query);
}
END_TEST
START_TEST(test_codepoint) {
ck_assert_str_eq(codepoint("A"), "U+0041");
ck_assert_str_eq(codepoint("🙃"), "U+1F643");
ck_assert_str_eq(codepoint("🇸🇪"), "U+1F1F8 U+1F1EA");
}
END_TEST
Suite *utils_suite(void) {
Suite *s;
TCase *tc_core;
TCase *tc_tokenize;
TCase *tc_codepoint;
s = suite_create("Utils");
tc_core = tcase_create("Core");
tcase_add_test(tc_core, test_capitalize);
tc_tokenize = tcase_create("Tokenize");
tcase_add_test(tc_tokenize, test_tokenize_search_simple_query);
tcase_add_test(tc_tokenize, test_tokenize_search_empty_query);
tcase_add_test(tc_tokenize, test_tokenize_search_group_query);
tcase_add_test(tc_tokenize, test_tokenize_search_subgroup_query);
tcase_add_test(tc_tokenize, test_tokenize_search_complex_query);
tcase_add_test(tc_tokenize, test_tokenize_search_empty_filters);
tcase_add_test(tc_tokenize, test_tokenize_search_only_group);
tcase_add_test(tc_tokenize, test_tokenize_search_repeated_filters);
tc_codepoint = tcase_create("Codepoint");
tcase_add_test(tc_codepoint, test_codepoint);
suite_add_tcase(s, tc_core);
suite_add_tcase(s, tc_tokenize);
suite_add_tcase(s, tc_codepoint);
return s;
}
int main(void) {
int number_failed;
Suite *s;
SRunner *sr;
s = utils_suite();
sr = srunner_create(s);
srunner_run_all(sr, CK_VERBOSE);
number_failed = srunner_ntests_failed(sr);
srunner_free(sr);
return (number_failed == 0) ? EXIT_SUCCESS : EXIT_FAILURE;
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.