发明名称 System and method for implementing scalable contention-adaptive statistics counters
摘要 The systems and methods described herein may implement scalable statistics counters that are adaptive to the amount of contention for the counters. The counters may be accessible within transactions. Methods for determining whether or when to increment the counters in response to initiation of an increment operation and/or methods for updating the counters may be selected dependent on current, recent, or historical amounts of contention. Various contention management policies or retry conditions may be applied to select between multiple methods. One counter may include a precise counter portion that is incremented under low contention and a probabilistic counter portion that is updated under high contention. Amounts by which probabilistic counters are incremented may be contention-dependent. Another counter may include a node identifier portion that encourages consecutive increments by threads on a single node only when under contention. Another counter may be inflated in response to contention for the counter.
申请公布号 US9183048(B2) 申请公布日期 2015.11.10
申请号 US201213722811 申请日期 2012.12.20
申请人 Oracle International Corporation 发明人 Dice David;Lev Yosef;Moir Mark S.
分类号 G06F9/30;G06F9/48;G06F9/52;G06F9/38 主分类号 G06F9/30
代理机构 Meyertons, Hood, Kivlin, Kowert & Goetzel, P.C. 代理人 Kowert Robert C.;Meyertons, Hood, Kivlin, Kowert & Goetzel, P.C.
主权项 1. A method, comprising: performing by one or more computing nodes, each of which comprises at least one processor core and a memory: beginning execution of a multithreaded application that comprises one or more operations to increment a shared counter, wherein the shared counter is implemented as a data structure that is accessible by a plurality of threads of the multithreaded application;initiating, by a given thread of the application, an increment operation targeting the shared counter;in response to said initiating, determining whether or when to update the data structure; andin response to determining that the data structure is to be updated, updating a value stored in the data structure;wherein said determining whether or when to update the data structure or said updating a value stored in the data structure comprises selecting one of a plurality of techniques for performing said determining or said updating dependent on a current or historical amount of contention for the shared counter.
地址 Redwood City CA US