Changeset 7dafb7b
- Timestamp:
- Jan 12, 2021, 1:50:56 PM (4 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- 56911ce
- Parents:
- 481ee28
- Location:
- libcfa/src/concurrency
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/concurrency/io.cfa
r481ee28 r7dafb7b 380 380 381 381 // Success return the data 382 sqe->opcode = 0;383 sqe->flags = 0;384 sqe->ioprio = 0;385 sqe->fd = 0;386 sqe->off = 0;387 sqe->addr = 0;388 sqe->len = 0;389 sqe->accept_flags = 0;390 sqe->__pad2[0] = 0;391 sqe->__pad2[1] = 0;392 sqe->__pad2[2] = 0;393 382 return [sqe, idx]; 394 383 } -
libcfa/src/concurrency/io/call.cfa.in
r481ee28 r7dafb7b 221 221 222 222 __u32 idx; 223 volatile struct io_uring_sqe * sqe; 224 [sqe, idx] = __submit_alloc( ring, (__u64)(uintptr_t)&future ); 225 226 sqe->__pad2[0] = sqe->__pad2[1] = sqe->__pad2[2] = 0; 223 struct io_uring_sqe * sqe; 224 [(volatile struct io_uring_sqe *) sqe, idx] = __submit_alloc( ring, (__u64)(uintptr_t)&future ); 225 227 226 sqe->opcode = IORING_OP_{op}; 228 sqe->flags = sflags;{body} 227 sqe->flags = sflags; 228 sqe->ioprio = 0; 229 sqe->fd = 0; 230 sqe->off = 0; 231 sqe->addr = 0; 232 sqe->len = 0; 233 sqe->accept_flags = 0; 234 sqe->__pad2[0] = 0; 235 sqe->__pad2[1] = 0; 236 sqe->__pad2[2] = 0;{body} 237 238 asm volatile("": : :"memory"); 229 239 230 240 verify( sqe->user_data == (__u64)(uintptr_t)&future ); … … 314 324 Call('ACCEPT', 'int accept4(int sockfd, struct sockaddr *addr, socklen_t *addrlen, int flags)', { 315 325 'fd': 'sockfd', 316 'ioprio': '0',317 326 'addr': '(__u64)addr', 318 327 'addr2': '(__u64)addrlen', … … 374 383 Call('READ', 'ssize_t read(int fd, void * buf, size_t count)', { 375 384 'fd': 'fd', 376 'off': '0',377 385 'addr': '(__u64)buf', 378 386 'len': 'count' … … 381 389 Call('WRITE', 'ssize_t write(int fd, void * buf, size_t count)', { 382 390 'fd': 'fd', 383 'off': '0',384 391 'addr': '(__u64)buf', 385 392 'len': 'count'
Note: See TracChangeset
for help on using the changeset viewer.