A brief file description. More...
#include "libts.h"
#include "ink_resource.h"
Go to the source code of this file.
Functions | |
TS_INLINE int64_t | buffer_size_to_index (int64_t size, int64_t max=max_iobuffer_size) |
TS_INLINE int64_t | iobuffer_size_to_index (int64_t size, int64_t max) |
TS_INLINE int64_t | index_to_buffer_size (int64_t idx) |
TS_INLINE IOBufferBlock * | iobufferblock_clone (IOBufferBlock *b, int64_t offset, int64_t len) |
Clone a IOBufferBlock chain. | |
TS_INLINE IOBufferBlock * | iobufferblock_skip (IOBufferBlock *b, int64_t *poffset, int64_t *plen, int64_t write) |
Skip over specified bytes in chain. | |
TS_INLINE IOBufferData * | new_IOBufferData_internal (void *b, int64_t size, int64_t asize_index) |
TS_INLINE IOBufferData * | new_constant_IOBufferData_internal (void *b, int64_t size) |
TS_INLINE IOBufferData * | new_xmalloc_IOBufferData_internal (void *b, int64_t size) |
TS_INLINE IOBufferData * | new_IOBufferData_internal (void *b, int64_t size) |
TS_INLINE IOBufferData * | new_IOBufferData_internal (int64_t size_index, AllocType type) |
TS_INLINE IOBufferBlock * | new_IOBufferBlock_internal () |
TS_INLINE IOBufferBlock * | new_IOBufferBlock_internal (IOBufferData *d, int64_t len, int64_t offset) |
TS_INLINE MIOBuffer * | new_MIOBuffer_internal (int64_t size_index) |
TS_INLINE void | free_MIOBuffer (MIOBuffer *mio) |
TS_INLINE MIOBuffer * | new_empty_MIOBuffer_internal (int64_t size_index) |
TS_INLINE void | free_empty_MIOBuffer (MIOBuffer *mio) |
Variables | |
inkcoreapi ClassAllocator < MIOBuffer > | ioAllocator |
A brief file description.
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.
Definition in file P_IOBuffer.h.
TS_INLINE int64_t buffer_size_to_index | ( | int64_t | size, | |
int64_t | max = max_iobuffer_size | |||
) |
Definition at line 43 of file P_IOBuffer.h.
References BUFFER_SIZE_FOR_INDEX.
Referenced by HttpTunnel::allocate_redirect_postdata_buffers(), HttpTunnel::allocate_redirect_postdata_producer_buffer(), CacheContinuation::allocMsgBuffer(), ClusterHandler::build_initial_vector(), HttpSM::do_setup_post_tunnel(), HttpSM::find_http_resp_buffer_size(), HttpTransact::handle_trace_and_options_requests(), ObjectReloadCont::Init(), OneWayTunnel::init(), OneWayMultiTunnel::init(), ink_event_system_init(), iobuffer_size_to_index(), main(), ClusterControl::real_alloc_data(), HttpSM::setup_cache_read_transfer(), HttpSM::setup_cache_transfer_to_transform(), HttpSM::setup_internal_transfer(), HttpSM::setup_transform_to_server_transfer(), and HttpSM::state_send_server_request_header().
TS_INLINE void free_empty_MIOBuffer | ( | MIOBuffer * | mio | ) |
Definition at line 812 of file P_IOBuffer.h.
References this_thread(), and THREAD_FREE.
Referenced by ClusterState::~ClusterState().
TS_INLINE void free_MIOBuffer | ( | MIOBuffer * | mio | ) |
Definition at line 790 of file P_IOBuffer.h.
References MIOBuffer::_writer, MIOBuffer::dealloc_all_readers(), this_thread(), and THREAD_FREE.
Referenced by KeepAliveConnTable::append(), FetchSM::cleanUp(), ChunkedHandler::clear(), OneWayTunnel::close_source_vio(), OneWayTunnel::close_target_vio(), OneWayMultiTunnel::close_target_vio(), HttpTunnel::deallocate_buffers(), HttpTunnel::deallocate_redirect_postdata_buffers(), HttpServerSession::destroy(), HttpClientSession::destroy(), Http2ClientSession::destroy(), TestProxy::done(), CacheTestSM::event_handler(), ObjectReloadCont::free(), SocksProxy::free(), SocksEntry::free(), KeepAliveConn::free(), PrefetchBlaster::free(), TransformControl::handle_event(), PrefetchTransform::handle_event(), ShowCache::handleCacheEvent(), ProtocolProbeTrampoline::ioCompletionEvent(), ProtoVCTable< VCTentry, max_entries >::remove_entry(), HttpVCTable::remove_entry(), setup_client_request(), HttpSM::state_send_server_request_header(), TSIOBufferDestroy(), HttpSM::tunnel_handler_post_ua(), CacheContinuation::VCdataRead(), CacheTestSM::~CacheTestSM(), CheckConnect::~CheckConnect(), NetTesterSM::~NetTesterSM(), NetVCTest::~NetVCTest(), NullTransform::~NullTransform(), PrefetchTransform::~PrefetchTransform(), RangeTransform::~RangeTransform(), and SSLNextProtocolAccept::~SSLNextProtocolAccept().
TS_INLINE int64_t index_to_buffer_size | ( | int64_t | idx | ) |
Definition at line 61 of file P_IOBuffer.h.
References BUFFER_SIZE_FOR_CONSTANT, BUFFER_SIZE_FOR_INDEX, BUFFER_SIZE_FOR_XMALLOC, BUFFER_SIZE_INDEX_IS_CONSTANT, BUFFER_SIZE_INDEX_IS_FAST_ALLOCATED, and BUFFER_SIZE_INDEX_IS_XMALLOCED.
Referenced by IOBufferData::alloc(), MIOBuffer::block_size(), IOBufferData::block_size(), HttpSM::find_http_resp_buffer_size(), INKUDPSendTo(), HttpSM::setup_cache_read_transfer(), and HttpSM::setup_internal_transfer().
TS_INLINE int64_t iobuffer_size_to_index | ( | int64_t | size, | |
int64_t | max | |||
) |
Definition at line 53 of file P_IOBuffer.h.
References BUFFER_SIZE_FOR_INDEX, BUFFER_SIZE_INDEX_FOR_XMALLOC_SIZE, and buffer_size_to_index().
Referenced by cache_op_ClusterFunction(), cache_op_result_ClusterFunction(), RamCacheCLFUS::get(), CacheVC::handleRead(), CacheVC::handleReadDone(), new_DocEvacuator(), new_incoming_UDPPacket(), new_IOBufferData_internal(), new_UDPPacket(), MIOBuffer::set_size_index(), CacheContinuation::setupVCdataRead(), and ICPProcessor::start().
TS_INLINE IOBufferBlock* iobufferblock_clone | ( | IOBufferBlock * | b, | |
int64_t | offset, | |||
int64_t | len | |||
) |
Clone a IOBufferBlock chain.
Used to snarf a IOBufferBlock chain w/o copy.
b | head of source IOBufferBlock chain. | |
offset | # bytes in the beginning to skip. | |
len | bytes to copy from source. |
Definition at line 75 of file P_IOBuffer.h.
References IOBufferBlock::_buf_end, IOBufferBlock::_end, IOBufferBlock::_start, IOBufferBlock::clone(), IOBufferBlock::next, and start.
Referenced by CacheVC::openReadFromWriterMain().
TS_INLINE IOBufferBlock* iobufferblock_skip | ( | IOBufferBlock * | b, | |
int64_t * | poffset, | |||
int64_t * | plen, | |||
int64_t | write | |||
) |
Skip over specified bytes in chain.
Used for dropping references.
b | head of source IOBufferBlock chain. | |
poffset | originally offset in b, finally offset in returned IOBufferBlock. | |
plen | value of write is subtracted from plen in the function. | |
write | bytes to skip. |
Definition at line 112 of file P_IOBuffer.h.
References IOBufferBlock::next, and IOBufferBlock::read_avail().
Referenced by CacheVC::openReadFromWriterMain(), CacheVC::openWriteCloseDataDone(), and CacheVC::openWriteWriteDone().
TS_INLINE IOBufferData* new_constant_IOBufferData_internal | ( | void * | b, | |
int64_t | size | |||
) |
Definition at line 220 of file P_IOBuffer.h.
References BUFFER_SIZE_INDEX_FOR_CONSTANT_SIZE, new_IOBufferData_internal(), and TRACK_BUFFER_USER.
TS_INLINE MIOBuffer* new_empty_MIOBuffer_internal | ( | int64_t | size_index | ) |
Definition at line 797 of file P_IOBuffer.h.
References MIOBuffer::_location, MIOBuffer::size_index, this_thread(), and THREAD_ALLOC.
TS_INLINE IOBufferBlock* new_IOBufferBlock_internal | ( | ) |
Definition at line 351 of file P_IOBuffer.h.
References IOBufferBlock::_location, ioBlockAllocator, this_thread(), and THREAD_ALLOC.
TS_INLINE IOBufferBlock* new_IOBufferBlock_internal | ( | IOBufferData * | d, | |
int64_t | len, | |||
int64_t | offset | |||
) |
Definition at line 365 of file P_IOBuffer.h.
References IOBufferBlock::_location, ioBlockAllocator, IOBufferBlock::set(), this_thread(), and THREAD_ALLOC.
TS_INLINE IOBufferData* new_IOBufferData_internal | ( | void * | b, | |
int64_t | size | |||
) |
Definition at line 248 of file P_IOBuffer.h.
References iobuffer_size_to_index(), new_IOBufferData_internal(), and TRACK_BUFFER_USER.
TS_INLINE IOBufferData* new_IOBufferData_internal | ( | void * | b, | |
int64_t | size, | |||
int64_t | asize_index | |||
) |
Definition at line 201 of file P_IOBuffer.h.
References IOBufferData::_data, IOBufferData::_location, IOBufferData::_size_index, BUFFER_SIZE_INDEX_IS_CONSTANT, ink_assert, ioDataAllocator, this_thread(), and THREAD_ALLOC.
TS_INLINE IOBufferData* new_IOBufferData_internal | ( | int64_t | size_index, | |
AllocType | type | |||
) |
Definition at line 262 of file P_IOBuffer.h.
References IOBufferData::_location, IOBufferData::alloc(), ioDataAllocator, this_thread(), and THREAD_ALLOC.
TS_INLINE MIOBuffer* new_MIOBuffer_internal | ( | int64_t | size_index | ) |
Definition at line 775 of file P_IOBuffer.h.
References MIOBuffer::_location, MIOBuffer::alloc(), this_thread(), and THREAD_ALLOC.
TS_INLINE IOBufferData* new_xmalloc_IOBufferData_internal | ( | void * | b, | |
int64_t | size | |||
) |
Definition at line 234 of file P_IOBuffer.h.
References BUFFER_SIZE_INDEX_FOR_XMALLOC_SIZE, new_IOBufferData_internal(), and TRACK_BUFFER_USER.
inkcoreapi ClassAllocator<MIOBuffer> ioAllocator |